@anker-in/headless-ui 1.1.2 → 1.1.5
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/dist/cjs/biz-components/AccordionCards/index.js.map +2 -2
- package/dist/cjs/biz-components/AiuiProvider/index.d.ts +4 -0
- package/dist/cjs/biz-components/AiuiProvider/index.js +1 -1
- package/dist/cjs/biz-components/AiuiProvider/index.js.map +2 -2
- package/dist/cjs/biz-components/AplusDesc/index.d.ts +22 -0
- package/dist/cjs/biz-components/AplusDesc/index.js +2 -0
- package/dist/cjs/biz-components/AplusDesc/index.js.map +7 -0
- package/dist/cjs/biz-components/Category/SwiperCategory.js.map +2 -2
- package/dist/cjs/biz-components/Category/index.js +1 -1
- package/dist/cjs/biz-components/Category/index.js.map +2 -2
- package/dist/cjs/biz-components/CreativeModule/index.js +1 -1
- package/dist/cjs/biz-components/CreativeModule/index.js.map +2 -2
- package/dist/cjs/biz-components/DownLoad/index.d.ts +20 -0
- package/dist/cjs/biz-components/DownLoad/index.js +2 -0
- package/dist/cjs/biz-components/DownLoad/index.js.map +7 -0
- package/dist/cjs/biz-components/Evaluate/index.js +1 -1
- package/dist/cjs/biz-components/Evaluate/index.js.map +1 -1
- package/dist/cjs/biz-components/Faq/Faq.js +1 -1
- package/dist/cjs/biz-components/Faq/Faq.js.map +2 -2
- package/dist/cjs/biz-components/Features/index.js +1 -1
- package/dist/cjs/biz-components/Features/index.js.map +2 -2
- package/dist/cjs/biz-components/FootCharger/index.js +1 -1
- package/dist/cjs/biz-components/FootCharger/index.js.map +2 -2
- package/dist/cjs/biz-components/FooterNavigation/index.js +1 -1
- package/dist/cjs/biz-components/FooterNavigation/index.js.map +2 -2
- package/dist/cjs/biz-components/GiftBox/index.d.ts +17 -0
- package/dist/cjs/biz-components/GiftBox/index.js +2 -0
- package/dist/cjs/biz-components/GiftBox/index.js.map +7 -0
- package/dist/cjs/biz-components/Graphic/index.js +1 -1
- package/dist/cjs/biz-components/Graphic/index.js.map +2 -2
- package/dist/cjs/biz-components/GraphicMore/index.js +1 -1
- package/dist/cjs/biz-components/GraphicMore/index.js.map +2 -2
- package/dist/cjs/biz-components/GraphicOverlay/GraphicOverlay.js.map +1 -1
- package/dist/cjs/biz-components/HeaderNavigation/NavProvider.js.map +2 -2
- package/dist/cjs/biz-components/HeaderNavigation/icons/Polygon.js.map +1 -1
- package/dist/cjs/biz-components/HeaderNavigation/index.js +1 -1
- package/dist/cjs/biz-components/HeaderNavigation/index.js.map +2 -2
- package/dist/cjs/biz-components/HeaderNavigation/withCategory.d.ts +1 -1
- package/dist/cjs/biz-components/HeaderNavigation/withCategory.js.map +2 -2
- package/dist/cjs/biz-components/HeroBanner/Countdown.js +1 -1
- package/dist/cjs/biz-components/HeroBanner/Countdown.js.map +1 -1
- package/dist/cjs/biz-components/Listing/BizProductProvider.d.ts +126 -0
- package/dist/cjs/biz-components/Listing/BizProductProvider.js +2 -0
- package/dist/cjs/biz-components/Listing/BizProductProvider.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.d.ts +10 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.d.ts +25 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/index.d.ts +15 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/type.d.ts +30 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/type.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/type.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +39 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js +39 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.d.ts +10 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.d.ts +30 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.d.ts +43 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.d.ts +21 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.d.ts +1 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +8 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.d.ts +73 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.d.ts +6 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/index.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/ProductCard/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.d.ts +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.d.ts +3 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.d.ts +12 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.d.ts +6 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.d.ts +12 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.js +2 -0
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.js.map +7 -0
- package/dist/cjs/biz-components/Listing/components/index.d.ts +3 -0
- package/dist/cjs/biz-components/Listing/components/index.js +2 -0
- package/dist/cjs/biz-components/Listing/components/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/const.d.ts +29 -0
- package/dist/cjs/biz-components/Listing/const.js +2 -0
- package/dist/cjs/biz-components/Listing/const.js.map +7 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant-media.d.ts +14 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant-media.js +2 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant-media.js.map +7 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant.js +2 -0
- package/dist/cjs/biz-components/Listing/hooks/use-variant.js.map +7 -0
- package/dist/cjs/biz-components/Listing/hooks/useBenefits.d.ts +50 -0
- package/dist/cjs/biz-components/Listing/hooks/useBenefits.js +2 -0
- package/dist/cjs/biz-components/Listing/hooks/useBenefits.js.map +7 -0
- package/dist/cjs/biz-components/Listing/hooks/useCopy.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/hooks/useCopy.js +2 -0
- package/dist/cjs/biz-components/Listing/hooks/useCopy.js.map +7 -0
- package/dist/cjs/biz-components/Listing/hooks/useDiscountEnable.d.ts +14 -0
- package/dist/cjs/biz-components/Listing/hooks/useDiscountEnable.js +2 -0
- package/dist/cjs/biz-components/Listing/hooks/useDiscountEnable.js.map +7 -0
- package/dist/cjs/biz-components/Listing/index.d.ts +3 -0
- package/dist/cjs/biz-components/Listing/index.js +2 -0
- package/dist/cjs/biz-components/Listing/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/types/graphql.d.ts +7473 -0
- package/dist/cjs/biz-components/Listing/types/graphql.js +2 -0
- package/dist/cjs/biz-components/Listing/types/graphql.js.map +7 -0
- package/dist/cjs/biz-components/Listing/types/product.d.ts +141 -0
- package/dist/cjs/biz-components/Listing/types/product.js +2 -0
- package/dist/cjs/biz-components/Listing/types/product.js.map +7 -0
- package/dist/cjs/biz-components/Listing/types/productMetafields.d.js +2 -0
- package/dist/cjs/biz-components/Listing/types/productMetafields.d.js.map +7 -0
- package/dist/cjs/biz-components/Listing/types/type-helper.d.ts +5 -0
- package/dist/cjs/biz-components/Listing/types/type-helper.js +2 -0
- package/dist/cjs/biz-components/Listing/types/type-helper.js.map +7 -0
- package/dist/cjs/biz-components/Listing/types.d.ts +29 -0
- package/dist/cjs/biz-components/Listing/types.js +2 -0
- package/dist/cjs/biz-components/Listing/types.js.map +7 -0
- package/dist/cjs/biz-components/Listing/utils/helper.d.ts +36 -0
- package/dist/cjs/biz-components/Listing/utils/helper.js +2 -0
- package/dist/cjs/biz-components/Listing/utils/helper.js.map +7 -0
- package/dist/cjs/biz-components/Listing/utils/index.d.ts +37 -0
- package/dist/cjs/biz-components/Listing/utils/index.js +2 -0
- package/dist/cjs/biz-components/Listing/utils/index.js.map +7 -0
- package/dist/cjs/biz-components/Listing/utils/textFormat.d.ts +73 -0
- package/dist/cjs/biz-components/Listing/utils/textFormat.js +2 -0
- package/dist/cjs/biz-components/Listing/utils/textFormat.js.map +7 -0
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +3 -3
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/types.d.ts +2 -0
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/types.js +1 -1
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/types.js.map +1 -1
- package/dist/cjs/biz-components/NavigationSearch/index.js +2 -2
- package/dist/cjs/biz-components/NavigationSearch/index.js.map +2 -2
- package/dist/cjs/biz-components/NavigationSearch/types.js.map +1 -1
- package/dist/cjs/biz-components/SearchPage/index.js +1 -1
- package/dist/cjs/biz-components/SearchPage/index.js.map +2 -2
- package/dist/cjs/biz-components/SearchPage/types.js.map +2 -2
- package/dist/cjs/biz-components/SelectStore/index.d.ts +20 -0
- package/dist/cjs/biz-components/SelectStore/index.js +2 -0
- package/dist/cjs/biz-components/SelectStore/index.js.map +7 -0
- package/dist/cjs/biz-components/ShelfDisplay/index.js +1 -1
- package/dist/cjs/biz-components/ShelfDisplay/index.js.map +1 -1
- package/dist/cjs/biz-components/ShelfDisplay/shelfDisplay.js.map +1 -1
- package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js +1 -1
- package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js.map +1 -1
- package/dist/cjs/biz-components/Slogan/index.js.map +2 -2
- package/dist/cjs/biz-components/Specs/dropdown.js +2 -2
- package/dist/cjs/biz-components/Specs/dropdown.js.map +2 -2
- package/dist/cjs/biz-components/Specs/index.js +1 -1
- package/dist/cjs/biz-components/Specs/index.js.map +3 -3
- package/dist/cjs/biz-components/Subscribe/index.js +1 -1
- package/dist/cjs/biz-components/Subscribe/index.js.map +2 -2
- package/dist/cjs/biz-components/SwiperBox/index.js.map +2 -2
- package/dist/cjs/biz-components/Tabs/types.js.map +1 -1
- package/dist/cjs/biz-components/TextModal/index.js +1 -1
- package/dist/cjs/biz-components/TextModal/index.js.map +1 -1
- package/dist/cjs/biz-components/Title/index.js +1 -1
- package/dist/cjs/biz-components/Title/index.js.map +2 -2
- package/dist/cjs/biz-components/VideoModal/index.js +1 -1
- package/dist/cjs/biz-components/VideoModal/index.js.map +2 -2
- package/dist/cjs/biz-components/index.d.ts +57 -1
- package/dist/cjs/biz-components/index.js +1 -1
- package/dist/cjs/biz-components/index.js.map +3 -3
- package/dist/cjs/components/ExposureDetector.d.ts +45 -0
- package/dist/cjs/components/ExposureDetector.js +2 -0
- package/dist/cjs/components/ExposureDetector.js.map +7 -0
- package/dist/cjs/components/board.js +1 -1
- package/dist/cjs/components/board.js.map +3 -3
- package/dist/cjs/components/button.js.map +2 -2
- package/dist/cjs/components/checkbox.d.ts +1 -0
- package/dist/cjs/components/checkbox.js +1 -1
- package/dist/cjs/components/checkbox.js.map +3 -3
- package/dist/cjs/components/dialog.d.ts +1 -1
- package/dist/cjs/components/dialog.js +1 -1
- package/dist/cjs/components/dialog.js.map +2 -2
- package/dist/cjs/components/index.d.ts +1 -0
- package/dist/cjs/components/index.js +1 -1
- package/dist/cjs/components/index.js.map +3 -3
- package/dist/cjs/components/loadingDots.js +1 -1
- package/dist/cjs/components/loadingDots.js.map +2 -2
- package/dist/cjs/components/picture.js +1 -1
- package/dist/cjs/components/picture.js.map +2 -2
- package/dist/cjs/cpn-components/CpnNavigation/index.js +1 -1
- package/dist/cjs/cpn-components/CpnNavigation/index.js.map +3 -3
- package/dist/cjs/cpn-components/CpnNavigation/types.d.ts +1 -0
- package/dist/cjs/cpn-components/CpnNavigation/types.js +1 -1
- package/dist/cjs/cpn-components/CpnNavigation/types.js.map +3 -3
- package/dist/cjs/cpn-components/CpnProductCard/types.d.ts +1 -1
- package/dist/cjs/cpn-components/CpnProductCard/types.js.map +1 -1
- package/dist/cjs/helpers/utils.js.map +1 -1
- package/dist/cjs/hooks/useExposure.js.map +2 -2
- package/dist/cjs/hooks/useExposureDetection.d.ts +69 -0
- package/dist/cjs/hooks/useExposureDetection.js +2 -0
- package/dist/cjs/hooks/useExposureDetection.js.map +7 -0
- package/dist/cjs/hooks/useIntersectionObserver.js.map +2 -2
- package/dist/cjs/hooks/useRollout.js.map +2 -2
- package/dist/cjs/stories/board.stories.d.ts +1 -1
- package/dist/cjs/stories/board.stories.js +1 -1
- package/dist/cjs/stories/board.stories.js.map +2 -2
- package/dist/cjs/stories/carousel.stories.d.ts +3 -57
- package/dist/cjs/stories/carousel.stories.js.map +2 -2
- package/dist/cjs/stories/specs.stories.js.map +2 -2
- package/dist/esm/biz-components/AccordionCards/index.js.map +2 -2
- package/dist/esm/biz-components/AiuiProvider/index.d.ts +4 -0
- package/dist/esm/biz-components/AiuiProvider/index.js +1 -1
- package/dist/esm/biz-components/AiuiProvider/index.js.map +2 -2
- package/dist/esm/biz-components/AplusDesc/index.d.ts +22 -0
- package/dist/esm/biz-components/AplusDesc/index.js +2 -0
- package/dist/esm/biz-components/AplusDesc/index.js.map +7 -0
- package/dist/esm/biz-components/Category/SwiperCategory.js.map +2 -2
- package/dist/esm/biz-components/Category/index.js +1 -1
- package/dist/esm/biz-components/Category/index.js.map +2 -2
- package/dist/esm/biz-components/CreativeModule/index.js +1 -1
- package/dist/esm/biz-components/CreativeModule/index.js.map +2 -2
- package/dist/esm/biz-components/DownLoad/index.d.ts +20 -0
- package/dist/esm/biz-components/DownLoad/index.js +2 -0
- package/dist/esm/biz-components/DownLoad/index.js.map +7 -0
- package/dist/esm/biz-components/Evaluate/index.js +1 -1
- package/dist/esm/biz-components/Evaluate/index.js.map +1 -1
- package/dist/esm/biz-components/Faq/Faq.js +1 -1
- package/dist/esm/biz-components/Faq/Faq.js.map +3 -3
- package/dist/esm/biz-components/Features/index.js +1 -1
- package/dist/esm/biz-components/Features/index.js.map +2 -2
- package/dist/esm/biz-components/FootCharger/index.js +1 -1
- package/dist/esm/biz-components/FootCharger/index.js.map +2 -2
- package/dist/esm/biz-components/FooterNavigation/index.js +1 -1
- package/dist/esm/biz-components/FooterNavigation/index.js.map +2 -2
- package/dist/esm/biz-components/GiftBox/index.d.ts +17 -0
- package/dist/esm/biz-components/GiftBox/index.js +2 -0
- package/dist/esm/biz-components/GiftBox/index.js.map +7 -0
- package/dist/esm/biz-components/Graphic/index.js +1 -1
- package/dist/esm/biz-components/Graphic/index.js.map +2 -2
- package/dist/esm/biz-components/GraphicMore/index.js +1 -1
- package/dist/esm/biz-components/GraphicMore/index.js.map +2 -2
- package/dist/esm/biz-components/GraphicOverlay/GraphicOverlay.js.map +1 -1
- package/dist/esm/biz-components/HeaderNavigation/NavProvider.js.map +2 -2
- package/dist/esm/biz-components/HeaderNavigation/icons/Polygon.js.map +1 -1
- package/dist/esm/biz-components/HeaderNavigation/index.js +1 -1
- package/dist/esm/biz-components/HeaderNavigation/index.js.map +2 -2
- package/dist/esm/biz-components/HeaderNavigation/withCategory.d.ts +1 -1
- package/dist/esm/biz-components/HeaderNavigation/withCategory.js.map +2 -2
- package/dist/esm/biz-components/HeroBanner/Countdown.js +1 -1
- package/dist/esm/biz-components/HeroBanner/Countdown.js.map +1 -1
- package/dist/esm/biz-components/Listing/BizProductProvider.d.ts +126 -0
- package/dist/esm/biz-components/Listing/BizProductProvider.js +2 -0
- package/dist/esm/biz-components/Listing/BizProductProvider.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.d.ts +10 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.d.ts +25 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/index.d.ts +15 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/type.d.ts +30 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/type.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/type.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/utils.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/utils.js +2 -0
- package/dist/esm/biz-components/Listing/components/PaidShipping/utils.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +39 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js +39 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.d.ts +10 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/ModalContainer.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.d.ts +30 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.d.ts +43 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.d.ts +21 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.d.ts +1 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +8 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.d.ts +73 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.d.ts +6 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +5 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/index.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/ProductCard/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.d.ts +2 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.d.ts +3 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.d.ts +12 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js +1 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/index.d.ts +6 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/types.d.ts +12 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/types.js +1 -0
- package/dist/esm/biz-components/Listing/components/PurchaseBar/types.js.map +7 -0
- package/dist/esm/biz-components/Listing/components/index.d.ts +3 -0
- package/dist/esm/biz-components/Listing/components/index.js +2 -0
- package/dist/esm/biz-components/Listing/components/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/const.d.ts +29 -0
- package/dist/esm/biz-components/Listing/const.js +2 -0
- package/dist/esm/biz-components/Listing/const.js.map +7 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant-media.d.ts +14 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant-media.js +2 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant-media.js.map +7 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant.d.ts +5 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant.js +2 -0
- package/dist/esm/biz-components/Listing/hooks/use-variant.js.map +7 -0
- package/dist/esm/biz-components/Listing/hooks/useBenefits.d.ts +50 -0
- package/dist/esm/biz-components/Listing/hooks/useBenefits.js +2 -0
- package/dist/esm/biz-components/Listing/hooks/useBenefits.js.map +7 -0
- package/dist/esm/biz-components/Listing/hooks/useCopy.d.ts +5 -0
- package/dist/esm/biz-components/Listing/hooks/useCopy.js +2 -0
- package/dist/esm/biz-components/Listing/hooks/useCopy.js.map +7 -0
- package/dist/esm/biz-components/Listing/hooks/useDiscountEnable.d.ts +14 -0
- package/dist/esm/biz-components/Listing/hooks/useDiscountEnable.js +2 -0
- package/dist/esm/biz-components/Listing/hooks/useDiscountEnable.js.map +7 -0
- package/dist/esm/biz-components/Listing/index.d.ts +3 -0
- package/dist/esm/biz-components/Listing/index.js +2 -0
- package/dist/esm/biz-components/Listing/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/types/graphql.d.ts +7473 -0
- package/dist/esm/biz-components/Listing/types/graphql.js +2 -0
- package/dist/esm/biz-components/Listing/types/graphql.js.map +7 -0
- package/dist/esm/biz-components/Listing/types/product.d.ts +141 -0
- package/dist/esm/biz-components/Listing/types/product.js +2 -0
- package/dist/esm/biz-components/Listing/types/product.js.map +7 -0
- package/dist/esm/biz-components/Listing/types/productMetafields.d.js +2 -0
- package/dist/esm/biz-components/Listing/types/productMetafields.d.js.map +7 -0
- package/dist/esm/biz-components/Listing/types/type-helper.d.ts +5 -0
- package/dist/esm/biz-components/Listing/types/type-helper.js +1 -0
- package/dist/esm/biz-components/Listing/types/type-helper.js.map +7 -0
- package/dist/esm/biz-components/Listing/types.d.ts +29 -0
- package/dist/esm/biz-components/Listing/types.js +1 -0
- package/dist/esm/biz-components/Listing/types.js.map +7 -0
- package/dist/esm/biz-components/Listing/utils/helper.d.ts +36 -0
- package/dist/esm/biz-components/Listing/utils/helper.js +2 -0
- package/dist/esm/biz-components/Listing/utils/helper.js.map +7 -0
- package/dist/esm/biz-components/Listing/utils/index.d.ts +37 -0
- package/dist/esm/biz-components/Listing/utils/index.js +2 -0
- package/dist/esm/biz-components/Listing/utils/index.js.map +7 -0
- package/dist/esm/biz-components/Listing/utils/textFormat.d.ts +73 -0
- package/dist/esm/biz-components/Listing/utils/textFormat.js +2 -0
- package/dist/esm/biz-components/Listing/utils/textFormat.js.map +7 -0
- package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
- package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +3 -3
- package/dist/esm/biz-components/MultiLayoutGraphicBlock/types.d.ts +2 -0
- package/dist/esm/biz-components/NavigationSearch/index.js +2 -2
- package/dist/esm/biz-components/NavigationSearch/index.js.map +2 -2
- package/dist/esm/biz-components/NavigationSearch/types.js.map +1 -1
- package/dist/esm/biz-components/SearchPage/index.js +1 -1
- package/dist/esm/biz-components/SearchPage/index.js.map +2 -2
- package/dist/esm/biz-components/SearchPage/types.js.map +2 -2
- package/dist/esm/biz-components/SelectStore/index.d.ts +20 -0
- package/dist/esm/biz-components/SelectStore/index.js +2 -0
- package/dist/esm/biz-components/SelectStore/index.js.map +7 -0
- package/dist/esm/biz-components/ShelfDisplay/index.js +1 -1
- package/dist/esm/biz-components/ShelfDisplay/index.js.map +1 -1
- package/dist/esm/biz-components/ShelfDisplay/shelfDisplay.js.map +1 -1
- package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js +1 -1
- package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js.map +1 -1
- package/dist/esm/biz-components/Slogan/index.js.map +2 -2
- package/dist/esm/biz-components/Specs/dropdown.js +2 -2
- package/dist/esm/biz-components/Specs/dropdown.js.map +2 -2
- package/dist/esm/biz-components/Specs/index.js +1 -1
- package/dist/esm/biz-components/Specs/index.js.map +3 -3
- package/dist/esm/biz-components/Subscribe/index.js +1 -1
- package/dist/esm/biz-components/Subscribe/index.js.map +2 -2
- package/dist/esm/biz-components/SwiperBox/index.js.map +2 -2
- package/dist/esm/biz-components/TextModal/index.js +1 -1
- package/dist/esm/biz-components/TextModal/index.js.map +1 -1
- package/dist/esm/biz-components/Title/index.js +1 -1
- package/dist/esm/biz-components/Title/index.js.map +2 -2
- package/dist/esm/biz-components/VideoModal/index.js +1 -1
- package/dist/esm/biz-components/VideoModal/index.js.map +2 -2
- package/dist/esm/biz-components/index.d.ts +57 -1
- package/dist/esm/biz-components/index.js +1 -1
- package/dist/esm/biz-components/index.js.map +3 -3
- package/dist/esm/components/ExposureDetector.d.ts +45 -0
- package/dist/esm/components/ExposureDetector.js +2 -0
- package/dist/esm/components/ExposureDetector.js.map +7 -0
- package/dist/esm/components/board.js +1 -1
- package/dist/esm/components/board.js.map +2 -2
- package/dist/esm/components/button.js.map +2 -2
- package/dist/esm/components/checkbox.d.ts +1 -0
- package/dist/esm/components/checkbox.js +1 -1
- package/dist/esm/components/checkbox.js.map +3 -3
- package/dist/esm/components/dialog.d.ts +1 -1
- package/dist/esm/components/dialog.js +1 -1
- package/dist/esm/components/dialog.js.map +2 -2
- package/dist/esm/components/index.d.ts +1 -0
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/index.js.map +3 -3
- package/dist/esm/components/loadingDots.js +1 -1
- package/dist/esm/components/loadingDots.js.map +2 -2
- package/dist/esm/components/picture.js +1 -1
- package/dist/esm/components/picture.js.map +2 -2
- package/dist/esm/cpn-components/CpnNavigation/index.js +1 -1
- package/dist/esm/cpn-components/CpnNavigation/index.js.map +2 -2
- package/dist/esm/cpn-components/CpnNavigation/types.d.ts +1 -0
- package/dist/esm/cpn-components/CpnNavigation/types.js +1 -0
- package/dist/esm/cpn-components/CpnNavigation/types.js.map +3 -3
- package/dist/esm/cpn-components/CpnProductCard/types.d.ts +1 -1
- package/dist/esm/helpers/utils.js.map +1 -1
- package/dist/esm/hooks/useExposure.js.map +2 -2
- package/dist/esm/hooks/useExposureDetection.d.ts +69 -0
- package/dist/esm/hooks/useExposureDetection.js +2 -0
- package/dist/esm/hooks/useExposureDetection.js.map +7 -0
- package/dist/esm/hooks/useIntersectionObserver.js.map +2 -2
- package/dist/esm/hooks/useRollout.js.map +2 -2
- package/dist/esm/stories/board.stories.d.ts +1 -1
- package/dist/esm/stories/board.stories.js +1 -1
- package/dist/esm/stories/board.stories.js.map +2 -2
- package/dist/esm/stories/carousel.stories.d.ts +3 -57
- package/dist/esm/stories/carousel.stories.js.map +2 -2
- package/dist/esm/stories/specs.stories.js.map +2 -2
- package/dist/tokens/anker.css +1 -0
- package/dist/tokens/base.css +1 -1
- package/dist/tokens/eufy.css +1 -0
- package/dist/tokens/eufyMake.css +1 -0
- package/dist/tokens/solix.css +1 -0
- package/dist/tokens/soundcore.css +1 -0
- package/package.json +9 -2
- package/style.css +0 -8
- package/tailwind.config.js +20 -0
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { type RefObject } from 'react';
|
|
2
|
+
export interface UseExposureDetectionOptions {
|
|
3
|
+
/**
|
|
4
|
+
* 唯一标识,用于判断是否已曝光
|
|
5
|
+
* 如果不提供,将使用元素的唯一标识(如果可能)
|
|
6
|
+
*/
|
|
7
|
+
exposureKey?: string;
|
|
8
|
+
/**
|
|
9
|
+
* 可见性阈值,0-1 之间,默认 0.5(50%)
|
|
10
|
+
*/
|
|
11
|
+
threshold?: number;
|
|
12
|
+
/**
|
|
13
|
+
* 停留时间(毫秒),默认 2000ms
|
|
14
|
+
*/
|
|
15
|
+
duration?: number;
|
|
16
|
+
/**
|
|
17
|
+
* 是否只触发一次,默认 true
|
|
18
|
+
*/
|
|
19
|
+
once?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* 曝光回调函数
|
|
22
|
+
*/
|
|
23
|
+
onExposure?: () => void;
|
|
24
|
+
/**
|
|
25
|
+
* IntersectionObserver 的 rootMargin
|
|
26
|
+
*/
|
|
27
|
+
rootMargin?: string;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* 曝光检测 Hook
|
|
31
|
+
* 使用 IntersectionObserver 检测元素是否至少 50% 可见且停留时间超过指定时间
|
|
32
|
+
* 确保在整个页面生命周期中只曝光一次
|
|
33
|
+
*
|
|
34
|
+
* @param elementRef - 要检测的元素的 ref
|
|
35
|
+
* @param options - 配置选项
|
|
36
|
+
* @returns 返回清除计时器的方法(用于切换时清理)
|
|
37
|
+
*
|
|
38
|
+
* @example
|
|
39
|
+
* ```tsx
|
|
40
|
+
* const MyComponent = () => {
|
|
41
|
+
* const ref = useRef<HTMLDivElement>(null)
|
|
42
|
+
* const { clearTimer } = useExposureDetection(ref, {
|
|
43
|
+
* exposureKey: 'my-component-1',
|
|
44
|
+
* threshold: 0.5,
|
|
45
|
+
* duration: 2000,
|
|
46
|
+
* onExposure: () => {
|
|
47
|
+
* console.log('元素已曝光')
|
|
48
|
+
* }
|
|
49
|
+
* })
|
|
50
|
+
*
|
|
51
|
+
* return <div ref={ref}>内容</div>
|
|
52
|
+
* }
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
export declare const useExposureDetection: (elementRef: RefObject<HTMLElement>, options?: UseExposureDetectionOptions) => {
|
|
56
|
+
clearTimer: () => void;
|
|
57
|
+
};
|
|
58
|
+
/**
|
|
59
|
+
* 清除指定 key 的曝光记录(用于测试或特殊场景)
|
|
60
|
+
*/
|
|
61
|
+
export declare const clearExposureRecord: (key: string) => void;
|
|
62
|
+
/**
|
|
63
|
+
* 清除所有曝光记录(用于测试或特殊场景)
|
|
64
|
+
*/
|
|
65
|
+
export declare const clearAllExposureRecords: () => void;
|
|
66
|
+
/**
|
|
67
|
+
* 检查指定 key 是否已曝光
|
|
68
|
+
*/
|
|
69
|
+
export declare const hasExposed: (key: string) => boolean;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var E=Object.defineProperty;var y=Object.getOwnPropertyDescriptor;var w=Object.getOwnPropertyNames;var T=Object.prototype.hasOwnProperty;var K=(e,r)=>{for(var o in r)E(e,o,{get:r[o],enumerable:!0})},O=(e,r,o,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let u of w(r))!T.call(e,u)&&u!==o&&E(e,u,{get:()=>r[u],enumerable:!(l=y(r,u))||l.enumerable});return e};var v=e=>O(E({},"__esModule",{value:!0}),e);var R={};K(R,{clearAllExposureRecords:()=>j,clearExposureRecord:()=>M,hasExposed:()=>A,useExposureDetection:()=>D});module.exports=v(R);var c=require("react");const i=new Set,D=(e,r={})=>{const{exposureKey:o,threshold:l=.5,duration:u=2e3,once:p=!0,onExposure:x,rootMargin:h="0px"}=r,t=(0,c.useRef)(null),d=(0,c.useRef)(null),m=(0,c.useCallback)(()=>{if(o)return o;if(e.current&&!d.current){const a=e.current.getAttribute("data-exposure-id");if(a)return d.current=a,a;const s=[];let n=e.current;for(;n&&n!==document.body;){const f=Array.from(n.parentElement?.children||[]).indexOf(n);s.unshift(`${n.tagName.toLowerCase()}[${f}]`),n=n.parentElement}return d.current=s.join(" > "),d.current}return d.current||""},[o,e]),g=(0,c.useCallback)(()=>{t.current&&(clearTimeout(t.current),t.current=null)},[]);return(0,c.useEffect)(()=>{const a=e.current;if(!a||!x)return;const s=m();if(!s){console.warn("useExposureDetection: \u65E0\u6CD5\u751F\u6210\u552F\u4E00\u7684 exposureKey\uFF0C\u8BF7\u63D0\u4F9B exposureKey \u53C2\u6570");return}if(p&&i.has(s))return;const n=new IntersectionObserver(f=>{f.forEach(b=>{b.intersectionRatio>=l?(!p||!i.has(s))&&!t.current&&(t.current=window.setTimeout(()=>{p&&i.has(s)||(p&&i.add(s),x())},u)):t.current&&(clearTimeout(t.current),t.current=null)})},{threshold:l,rootMargin:h});return n.observe(a),()=>{n.disconnect(),t.current&&(clearTimeout(t.current),t.current=null)}},[e,x,l,u,p,h,m]),{clearTimer:g}},M=e=>{i.delete(e)},j=()=>{i.clear()},A=e=>i.has(e);
|
|
2
|
+
//# sourceMappingURL=useExposureDetection.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/hooks/useExposureDetection.ts"],
|
|
4
|
+
"sourcesContent": ["import { type RefObject, useRef, useEffect, useCallback } from 'react'\n\n// \u5168\u5C40\u66DD\u5149\u8BB0\u5F55\uFF0C\u786E\u4FDD\u6BCF\u4E2A\u5143\u7D20\u5728\u6574\u4E2A\u9875\u9762\u751F\u547D\u5468\u671F\u4E2D\u53EA\u66DD\u5149\u4E00\u6B21\nconst exposedElementsSet = new Set<string>()\n\nexport interface UseExposureDetectionOptions {\n /**\n * \u552F\u4E00\u6807\u8BC6\uFF0C\u7528\u4E8E\u5224\u65AD\u662F\u5426\u5DF2\u66DD\u5149\n * \u5982\u679C\u4E0D\u63D0\u4F9B\uFF0C\u5C06\u4F7F\u7528\u5143\u7D20\u7684\u552F\u4E00\u6807\u8BC6\uFF08\u5982\u679C\u53EF\u80FD\uFF09\n */\n exposureKey?: string\n /**\n * \u53EF\u89C1\u6027\u9608\u503C\uFF0C0-1 \u4E4B\u95F4\uFF0C\u9ED8\u8BA4 0.5\uFF0850%\uFF09\n */\n threshold?: number\n /**\n * \u505C\u7559\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09\uFF0C\u9ED8\u8BA4 2000ms\n */\n duration?: number\n /**\n * \u662F\u5426\u53EA\u89E6\u53D1\u4E00\u6B21\uFF0C\u9ED8\u8BA4 true\n */\n once?: boolean\n /**\n * \u66DD\u5149\u56DE\u8C03\u51FD\u6570\n */\n onExposure?: () => void\n /**\n * IntersectionObserver \u7684 rootMargin\n */\n rootMargin?: string\n}\n\n/**\n * \u66DD\u5149\u68C0\u6D4B Hook\n * \u4F7F\u7528 IntersectionObserver \u68C0\u6D4B\u5143\u7D20\u662F\u5426\u81F3\u5C11 50% \u53EF\u89C1\u4E14\u505C\u7559\u65F6\u95F4\u8D85\u8FC7\u6307\u5B9A\u65F6\u95F4\n * \u786E\u4FDD\u5728\u6574\u4E2A\u9875\u9762\u751F\u547D\u5468\u671F\u4E2D\u53EA\u66DD\u5149\u4E00\u6B21\n *\n * @param elementRef - \u8981\u68C0\u6D4B\u7684\u5143\u7D20\u7684 ref\n * @param options - \u914D\u7F6E\u9009\u9879\n * @returns \u8FD4\u56DE\u6E05\u9664\u8BA1\u65F6\u5668\u7684\u65B9\u6CD5\uFF08\u7528\u4E8E\u5207\u6362\u65F6\u6E05\u7406\uFF09\n *\n * @example\n * ```tsx\n * const MyComponent = () => {\n * const ref = useRef<HTMLDivElement>(null)\n * const { clearTimer } = useExposureDetection(ref, {\n * exposureKey: 'my-component-1',\n * threshold: 0.5,\n * duration: 2000,\n * onExposure: () => {\n * console.log('\u5143\u7D20\u5DF2\u66DD\u5149')\n * }\n * })\n *\n * return <div ref={ref}>\u5185\u5BB9</div>\n * }\n * ```\n */\nexport const useExposureDetection = (elementRef: RefObject<HTMLElement>, options: UseExposureDetectionOptions = {}) => {\n const { exposureKey, threshold = 0.5, duration = 2000, once = true, onExposure, rootMargin = '0px' } = options\n\n const exposureTimerRef = useRef<number | null>(null)\n const generatedKeyRef = useRef<string | null>(null)\n\n // \u751F\u6210\u552F\u4E00\u7684\u66DD\u5149 key\n const getExposureKey = useCallback(() => {\n if (exposureKey) {\n return exposureKey\n }\n // \u5982\u679C\u6CA1\u6709\u63D0\u4F9B key\uFF0C\u5C1D\u8BD5\u4F7F\u7528\u5143\u7D20\u7684\u552F\u4E00\u6807\u8BC6\n if (elementRef.current && !generatedKeyRef.current) {\n // \u4F7F\u7528\u5143\u7D20\u7684 data-exposure-id \u5C5E\u6027\uFF0C\u6216\u8005\u751F\u6210\u4E00\u4E2A\u57FA\u4E8E\u4F4D\u7F6E\u7684 key\n const dataId = elementRef.current.getAttribute('data-exposure-id')\n if (dataId) {\n generatedKeyRef.current = dataId\n return dataId\n }\n // \u5982\u679C\u6CA1\u6709 data-exposure-id\uFF0C\u4F7F\u7528\u5143\u7D20\u5728 DOM \u4E2D\u7684\u4F4D\u7F6E\u751F\u6210 key\n const path: string[] = []\n let el: Element | null = elementRef.current\n while (el && el !== document.body) {\n const index = Array.from(el.parentElement?.children || []).indexOf(el)\n path.unshift(`${el.tagName.toLowerCase()}[${index}]`)\n el = el.parentElement\n }\n generatedKeyRef.current = path.join(' > ')\n return generatedKeyRef.current\n }\n return generatedKeyRef.current || ''\n }, [exposureKey, elementRef])\n\n // \u6E05\u9664\u8BA1\u65F6\u5668\u7684\u65B9\u6CD5\uFF08\u4E0D\u91CD\u7F6E\u66DD\u5149\u72B6\u6001\uFF09\n const clearTimer = useCallback(() => {\n if (exposureTimerRef.current) {\n clearTimeout(exposureTimerRef.current)\n exposureTimerRef.current = null\n }\n }, [])\n\n useEffect(() => {\n const element = elementRef.current\n if (!element || !onExposure) return\n\n const key = getExposureKey()\n if (!key) {\n console.warn('useExposureDetection: \u65E0\u6CD5\u751F\u6210\u552F\u4E00\u7684 exposureKey\uFF0C\u8BF7\u63D0\u4F9B exposureKey \u53C2\u6570')\n return\n }\n\n // \u5982\u679C\u5DF2\u7ECF\u66DD\u5149\u8FC7\u4E14\u8BBE\u7F6E\u4E86 once\uFF0C\u76F4\u63A5\u8FD4\u56DE\uFF0C\u4E0D\u518D\u76D1\u542C\n if (once && exposedElementsSet.has(key)) {\n return\n }\n\n const observer = new IntersectionObserver(\n entries => {\n entries.forEach(entry => {\n // \u5982\u679C\u53EF\u89C1\u6027\u8FBE\u5230\u9608\u503C\uFF08\u9ED8\u8BA4 50%\uFF09\n if (entry.intersectionRatio >= threshold) {\n // \u5982\u679C\u8FD8\u6CA1\u6709\u89E6\u53D1\u8FC7\u66DD\u5149\u4E14\u6CA1\u6709\u6B63\u5728\u8BA1\u65F6\u7684\u8BA1\u65F6\u5668\uFF0C\u5F00\u59CB\u8BA1\u65F6\n if ((!once || !exposedElementsSet.has(key)) && !exposureTimerRef.current) {\n exposureTimerRef.current = window.setTimeout(() => {\n // \u518D\u6B21\u68C0\u67E5\u662F\u5426\u5DF2\u66DD\u5149\uFF08\u9632\u6B62\u5728\u8BA1\u65F6\u671F\u95F4\u88AB\u5176\u4ED6\u64CD\u4F5C\u89E6\u53D1\uFF09\n if (once && exposedElementsSet.has(key)) return\n\n // \u6807\u8BB0\u4E3A\u5DF2\u66DD\u5149\n if (once) {\n exposedElementsSet.add(key)\n }\n // \u89E6\u53D1\u66DD\u5149\u4E8B\u4EF6\n onExposure()\n }, duration)\n }\n } else {\n // \u5982\u679C\u53EF\u89C1\u6027\u4F4E\u4E8E\u9608\u503C\uFF0C\u6E05\u9664\u8BA1\u65F6\u5668\uFF08\u4F46\u4E0D\u79FB\u9664\u66DD\u5149\u6807\u8BB0\uFF09\n if (exposureTimerRef.current) {\n clearTimeout(exposureTimerRef.current)\n exposureTimerRef.current = null\n }\n }\n })\n },\n {\n threshold: threshold,\n rootMargin: rootMargin,\n }\n )\n\n observer.observe(element)\n\n return () => {\n observer.disconnect()\n if (exposureTimerRef.current) {\n clearTimeout(exposureTimerRef.current)\n exposureTimerRef.current = null\n }\n }\n }, [elementRef, onExposure, threshold, duration, once, rootMargin, getExposureKey])\n\n return { clearTimer }\n}\n\n/**\n * \u6E05\u9664\u6307\u5B9A key \u7684\u66DD\u5149\u8BB0\u5F55\uFF08\u7528\u4E8E\u6D4B\u8BD5\u6216\u7279\u6B8A\u573A\u666F\uFF09\n */\nexport const clearExposureRecord = (key: string) => {\n exposedElementsSet.delete(key)\n}\n\n/**\n * \u6E05\u9664\u6240\u6709\u66DD\u5149\u8BB0\u5F55\uFF08\u7528\u4E8E\u6D4B\u8BD5\u6216\u7279\u6B8A\u573A\u666F\uFF09\n */\nexport const clearAllExposureRecords = () => {\n exposedElementsSet.clear()\n}\n\n/**\n * \u68C0\u67E5\u6307\u5B9A key \u662F\u5426\u5DF2\u66DD\u5149\n */\nexport const hasExposed = (key: string): boolean => {\n return exposedElementsSet.has(key)\n}\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,6BAAAE,EAAA,wBAAAC,EAAA,eAAAC,EAAA,yBAAAC,IAAA,eAAAC,EAAAN,GAAA,IAAAO,EAA+D,iBAG/D,MAAMC,EAAqB,IAAI,IAwDlBH,EAAuB,CAACI,EAAoCC,EAAuC,CAAC,IAAM,CACrH,KAAM,CAAE,YAAAC,EAAa,UAAAC,EAAY,GAAK,SAAAC,EAAW,IAAM,KAAAC,EAAO,GAAM,WAAAC,EAAY,WAAAC,EAAa,KAAM,EAAIN,EAEjGO,KAAmB,UAAsB,IAAI,EAC7CC,KAAkB,UAAsB,IAAI,EAG5CC,KAAiB,eAAY,IAAM,CACvC,GAAIR,EACF,OAAOA,EAGT,GAAIF,EAAW,SAAW,CAACS,EAAgB,QAAS,CAElD,MAAME,EAASX,EAAW,QAAQ,aAAa,kBAAkB,EACjE,GAAIW,EACF,OAAAF,EAAgB,QAAUE,EACnBA,EAGT,MAAMC,EAAiB,CAAC,EACxB,IAAIC,EAAqBb,EAAW,QACpC,KAAOa,GAAMA,IAAO,SAAS,MAAM,CACjC,MAAMC,EAAQ,MAAM,KAAKD,EAAG,eAAe,UAAY,CAAC,CAAC,EAAE,QAAQA,CAAE,EACrED,EAAK,QAAQ,GAAGC,EAAG,QAAQ,YAAY,CAAC,IAAIC,CAAK,GAAG,EACpDD,EAAKA,EAAG,aACV,CACA,OAAAJ,EAAgB,QAAUG,EAAK,KAAK,KAAK,EAClCH,EAAgB,OACzB,CACA,OAAOA,EAAg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exports", "__export", "clearAllExposureRecords", "clearExposureRecord", "hasExposed", "useExposureDetection", "__toCommonJS", "import_react", "exposedElementsSet", "elementRef", "options", "exposureKey", "threshold", "duration", "once", "onExposure", "rootMargin", "exposureTimerRef", "generatedKeyRef", "getExposureKey", "dataId", "path", "el", "index", "clearTimer", "element", "key", "observer", "entries", "entry"]
|
|
7
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/hooks/useIntersectionObserver.ts"],
|
|
4
|
-
"sourcesContent": ["import { type RefObject, useRef, useEffect } from 'react'\n\ntype DelayOptions = {\n callback: () => void\n once?: boolean\n threshold?: number\n delay?: number\n}\n\n// \u7F13\u5B58\u53EF\u89C1\u6027\u68C0\u67E5\u7ED3\u679C\uFF0C\u907F\u514D\u91CD\u590D\u8BA1\u7B97\nconst visibilityCache = new WeakMap<Element, { visible: boolean; timestamp: number }>()\nconst CACHE_DURATION = 500 // \u7F13\u5B58500ms\uFF0C\u5E73\u8861\u6027\u80FD\u548C\u51C6\u786E\u6027\n\n/**\n * \u68C0\u67E5\u5143\u7D20\u662F\u5426\u771F\u6B63\u53EF\u89C1\uFF08\u4F18\u5316\u7248\u672C\uFF0C\u5E26\u7F13\u5B58\uFF09\n * @param element \u8981\u68C0\u67E5\u7684\u5143\u7D20\n * @returns \u5143\u7D20\u662F\u5426\u53EF\u89C1\n */\nconst isElementVisible = (element: Element): boolean => {\n const now = Date.now()\n
|
|
5
|
-
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kCAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAkD,iBAUlD,MAAMC,EAAkB,IAAI,QACtBC,EAAiB,IAOjBC,EAAoBC,GAA8B,CACtD,MAAMC,EAAM,KAAK,IAAI,EAGfC,EAASL,EAAgB,IAAIG,CAAO,EAC1C,GAAIE,
|
|
4
|
+
"sourcesContent": ["import { type RefObject, useRef, useEffect } from 'react'\n\ntype DelayOptions = {\n callback: () => void\n once?: boolean\n threshold?: number\n delay?: number\n}\n\n// \u7F13\u5B58\u53EF\u89C1\u6027\u68C0\u67E5\u7ED3\u679C\uFF0C\u907F\u514D\u91CD\u590D\u8BA1\u7B97\nconst visibilityCache = new WeakMap<Element, { visible: boolean; timestamp: number }>()\nconst CACHE_DURATION = 500 // \u7F13\u5B58500ms\uFF0C\u5E73\u8861\u6027\u80FD\u548C\u51C6\u786E\u6027\n\n/**\n * \u68C0\u67E5\u5143\u7D20\u662F\u5426\u771F\u6B63\u53EF\u89C1\uFF08\u4F18\u5316\u7248\u672C\uFF0C\u5E26\u7F13\u5B58\uFF09\n * @param element \u8981\u68C0\u67E5\u7684\u5143\u7D20\n * @returns \u5143\u7D20\u662F\u5426\u53EF\u89C1\n */\nconst isElementVisible = (element: Element): boolean => {\n const now = Date.now()\n\n // \u68C0\u67E5\u7F13\u5B58\n const cached = visibilityCache.get(element)\n if (cached && now - cached.timestamp < CACHE_DURATION) {\n return cached.visible\n }\n\n const el = element as HTMLElement\n\n // \u5FEB\u901F\u68C0\u67E5\uFF1A\u5143\u7D20\u662F\u5426\u5B58\u5728\n if (!el) {\n visibilityCache.set(element, { visible: false, timestamp: now })\n return false\n }\n\n // \u5FEB\u901F\u68C0\u67E5\uFF1A\u5143\u7D20\u662F\u5426\u5728DOM\u4E2D\n if (!document.contains(el)) {\n visibilityCache.set(element, { visible: false, timestamp: now })\n return false\n }\n\n // \u4F7F\u7528 getBoundingClientRect \u8FDB\u884C\u5FEB\u901F\u68C0\u67E5\uFF08\u6BD4 getComputedStyle \u66F4\u5FEB\uFF09\n const rect = el.getBoundingClientRect()\n\n // \u5982\u679C\u5143\u7D20\u6CA1\u6709\u5C3A\u5BF8\uFF0C\u76F4\u63A5\u8FD4\u56DE false\uFF08\u8FD9\u6BD4\u68C0\u67E5 CSS \u6837\u5F0F\u66F4\u5FEB\uFF09\n if (rect.width === 0 || rect.height === 0) {\n visibilityCache.set(element, { visible: false, timestamp: now })\n return false\n }\n\n // \u53EA\u6709\u5728\u5FC5\u8981\u65F6\u624D\u68C0\u67E5 CSS \u6837\u5F0F\uFF08\u5EF6\u8FDF\u68C0\u67E5\uFF09\n // \u5148\u68C0\u67E5\u6700\u5E38\u89C1\u7684\u9690\u85CF\u60C5\u51B5\n const style = el.style\n if (style.display === 'none' || style.visibility === 'hidden' || style.opacity === '0') {\n visibilityCache.set(element, { visible: false, timestamp: now })\n return false\n }\n\n // \u5982\u679C\u5185\u8054\u6837\u5F0F\u6CA1\u6709\u9690\u85CF\uFF0C\u518D\u68C0\u67E5\u8BA1\u7B97\u6837\u5F0F\uFF08\u66F4\u6602\u8D35\u7684\u64CD\u4F5C\uFF09\n // \u4F46\u53EA\u5728\u5143\u7D20\u786E\u5B9E\u6709\u5C3A\u5BF8\u4E14\u5728\u89C6\u53E3\u5185\u65F6\u624D\u68C0\u67E5\n if (rect.width > 0 && rect.height > 0) {\n const computedStyle = window.getComputedStyle(el)\n if (computedStyle.display === 'none' || computedStyle.visibility === 'hidden' || computedStyle.opacity === '0') {\n visibilityCache.set(element, { visible: false, timestamp: now })\n return false\n }\n }\n\n const visible = true\n visibilityCache.set(element, { visible, timestamp: now })\n return visible\n}\n/**\n * \u53EA\u6709\u63D0\u7559\u8D85\u8FC7delay\u8BBE\u7F6E\u7684\u65F6\u95F4\u624D\u4F1A\u89E6\u53D1callback\n * @param targetRef\n * @param callback\n * @param once\n * @param threshold\n * @param delay\n */\nexport const useIntersectionObserverDelay = (\n targetRef: RefObject<any> | undefined,\n { callback, once, threshold = 0.8, delay = 0 }: DelayOptions\n) => {\n const timeoutRef = useRef<number>(0)\n const triggeredRef = useRef(false)\n\n useEffect(() => {\n if (!targetRef?.current) {\n return\n }\n\n if (typeof IntersectionObserver === 'undefined') {\n return\n }\n\n const current = targetRef.current\n const options = {\n root: null,\n rootMargin: '0px',\n threshold: threshold,\n }\n const observer = new IntersectionObserver(entries => {\n entries.forEach(entry => {\n if (entry.isIntersecting && isElementVisible(entry.target)) {\n if (delay) {\n window.clearTimeout(timeoutRef.current)\n if (triggeredRef.current) return\n timeoutRef.current = window.setTimeout(() => {\n callback()\n triggeredRef.current = true\n }, delay)\n } else {\n callback()\n triggeredRef.current = true\n }\n\n if (once && triggeredRef.current) {\n observer.disconnect()\n }\n } else {\n if (timeoutRef.current) {\n window.clearTimeout(timeoutRef.current)\n }\n }\n })\n }, options)\n if (current) {\n observer.observe(current)\n }\n return () => {\n observer.disconnect()\n window.clearTimeout(timeoutRef.current)\n }\n }, [once, threshold, delay, targetRef?.current])\n}\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kCAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAkD,iBAUlD,MAAMC,EAAkB,IAAI,QACtBC,EAAiB,IAOjBC,EAAoBC,GAA8B,CACtD,MAAMC,EAAM,KAAK,IAAI,EAGfC,EAASL,EAAgB,IAAIG,CAAO,EAC1C,GAAIE,GAAUD,EAAMC,EAAO,UAAYJ,EACrC,OAAOI,EAAO,QAGhB,MAAMC,EAAKH,EAGX,GAAI,CAACG,EACH,OAAAN,EAAgB,IAAIG,EAAS,CAAE,QAAS,GAAO,UAAWC,CAAI,CAAC,EACxD,GAIT,GAAI,CAAC,SAAS,SAASE,CAAE,EACvB,OAAAN,EAAgB,IAAIG,EAAS,CAAE,QAAS,GAAO,UAAWC,CAAI,CAAC,EACxD,GAIT,MAAMG,EAAOD,EAAG,sBAAsB,EAGtC,GAAIC,EAAK,QAAU,GAAKA,EAAK,SAAW,EACtC,OAAAP,EAAgB,IAAIG,EAAS,CAAE,QAAS,GAAO,UAAWC,CAAI,CAAC,EACxD,GAKT,MAAMI,EAAQF,EAAG,MACjB,GAAIE,EAAM,UAAY,QAAUA,EAAM,aAAe,UAAYA,EAAM,UAAY,IACjF,OAAAR,EAAgB,IAAIG,EAAS,CAAE,QAAS,GAAO,UAAWC,CAAI,CAAC,EACxD,GAKT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EAAOJ,GAAW,OAAO,CAAC,CACjD",
|
|
6
6
|
"names": ["useIntersectionObserver_exports", "__export", "useIntersectionObserverDelay", "__toCommonJS", "import_react", "visibilityCache", "CACHE_DURATION", "isElementVisible", "element", "now", "cached", "el", "rect", "style", "computedStyle", "visible", "targetRef", "callback", "once", "threshold", "delay", "timeoutRef", "triggeredRef", "current", "options", "observer", "entries", "entry"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/hooks/useRollout.ts"],
|
|
4
|
-
"sourcesContent": ["import { useEffect, useRef, useState, type MutableRefObject } from 'react'\n\nexport function useRollout<T extends HTMLElement = HTMLElement>(
|
|
5
|
-
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,gBAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAmE,iBAE5D,SAASF,
|
|
4
|
+
"sourcesContent": ["import { useEffect, useRef, useState, type MutableRefObject } from 'react'\n\nexport function useRollout<T extends HTMLElement = HTMLElement>(options: any): [MutableRefObject<T | null>, boolean] {\n const ref = useRef<T>(null)\n const [inView, setInView] = useState(false)\n useEffect(() => {\n if (inView) return // \u5DF2\u8FDB\u5165\u8FC7\uFF0C\u5219\u4E0D\u518D\u89C2\u5BDF\n const el = ref.current\n if (!el || typeof IntersectionObserver === 'undefined') return\n const observer = new IntersectionObserver(([entry]) => {\n if (entry.isIntersecting) {\n setInView(true)\n observer.disconnect() // \u505C\u6B62\u89C2\u5BDF\n }\n }, options)\n observer.observe(el)\n return () => observer.disconnect()\n }, [inView, options])\n return [ref, inView]\n}\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,gBAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAmE,iBAE5D,SAASF,EAAgDG,EAAqD,CACnH,MAAMC,KAAM,UAAU,IAAI,EACpB,CAACC,EAAQC,CAAS,KAAI,YAAS,EAAK,EAC1C,sBAAU,IAAM,CACd,GAAID,EAAQ,OACZ,MAAME,EAAKH,EAAI,QACf,GAAI,CAACG,GAAM,OAAO,qBAAyB,IAAa,OACxD,MAAMC,EAAW,IAAI,qBAAqB,CAAC,CAACC,CAAK,IAAM,CACjDA,EAAM,iBACRH,EAAU,EAAI,EACdE,EAAS,WAAW,EAExB,EAAGL,CAAO,EACV,OAAAK,EAAS,QAAQD,CAAE,EACZ,IAAMC,EAAS,WAAW,CACnC,EAAG,CAACH,EAAQF,CAAO,CAAC,EACb,CAACC,EAAKC,CAAM,CACrB",
|
|
6
6
|
"names": ["useRollout_exports", "__export", "useRollout", "__toCommonJS", "import_react", "options", "ref", "inView", "setInView", "el", "observer", "entry"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var m=Object.create;var a=Object.defineProperty;var n=Object.getOwnPropertyDescriptor;var s=Object.getOwnPropertyNames;var c=Object.getPrototypeOf,B=Object.prototype.hasOwnProperty;var S=(o,t)=>{for(var r in t)a(o,r,{get:t[r],enumerable:!0})},d=(o,t,r,y)=>{if(t&&typeof t=="object"||typeof t=="function")for(let e of s(t))!B.call(o,e)&&e!==r&&a(o,e,{get:()=>t[e],enumerable:!(y=n(t,e))||y.enumerable});return o};var b=(o,t,r)=>(r=o!=null?m(c(o)):{},d(t||!o||!o.__esModule?a(r,"default",{value:o,enumerable:!0}):r,o)),l=o=>d(a({},"__esModule",{value:!0}),o);var O={};S(O,{Default:()=>M,default:()=>u});module.exports=l(O);var f=require("react/jsx-runtime"),p=b(require("../components/board"));const i={title:"Components/Board",component:p.default,tags:["autodocs"]};var u=i;const M={render:()=>(0,f.jsx)(p.default,{})};
|
|
1
|
+
"use strict";var m=Object.create;var a=Object.defineProperty;var n=Object.getOwnPropertyDescriptor;var s=Object.getOwnPropertyNames;var c=Object.getPrototypeOf,B=Object.prototype.hasOwnProperty;var S=(o,t)=>{for(var r in t)a(o,r,{get:t[r],enumerable:!0})},d=(o,t,r,y)=>{if(t&&typeof t=="object"||typeof t=="function")for(let e of s(t))!B.call(o,e)&&e!==r&&a(o,e,{get:()=>t[e],enumerable:!(y=n(t,e))||y.enumerable});return o};var b=(o,t,r)=>(r=o!=null?m(c(o)):{},d(t||!o||!o.__esModule?a(r,"default",{value:o,enumerable:!0}):r,o)),l=o=>d(a({},"__esModule",{value:!0}),o);var O={};S(O,{Default:()=>M,default:()=>u});module.exports=l(O);var f=require("react/jsx-runtime"),p=b(require("../components/board.js"));const i={title:"Components/Board",component:p.default,tags:["autodocs"]};var u=i;const M={render:()=>(0,f.jsx)(p.default,{})};
|
|
2
2
|
//# sourceMappingURL=board.stories.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/stories/board.stories.tsx"],
|
|
4
|
-
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\nimport Board from '../components/board'\n\nconst meta: Meta<typeof Board> = {\n title: 'Components/Board',\n component: Board,\n tags: ['autodocs'],\n}\n\nexport default meta\n\ntype Story = StoryObj<typeof Board>\n\nexport const Default: Story = {\n render: () => <Board />,\n}"],
|
|
5
|
-
"mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GAcgB,IAAAK,EAAA,6BAbhBC,EAAkB,
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\nimport Board from '../components/board.js'\n\nconst meta: Meta<typeof Board> = {\n title: 'Components/Board',\n component: Board,\n tags: ['autodocs'],\n}\n\nexport default meta\n\ntype Story = StoryObj<typeof Board>\n\nexport const Default: Story = {\n render: () => <Board />,\n}\n"],
|
|
5
|
+
"mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GAcgB,IAAAK,EAAA,6BAbhBC,EAAkB,qCAElB,MAAMC,EAA2B,CAC/B,MAAO,mBACP,UAAW,EAAAC,QACX,KAAM,CAAC,UAAU,CACnB,EAEA,IAAOL,EAAQI,EAIR,MAAML,EAAiB,CAC5B,OAAQ,OAAM,OAAC,EAAAM,QAAA,EAAM,CACvB",
|
|
6
6
|
"names": ["board_stories_exports", "__export", "Default", "board_stories_default", "__toCommonJS", "import_jsx_runtime", "import_board", "meta", "Board"]
|
|
7
7
|
}
|
|
@@ -1,60 +1,6 @@
|
|
|
1
|
-
import type { StoryObj } from '@storybook/react';
|
|
2
|
-
import
|
|
3
|
-
declare const meta:
|
|
4
|
-
title: string;
|
|
5
|
-
component: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & {
|
|
6
|
-
showNavigation?: boolean;
|
|
7
|
-
navigationPosition?: "inner" | "outter";
|
|
8
|
-
opts?: Partial<import("node_modules/embla-carousel/esm/components/Options.js").OptionsType> | undefined;
|
|
9
|
-
plugins?: import("embla-carousel").CreatePluginType<import("node_modules/embla-carousel/esm/components/Plugins.js").LoosePluginType, {}>[] | undefined;
|
|
10
|
-
orientation?: "horizontal" | "vertical";
|
|
11
|
-
setApi?: (api: import("../index.js").CarouselApi) => void;
|
|
12
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
-
subcomponents: {
|
|
14
|
-
CarouselContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
15
|
-
CarouselItem: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
-
};
|
|
17
|
-
parameters: {
|
|
18
|
-
layout: string;
|
|
19
|
-
docs: {
|
|
20
|
-
description: {
|
|
21
|
-
component: string;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
24
|
-
};
|
|
25
|
-
tags: string[];
|
|
26
|
-
argTypes: {
|
|
27
|
-
opts: {
|
|
28
|
-
description: string;
|
|
29
|
-
control: {
|
|
30
|
-
type: "object";
|
|
31
|
-
};
|
|
32
|
-
};
|
|
33
|
-
showNavigation: {
|
|
34
|
-
description: string;
|
|
35
|
-
control: {
|
|
36
|
-
type: "boolean";
|
|
37
|
-
};
|
|
38
|
-
};
|
|
39
|
-
orientation: {
|
|
40
|
-
description: string;
|
|
41
|
-
control: {
|
|
42
|
-
type: "select";
|
|
43
|
-
};
|
|
44
|
-
options: string[];
|
|
45
|
-
};
|
|
46
|
-
setApi: {
|
|
47
|
-
description: string;
|
|
48
|
-
};
|
|
49
|
-
plugins: {
|
|
50
|
-
description: string;
|
|
51
|
-
};
|
|
52
|
-
};
|
|
53
|
-
args: {
|
|
54
|
-
opts: {};
|
|
55
|
-
orientation: "horizontal";
|
|
56
|
-
};
|
|
57
|
-
};
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Carousel } from '../components/index.js';
|
|
3
|
+
declare const meta: Meta<typeof Carousel>;
|
|
58
4
|
export default meta;
|
|
59
5
|
type Story = StoryObj<typeof meta>;
|
|
60
6
|
export declare const Default: Story;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/stories/carousel.stories.tsx"],
|
|
4
|
-
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\nimport {\n Carousel,\n CarouselContent,\n CarouselItem,\n CarouselNext,\n CarouselPrevious,\n Card,\n CardContent,\n} from '../components/index.js'\n\nimport React from 'react'\n\nconst meta = {\n title: 'Components/Carousel',\n component: Carousel,\n subcomponents: {\n CarouselContent,\n CarouselItem,\n },\n parameters: {\n layout: 'fullscreen',\n docs: {\n description: {\n component: '\u8F6E\u64AD\u7EC4\u4EF6, \u57FA\u4E8E\u8F7B\u91CF\u7EA7\u7EC4\u4EF6embla-carousel-react, https://www.embla-carousel.com/get-started/react/',\n },\n },\n },\n tags: ['autodocs'],\n argTypes: {\n opts: {\n description:\n 'embla-carousel-react \u7684\u914D\u7F6E\u53C2\u6570, \u53EF\u4EE5\u914D\u7F6Eloop: true \u5F00\u542F\u5FAA\u73AF\uFF0Calign: center | start | end \u5BF9\u9F50\u65B9\u5F0F\uFF0C \u67E5\u770B https://www.embla-carousel.com/api/options/',\n control: {\n type: 'object',\n },\n },\n showNavigation: {\n description: '\u662F\u5426\u663E\u793A\u5BFC\u822A\u70B9',\n control: {\n type: 'boolean',\n },\n },\n orientation: {\n description: '\u8F6E\u64AD\u65B9\u5411',\n control: {\n type: 'select',\n },\n options: ['horizontal', 'vertical'],\n },\n setApi: {\n description: '\u8BBE\u7F6Eapi, \u53EF\u4EE5\u901A\u8FC7\u8FD9\u4E2A\u51FD\u6570\u83B7\u53D6carousel API \u5B9E\u4F8B\uFF0C\u62FF\u5230api \u5B9E\u4F8B\u540E,\u53EF\u4EE5\u8C03\u7528api \u5B9E\u4F8B\u7684\u65B9\u6CD5\u6216\u8005\u5C5E\u6027',\n },\n plugins: {\n description:\n 'embla-carousel-react \u7684\u63D2\u4EF6,embla-carousel \u7684 Autoplay, Wheel Gesture \u7B49\u9AD8\u7EA7\u529F\u80FD \u901A\u8FC7\u63D2\u4EF6\u652F\u6301 https://www.embla-carousel.com/plugins/',\n },\n },\n args: {\n opts: {},\n orientation: 'horizontal',\n },\n} satisfies Meta<typeof Carousel>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Default: Story = {\n args: {\n opts: {\n align: 'start',\n },\n children: (\n <>\n <CarouselContent>\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/3\">\n <div className=\"p-1\">\n <Card>\n <CardContent className=\"flex aspect-square items-center justify-center p-6\">\n <span className=\"text-3xl font-semibold\">{index + 1}</span>\n </CardContent>\n </Card>\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious />\n <CarouselNext />\n </>\n ),\n },\n}\n\nexport const Vertical: Story = {\n render() {\n return (\n <Carousel\n opts={{\n align: 'start',\n }}\n orientation=\"vertical\"\n className=\"w-full max-w-xs\"\n >\n <CarouselContent className=\"-mt-1 h-[200px]\">\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/2 pt-1\">\n <div className=\"p-1\">\n <Card>\n <CardContent className=\"flex aspect-square items-center justify-center p-6\">\n <span className=\"text-3xl font-semibold\">{index + 1}</span>\n </CardContent>\n </Card>\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious />\n <CarouselNext />\n </Carousel>\n )\n },\n}\n\nconst images = [\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_mo_path_1.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_1_mo_never_missing.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_mo_path_1.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388.png?v=1741689169',\n]\nexport const OverrideClassName: Story = {\n render() {\n return (\n <Carousel\n opts={{\n loop: true,\n align: 'center',\n }}\n showNavigation={true}\n navigationPosition=\"outter\"\n className=\"w-full max-w-xl\"\n >\n <CarouselContent className=\"\">\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/2\">\n <div className=\"p-1\">\n <img src={images[index]} alt=\"\" />\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious className=\"left-4\" />\n <CarouselNext className=\"right-4\" />\n </Carousel>\n )\n },\n}\nOverrideClassName.parameters = {\n layout: 'padded',\n}\n"],
|
|
5
|
-
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,sBAAAC,EAAA,aAAAC,EAAA,YAAAC,IAAA,eAAAC,EAAAN,GAyEM,IAAAO,EAAA,6BAxENC,EAQO,kCAEPC,EAAkB,iBAElB,MAAMC,
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\nimport {\n Carousel,\n CarouselContent,\n CarouselItem,\n CarouselNext,\n CarouselPrevious,\n Card,\n CardContent,\n} from '../components/index.js'\n\nimport React from 'react'\n\nconst meta: Meta<typeof Carousel> = {\n title: 'Components/Carousel',\n component: Carousel,\n subcomponents: {\n CarouselContent,\n CarouselItem,\n },\n parameters: {\n layout: 'fullscreen',\n docs: {\n description: {\n component: '\u8F6E\u64AD\u7EC4\u4EF6, \u57FA\u4E8E\u8F7B\u91CF\u7EA7\u7EC4\u4EF6embla-carousel-react, https://www.embla-carousel.com/get-started/react/',\n },\n },\n },\n tags: ['autodocs'],\n argTypes: {\n opts: {\n description:\n 'embla-carousel-react \u7684\u914D\u7F6E\u53C2\u6570, \u53EF\u4EE5\u914D\u7F6Eloop: true \u5F00\u542F\u5FAA\u73AF\uFF0Calign: center | start | end \u5BF9\u9F50\u65B9\u5F0F\uFF0C \u67E5\u770B https://www.embla-carousel.com/api/options/',\n control: {\n type: 'object',\n },\n },\n showNavigation: {\n description: '\u662F\u5426\u663E\u793A\u5BFC\u822A\u70B9',\n control: {\n type: 'boolean',\n },\n },\n orientation: {\n description: '\u8F6E\u64AD\u65B9\u5411',\n control: {\n type: 'select',\n },\n options: ['horizontal', 'vertical'],\n },\n setApi: {\n description: '\u8BBE\u7F6Eapi, \u53EF\u4EE5\u901A\u8FC7\u8FD9\u4E2A\u51FD\u6570\u83B7\u53D6carousel API \u5B9E\u4F8B\uFF0C\u62FF\u5230api \u5B9E\u4F8B\u540E,\u53EF\u4EE5\u8C03\u7528api \u5B9E\u4F8B\u7684\u65B9\u6CD5\u6216\u8005\u5C5E\u6027',\n },\n plugins: {\n description:\n 'embla-carousel-react \u7684\u63D2\u4EF6,embla-carousel \u7684 Autoplay, Wheel Gesture \u7B49\u9AD8\u7EA7\u529F\u80FD \u901A\u8FC7\u63D2\u4EF6\u652F\u6301 https://www.embla-carousel.com/plugins/',\n },\n },\n args: {\n opts: {},\n orientation: 'horizontal',\n },\n} satisfies Meta<typeof Carousel>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Default: Story = {\n args: {\n opts: {\n align: 'start',\n },\n children: (\n <>\n <CarouselContent>\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/3\">\n <div className=\"p-1\">\n <Card>\n <CardContent className=\"flex aspect-square items-center justify-center p-6\">\n <span className=\"text-3xl font-semibold\">{index + 1}</span>\n </CardContent>\n </Card>\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious />\n <CarouselNext />\n </>\n ),\n },\n}\n\nexport const Vertical: Story = {\n render() {\n return (\n <Carousel\n opts={{\n align: 'start',\n }}\n orientation=\"vertical\"\n className=\"w-full max-w-xs\"\n >\n <CarouselContent className=\"-mt-1 h-[200px]\">\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/2 pt-1\">\n <div className=\"p-1\">\n <Card>\n <CardContent className=\"flex aspect-square items-center justify-center p-6\">\n <span className=\"text-3xl font-semibold\">{index + 1}</span>\n </CardContent>\n </Card>\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious />\n <CarouselNext />\n </Carousel>\n )\n },\n}\n\nconst images = [\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_mo_path_1.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_1_mo_never_missing.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388_mo_path_1.png?v=1741689169',\n 'https://cdn.shopify.com/s/files/1/0521/9411/5753/files/Frame_1312320388.png?v=1741689169',\n]\nexport const OverrideClassName: Story = {\n render() {\n return (\n <Carousel\n opts={{\n loop: true,\n align: 'center',\n }}\n showNavigation={true}\n navigationPosition=\"outter\"\n className=\"w-full max-w-xl\"\n >\n <CarouselContent className=\"\">\n {Array.from({ length: 5 }).map((_, index) => (\n <CarouselItem key={index} className=\"basis-1/2\">\n <div className=\"p-1\">\n <img src={images[index]} alt=\"\" />\n </div>\n </CarouselItem>\n ))}\n </CarouselContent>\n <CarouselPrevious className=\"left-4\" />\n <CarouselNext className=\"right-4\" />\n </Carousel>\n )\n },\n}\nOverrideClassName.parameters = {\n layout: 'padded',\n}\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,sBAAAC,EAAA,aAAAC,EAAA,YAAAC,IAAA,eAAAC,EAAAN,GAyEM,IAAAO,EAAA,6BAxENC,EAQO,kCAEPC,EAAkB,iBAElB,MAAMC,EAA8B,CAClC,MAAO,sBACP,UAAW,WACX,cAAe,CACb,kCACA,2BACF,EACA,WAAY,CACV,OAAQ,aACR,KAAM,CACJ,YAAa,CACX,UAAW,6IACb,CACF,CACF,EACA,KAAM,CAAC,UAAU,EACjB,SAAU,CACR,KAAM,CACJ,YACE,4OACF,QAAS,CACP,KAAM,QACR,CACF,EACA,eAAgB,CACd,YAAa,6CACb,QAAS,CACP,KAAM,SACR,CACF,EACA,YAAa,CACX,YAAa,2BACb,QAAS,CACP,KAAM,QACR,EACA,QAAS,CAAC,aAAc,UAAU,CACpC,EACA,OAAQ,CACN,YAAa,mOACf,EACA,QAAS,CACP,YACE,oMACJ,CACF,EACA,KAAM,CACJ,KAAM,CAAC,EACP,YAAa,YACf,CACF,EAEA,IAAOL,EAAQK,EAGR,MAAMR,EAAiB,CAC5B,KAAM,CACJ,KAAM,CACJ,MAAO,OACT,EACA,YACE,oBACE,oBAAC,mBACE,eAAM,KAAK,CAAE,OAAQ,CAAE,CAAC,EAAE,IAAI,CAACS,EAAGC,OACjC,OAAC,gBAAyB,UAAU,YAClC,mBAAC,OAAI,UAAU,MACb,mBAAC,QACC,mBAAC,eAAY,UAAU,qDACrB,mBAAC,QAAK,UAAU,yBAA0B,SAAAA,EAAQ,EAAE,EACtD,EACF,EACF,GAPiBA,CAQnB,CACD,EACH,KACA,OAAC,qBAAiB,KAClB,OAAC,iBAAa,GAChB,CAEJ,CACF,EAEaR,EAAkB,CAC7B,QAAS,CACP,SACE,QAAC,YACC,KAAM,CACJ,MAAO,OACT,EACA,YAAY,WACZ,UAAU,kBAEV,oBAAC,mBAAgB,UAAU,kBACxB,eAAM,KAAK,CAAE,OAAQ,CAAE,CAAC,EAAE,IAAI,CAACO,EAAGC,OACjC,OAAC,gBAAyB,UAAU,iBAClC,mBAAC,OAAI,UAAU,MACb,mBAAC,QACC,mBAAC,eAAY,UAAU,qDACrB,mBAAC,QAAK,UAAU,yBAA0B,SAAAA,EAAQ,EAAE,EACtD,EACF,EACF,GAPiBA,CAQnB,CACD,EACH,KACA,OAAC,qBAAiB,KAClB,OAAC,iBAAa,GAChB,CAEJ,CACF,EAEMC,EAAS,CACb,qGACA,2FACA,8GACA,qGACA,0FACF,EACaV,EAA2B,CACtC,QAAS,CACP,SACE,QAAC,YACC,KAAM,CACJ,KAAM,GACN,MAAO,QACT,EACA,eAAgB,GAChB,mBAAmB,SACnB,UAAU,kBAEV,oBAAC,mBAAgB,UAAU,GACxB,eAAM,KAAK,CAAE,OAAQ,CAAE,CAAC,EAAE,IAAI,CAACQ,EAAGC,OACjC,OAAC,gBAAyB,UAAU,YAClC,mBAAC,OAAI,UAAU,MACb,mBAAC,OAAI,IAAKC,EAAOD,CAAK,EAAG,IAAI,GAAG,EAClC,GAHiBA,CAInB,CACD,EACH,KACA,OAAC,oBAAiB,UAAU,SAAS,KACrC,OAAC,gBAAa,UAAU,UAAU,GACpC,CAEJ,CACF,EACAT,EAAkB,WAAa,CAC7B,OAAQ,QACV",
|
|
6
6
|
"names": ["carousel_stories_exports", "__export", "Default", "OverrideClassName", "Vertical", "carousel_stories_default", "__toCommonJS", "import_jsx_runtime", "import_components", "import_react", "meta", "_", "index", "images"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/stories/specs.stories.tsx"],
|
|
4
|
-
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\n\nimport Specs from '../biz-components/Specs/index.js'\nimport { Container } from '../components/container.js'\n\nconst meta = {\n title: 'Biz-Components/Specs',\n component: Specs,\n parameters: {\n layout: 'fullscreen',\n },\n tags: ['autodocs'],\n} satisfies Meta<typeof Specs>\n\nexport default meta\n\ntype Story = StoryObj<typeof meta>\n\nconst data = {\n id: '68ea29e5ca34138c04aec30f',\n display: 'visible',\n items: [\n {\n sku: 'A1340011',\n name: 'Anker <b>325</b> Power Bank (PowerCore 20K)',\n image:\n 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1268013_1_2430b504-15c6-441e-9914-ae215095e8b4.png?v=1753755824',\n value: 'a1340-250w-power-bank',\n handle: 'a1340-250w-power-bank',\n },\n {\n sku: 'A2524014',\n name: 'Anker <b>337</b> Power Bank (PowerCore 26K)',\n image: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1277011_V1.png?v=1753755956',\n value: 'a2524',\n handle: 'a2524',\n shopify_id: '10034291441848',\n },\n ],\n data: {\n LeftMenu: {\n data: [\n {\n title: 'Product',\n subTitle: [\n 'Clean Types',\n 'Portable Deep Cleaner',\n 'HydroJet\u2122 Mopping System',\n 'Mop Type',\n 'Downward Pressure',\n 'Rotations Per Minute',\n 'Suction Power',\n 'Auto-Detangling',\n 'Obstacle Avoidance',\n 'Omni Station',\n 'Obstacle Clearance Height',\n 'Minimum Height and Width Restrictions',\n 'Robot/Station',\n 'Run Time',\n 'App Control',\n 'Bluetooth',\n 'Wi-Fi',\n ],\n isProduct: true,\n },\n ],\n },\n RightMenu: {\n menus: [\n {\n sku: 'A1340011',\n handle: 'a1340-250w-power-bank',\n subTitle: {\n 'Wi-Fi': '\u2705',\n 'Mop Type': 'Rolling Mop',\n 'Run Time': 'Vacuum and Mop\uFF1A\\n125 min (Standard)\\n\\nVacuum\uFF1A\\n216 min (Standard)',\n Bluetooth: '\u2705',\n 'App Control': '\u2705',\n 'Clean Types': 'Vacuum and Mop',\n 'Omni Station': '\u2705',\n 'Robot/Station': 'Robot: \\n12.83 \u00D7 13.72 \u00D7 4.40 in\\nStation\uFF1A\\n14.63 \u00D7 19.07 \u00D7 17.29 in',\n 'Suction Power': '20,000 Pa',\n 'Auto-Detangling': 'DuoSpiral\u2122 Brushes',\n 'Downward Pressure': '1.5kg',\n 'Obstacle Avoidance': 'RGB Camera + LED',\n 'Rotations Per Minute': '180RPM',\n 'Portable Deep Cleaner': '\u274C',\n 'Obstacle Clearance Height': '0.83 in',\n 'HydroJet\u2122 Mopping System': '\u2705',\n 'Minimum Height and Width Restrictions': '4.40 in / 12.83 in',\n },\n },\n {\n sku: 'A2524014',\n handle: 'a2524',\n subTitle: {\n 'Wi-Fi': '\u2705',\n 'Mop Type': 'Rolling Mop',\n 'Run Time': 'Vacuum and Mop\uFF1A\\n125 min (Standard)\\n\\nVacuum\uFF1A\\n216 min (Standard)',\n Bluetooth: '\u2705',\n 'App Control': '\u2705',\n 'Clean Types': 'Vacuum and Mop',\n 'Omni Station': '\u2705',\n 'Robot/Station': 'Robot: \\n12.83 \u00D7 13.72 \u00D7 4.40 in\\nStation\uFF1A\\n14.63 \u00D7 19.07 \u00D7 17.29 in',\n 'Suction Power': '20,000 Pa',\n 'Auto-Detangling': 'DuoSpiral\u2122 Brushes',\n 'Downward Pressure': '1.5kg',\n 'Obstacle Avoidance': 'RGB Camera + LED',\n 'Rotations Per Minute': '180RPM',\n 'Portable Deep Cleaner': '\u2705',\n 'Obstacle Clearance Height': '0.83 in',\n 'HydroJet\u2122 Mopping System': '\u2705',\n 'Minimum Height and Width Restrictions': '4.40 in / 12.83 in',\n },\n },\n ],\n },\n DefaultSelectMenu: {\n sku: 'A1340011,A2524014',\n buttonText: 'Buy Now',\n },\n },\n container: {\n mobileSpan: '12',\n desktopSpan: '12',\n },\n style:\n '.specs-wrapper {\\n\\tbackground: #fff !important;\\n}\\n\\n.specs-sku-node-text {\\n\\tborder-radius: 0 !important;\\n}',\n blockName: 'Specs',\n blockType: 'ipc-specs',\n}\n\nconst buildData = {\n products: [\n {\n availableForSale: true,\n productType: 'charging only',\n onlineStoreUrl: null,\n publishedAt: '2025-07-29T03:54:52Z',\n totalInventory: 399,\n description:\n '250W Multi-Device Fast Charging: Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\" (M2 Pro) to 50% in just 28 minutes. Intuitive Smart App: Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging. Small Size, Huge Power: The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 approximately 4.67 times. Please know that this power bank is 99.54Wh, which meets the requirements of the TSA(<100Wh) to be taken on airplanes as carry-on baggage. 170W Fast USB-C Recharge: Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes. What You Get: Anker Prime 27,650mAh Power Bank (250W), 2 ft / 0.6 m 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.',\n descriptionHtml:\n '<div data-mce-fragment=\"1\" data-docx-has-block-data=\"false\" data-page-id=\"BSbwdemQXoJ4lfxBpvVcKIWMnog\">\\n<div data-mce-fragment=\"1\" class=\"ace-line ace-line old-record-id-XkuPddt2Lo3pPXxN9MdcN04HnNb\">\\n<div style=\"font-family: -apple-system, BlinkMacSystemFont, \\'San Francisco\\', \\'Segoe UI\\', Roboto, \\'Helvetica Neue\\', sans-serif; font-size: 0.875rem;\">\\n<div data-docx-has-block-data=\"false\" data-page-id=\"BSbwdemQXoJ4lfxBpvVcKIWMnog\">\\n<div class=\"ace-line ace-line old-record-id-TNa5d1ywEoB7DGxde7Fc1Ua0nbb\">\\n<p>\u00A0</p>\\n<ul>\\n<li>\\n<div style=\"font-family: -apple-system, BlinkMacSystemFont, \\'San Francisco\\', \\'Segoe UI\\', Roboto, \\'Helvetica Neue\\', sans-serif; font-size: 0.875rem; display: inline !important;\">\\n<strong>250W Multi-Device\u00A0</strong><strong>Fast</strong><strong> Charging: </strong>Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\" (M2 Pro) to 50% in just 28 minutes.</div>\\n</li>\\n<li>\\n<strong>Intuitive Smart </strong><strong>App</strong><strong>: </strong>Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging.</li>\\n<li>\\n<strong>Small Size, Huge Power:</strong> The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 approximately 4.67 times. Please know that this power bank is 99.54Wh, which meets the requirements of the TSA(<100Wh) to be taken on airplanes as carry-on baggage.</li>\\n<li>\\n<strong>1</strong><strong>7</strong><strong>0W Fast </strong><strong>USB-C</strong><strong> Recharge: </strong>Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes.</li>\\n<li>\\n<strong>What You Get: </strong>Anker Prime 27,650mAh Power Bank (250W), 2 ft / 0.6 m 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.</li>\\n</ul>\\n</div>\\n</div>\\n</div>\\n</div>\\n</div>\\n<p><span data-mce-fragment=\"1\" class=\"lark-record-clipboard\" data-lark-record-format=\"docx/record\" data-lark-record-data=\\'{\"isCut\":false,\"rootId\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"parentId\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"blockIds\":[6,7,8,9,10],\"recordIds\":[\"XkuPddt2Lo3pPXxN9MdcN04HnNb\",\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\",\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\",\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\",\"KxuyddjiGok1j5xt8odceqn9nif\"],\"recordMap\":{\"XkuPddt2Lo3pPXxN9MdcN04HnNb\":{\"id\":\"XkuPddt2Lo3pPXxN9MdcN04HnNb\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7251516737602732034\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"initialAttributedTexts\":{\"text\":{\"0\":\"250W Multi-Device Fast Charging: Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\\\\\" (M2 Pro) to 50% in just 28 minutes.\"},\"attribs\":{\"0\":\"*0*1+i*2*0*1+4*0*1+b*0+m*3*0+2*0+2y*0*4+u*5*4+4*0*4+h*6*4+2*0*4+9\"}},\"apool\":{\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"d422fb13-aa58-4592-a55c-e906b774afc6\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7181707785976119298\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"3\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"59fbf9ee-ca61-4090-a3d5-4819f343f070\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7257112388569497604,enterprise_46079230,enterprise_7257075173017862148,enterprise_7250018290582519812\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"4\":[\"comment-id-7251516737602732034\",\"true\"],\"5\":[\"author\",\"7251397625784664066\"],\"6\":[\"author\",\"6911999026934153218\"]},\"nextNum\":7}},\"align\":\"\",\"folded\":false}},\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\":{\"id\":\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":3,\"numToAttrib\":{\"0\":[\"bold\",\"true\"],\"1\":[\"author\",\"6960514286405844995\"],\"2\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"5689917c-5736-4006-a54b-fa3164aa54f5\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7158749951980011523\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*1*0+g*2*1*0+3*1*0+2*1+44\"},\"text\":{\"0\":\"Intuitive Smart App: Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging.\"}}},\"align\":\"\",\"folded\":false}},\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\":{\"id\":\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7251518263719723010\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":5,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7251518263719723010\",\"true\"],\"3\":[\"author\",\"6911999026934153218\"],\"4\":[\"textHighlightBackground\",\"rgb(251,191,188)\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0*1+n*0+2f*0*2+1*3*2*4+2*0*2*4+5*3*2*4+1*0*2+c*0*2*4+1*3*2*4+2*0*2*4+1*0*4+1*3*4+a*0+g*0*4+1*3*4+2*0*4+7\"},\"text\":{\"0\":\"Small Size, Huge Power: The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 XX times.\"}}},\"align\":\"\",\"folded\":false}},\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\":{\"id\":\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7257138127599321089\",\"7250360979459080193\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":5,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7250360979459080193\",\"true\"],\"3\":[\"comment-id-7257138127599321089\",\"true\"],\"4\":[\"author\",\"6911999026934153218\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0*1*2*3+1*4*1*2*3+1*0*1*2*3+o*0*2*3+27*4*2*3+5*0*2*3+i*4*2*3+8*0*2*3+a*4*2*3+1*0*2*3+8*4*2*3+b\"},\"text\":{\"0\":\"170W Fast USB-C Recharge: Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes.\"}}},\"align\":\"\",\"folded\":false}},\"KxuyddjiGok1j5xt8odceqn9nif\":{\"id\":\"KxuyddjiGok1j5xt8odceqn9nif\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7257121236814774275\",\"7251518550442344476\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"initialAttributedTexts\":{\"text\":{\"0\":\"What You Get: Anker Prime 27,650mAh Power Bank (250W), 2 ft (0.6 m) 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.\"},\"attribs\":{\"0\":\"*0*1+e*0+14*0*2+1*3*2+1*0*2+c*0+1e*4*3+b*4*0*5+6*0+1u\"}},\"apool\":{\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7257121236814774275\",\"true\"],\"3\":[\"author\",\"6911999026934153218\"],\"4\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"c5b16e2c-8c3b-4d24-b1be-442fbe5196dc\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7125383109633114114\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"5\":[\"comment-id-7251518550442344476\",\"true\"]},\"nextNum\":6}},\"align\":\"\",\"folded\":false}},\"BSbwdemQXoJ4lfxBpvVcKIWMnog\":{\"id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"snapshot\":{\"type\":\"page\",\"parent_id\":\"\",\"comments\":null,\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[\"P1lYdRH7Hor4BNxoOw3c015DnTb\",\"FsSedByPioX2r8xoEfBcJgw8nCe\",\"HE2qdl0viobsm6xdLyyck54ynGb\",\"PMehdKa42ogL1mxIgXWcn4XRnUh\",\"XkuPddt2Lo3pPXxN9MdcN04HnNb\",\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\",\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\",\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\",\"KxuyddjiGok1j5xt8odceqn9nif\",\"KrUadg8Cdonh42xaKDZc79nJnJf\",\"So00daSORoePWlx8DhAcUjkqn4f\",\"Ebg7dQBveo0026xAneIcaOTcn1g\",\"ZR0sdo11XoHqvGxB8j4cZnC0nee\",\"GcYgdn5rmoLRL6xlLc6cXnY3nHd\",\"LJ7DduoTso3D8mxW6D7cIaDMnph\",\"TuYddBj4jop3wyxuBa3crbPFnwb\",\"L5rldM6ysoM7faxmQFLcE8Ognxg\",\"Bip4d8FKco9aGUxcuU6cWhJSn1b\",\"PhEOdWCP0oAh2KxuZezcJv9inpc\",\"H8GxdNxBwoOO50xHldFcDeYfnld\",\"YGcfdYduQogOd4xnMkQcTJ8Pn7c\",\"VtA6dG2jwoHA4yxNTISc8zRRndb\",\"EnsMdHvDkoPx4cxx8jUcIempnxh\",\"LeX2dWfRZod240xnyGqclSeYnUf\",\"WZ9Jdzp3CodpiOxLlOUcEBP0n6b\",\"Mqkmdz3dao61JOxo032cJ0ZYnvb\",\"IMcdd88teodoW8xsjJtcEn28nsb\",\"GvjFdmlrAoilbbxjqr2c2R5QnFd\",\"YHsTdvEp1o4n4ZxwQCIcnpnFn0e\",\"V9efdxPyioc2P3xzW0Uc7S0Hnif\",\"QCSQdWrTRoCGCFxHz3ccLTHenpd\",\"Rjcad7xCAoOzxBxNaE9cXx5bnQd\",\"R6YedUcCQoFpt5xnU6Ac8xZrnvd\",\"Gi6wd5qRaoewxRxV1H5cksuoneb\",\"EQqZdA903oSF9vxPtQWceWHKnhf\",\"LSu5d2IusoTxXPxmSzucd62Unkd\",\"PIsDdxjDJo34tBxIw0ocu2n6nue\",\"KQJkdl7dCoLIsWxRBhlc1HlMnwb\",\"VuI6dRaTuohYuqxTjiPc8Y2RnTb\",\"BXGqdAZHso4IFDxpme5cApGCnQg\",\"Lrped7kXPocXelx5YthcZ0Kynmc\",\"M7JidVWO5orTtQxMaRKclvHon8b\",\"N33SddXYRowPtYxkIQrc2lc3nw3\",\"Tj3jdoV60o7QSTxLVaJccOb4nAb\",\"DDePdRYj4ojGy5xiU0Nc0Vk3nqg\",\"NLw9dY8Zaod5uxxFTxgcRFVfnog\"],\"text\":{\"apool\":{\"nextNum\":1,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0+1j\"},\"text\":{\"0\":\"A1340 Listing - Anker Prime 27,650mAh Power Bank (250W)\"}}},\"align\":\"\",\"doc_info\":{\"editors\":[\"6960514286405844995\",\"6911999026934153218\",\"7020952465340153884\",\"7251397625784664066\"],\"options\":[\"editors\",\"create_time\"],\"deleted_editors\":[]}}}},\"payloadMap\":{\"XkuPddt2Lo3pPXxN9MdcN04HnNb\":{\"level\":1},\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\":{\"level\":1},\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\":{\"level\":1},\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\":{\"level\":1},\"KxuyddjiGok1j5xt8odceqn9nif\":{\"level\":1}},\"extra\":{\"mention_page_title\":{},\"external_mention_url\":{}},\"isKeepQuoteContainer\":false,\"selection\":[{\"id\":6,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":225},\"recordId\":\"XkuPddt2Lo3pPXxN9MdcN04HnNb\"},{\"id\":7,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":169},\"recordId\":\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\"},{\"id\":8,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":172},\"recordId\":\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\"},{\"id\":9,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":166},\"recordId\":\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\"},{\"id\":10,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":201},\"recordId\":\"KxuyddjiGok1j5xt8odceqn9nif\"}],\"pasteFlag\":\"e5364435-867e-4bf8-bb9a-74ece20b1280\"}\\'></span> <button id=\"paste-helper-id\" style=\"width: 0px; height: 0px; padding: 0px; margin: 0px; border: 0px; display: none;\"></button></p>\\n<div id=\"gtx-trans\" style=\"position: absolute; left: 35px; top: -3.40625px;\">\\n<div class=\"gtx-trans-icon\"><br></div>\\n</div>',\n title: 'Anker Prime Power Bank (27K, 250W)',\n id: 'gid://shopify/Product/10034291638456',\n name: 'Anker Prime Power Bank (27K, 250W)',\n vendor: 'beta-anker-us',\n handle: 'a1340-250w-power-bank',\n path: '/a1340-250w-power-bank',\n slug: 'a1340-250w-power-bank',\n price: {\n value: 179.99,\n currencyCode: 'USD',\n },\n listPrice: 0,\n images: [\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/Rectangle1_25a10648-8f5f-4fa8-af31-78e60305985d.png?v=1753755974',\n altText: null,\n width: 3000,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD01_US_1200x1500px_V3.jpg?v=1753755974',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_TD03_V1_2fb91afe-dc06-4c64-a8ed-d8f17c96c33a.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD04_US.jpg?v=1753755974',\n altText: null,\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_TD05_V1_5b0cb041-ccf5-4d89-b5c9-e58fd5f7108a.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD02_US_1600x2000px_V1.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_20241009_TD_e4a4a55a-6221-494a-aa7e-aa2b8a834e1e.png?v=1753755975',\n altText: '2024-10-09-v1A13400B1',\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD01_US_1200x1500px_V3.jpg?v=1753755974',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/71pS0WHwYbL_f98f499f-1b1c-41b4-8c49-92fd9f5342cc.jpg?v=1753755973',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD04_US.jpg?v=1753755974',\n altText: null,\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/713YBqjTEfL_f9ecda02-b84a-4350-925f-9946b8bbe296.webp?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD02_US_1600x2000px_V1.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n ],\n variants: [\n {\n barcode: '194644130886',\n availableForSale: true,\n product: {\n handle: 'a1340-250w-power-bank',\n },\n id: 'gid://shopify/ProductVariant/51588168679608',\n name: 'Black',\n sku: 'A1340011',\n price: 179.99,\n image: {\n altText: null,\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/Rectangle1_25a10648-8f5f-4fa8-af31-78e60305985d.png?v=1753755974',\n width: 3000,\n height: 3000,\n },\n listPrice: null,\n requiresShipping: true,\n quantityAvailable: 199,\n currentlyNotInStock: false,\n sellingPlanAllocations: [],\n productHandle: 'a1340-250w-power-bank',\n coupons: [\n {\n title: 'WS24NJ137G95',\n starts_at: '2025-08-06T07:15:10.000Z',\n ends_at: null,\n variant_shopify_id: 51588168679608,\n value_type: 'fixed_amount',\n value: '-100.0',\n currency: 'USD',\n fixed_value: '100.0',\n value_style: '$100',\n variant_price4wscode: 79.99,\n discount_type: 'WS24',\n amazon_deal: false,\n cdi_id: 45745,\n cdi_updated_at: '2025-08-28T04:15:55.794Z',\n },\n ],\n },\n ],\n options: [\n {\n __typename: 'MultipleChoiceOption',\n id: 'gid://shopify/ProductOption/12066912338104',\n displayName: 'color',\n name: 'Color',\n values: [\n {\n label: 'Black',\n hexColors: ['#000000'],\n },\n {\n label: 'Champagne',\n },\n ],\n },\n ],\n },\n {\n availableForSale: true,\n description:\n \"The Anker Advantage: Join the 55+ million powered by our leading technology A Galaxy of Speed: A high-efficiency chipset provides 10W high-speed charging for Samsung Galaxy. iPhones get a boosted 5W charge at 10% faster than other wireless chargers Flip It: Charge in landscape orientation while watching videos or portrait mode for messaging and facial recognition Case Friendly: Don't fumble with your phone case. PowerWave charges directly through protective cases. Rubber/plastic/TPU cases less than 5 mm thick only. Magnetic and metal attachments or cards will prevent charging What You Get: Anker 313 Wireless Charger (Stand) / PowerWave Stand, 3 ft Micro USB Cable, welcome guide, worry-free 18-month warranty, and friendly customer service.\",\n descriptionHtml:\n '<meta charset=\"utf-8\">\\n<ul class=\"a-unordered-list a-vertical a-spacing-mini\" data-mce-fragment=\"1\">\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>The Anker Advantage</strong>: Join the 55+ million powered by our leading technology</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>A Galaxy of Speed</strong>: A high-efficiency chipset provides 10W high-speed charging for Samsung Galaxy. iPhones get a boosted 5W charge at 10% faster than other wireless chargers</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>Flip It</strong>: Charge in landscape orientation while watching videos or portrait mode for messaging and facial recognition</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>Case Friendly</strong>: Don\\'t fumble with your phone case. PowerWave charges directly through protective cases. Rubber/plastic/TPU cases less than 5 mm thick only. Magnetic and metal attachments or cards will prevent charging</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>What You Ge</strong>t: Anker <strong>313</strong> Wireless Charger (Stand) / PowerWave Stand, 3 ft Micro USB Cable, welcome guide, worry-free 18-month warranty, and friendly customer service.</span></li>\\n</ul>',\n title: 'Anker <b>313</b> Wireless Charger (Stand)',\n id: 'gid://shopify/Product/10034295144632',\n name: 'Anker <b>313</b> Wireless Charger (Stand)',\n vendor: 'Anker',\n handle: 'a2524',\n path: '/a2524',\n slug: 'a2524',\n price: {\n value: 23.99,\n currencyCode: 'USD',\n },\n listPrice: 0,\n images: [\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A2524011-Anker_313_Wireless_Charger_Stand_1.png?v=1753756317',\n altText: null,\n width: 1801,\n height: 1800,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61Df3AbF-PL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/71RT3xSwRJL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61NTug2RRHL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/714rrWliSiL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61dbnVj78DL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n ],\n variants: [\n {\n barcode: '194644085698',\n availableForSale: true,\n product: {\n handle: 'a2524',\n },\n id: 'gid://shopify/ProductVariant/51588205707448',\n name: 'Black',\n sku: 'A2524014',\n price: 23.99,\n image: {\n altText: null,\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A2524011-Anker_313_Wireless_Charger_Stand_1.png?v=1753756317',\n width: 1801,\n height: 1800,\n },\n listPrice: null,\n requiresShipping: true,\n quantityAvailable: 200,\n currentlyNotInStock: false,\n sellingPlanAllocations: [],\n productHandle: 'a2524',\n },\n ],\n sellingPlanGroups: [],\n options: [\n {\n __typename: 'MultipleChoiceOption',\n id: 'gid://shopify/ProductOption/12066916303032',\n displayName: 'color',\n name: 'Color',\n values: [\n {\n label: 'Black',\n hexColors: ['#000000'],\n },\n ],\n },\n ],\n },\n ],\n categories: [],\n}\n\nexport const Default = () => {\n return (\n <Container>\n <Specs\n data={data}\n buildData={buildData}\n />\n </Container>\n )\n}\n"],
|
|
5
|
-
"mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GA2YM,IAAAK,EAAA,6BAzYNC,EAAkB,+CAClBC,EAA0B,sCAE1B,MAAMC,EAAO,CACX,MAAO,uBACP,UAAW,EAAAC,QACX,WAAY,CACV,OAAQ,YACV,EACA,KAAM,CAAC,UAAU,CACnB,EAEA,IAAON,EAAQK,EAIf,MAAME,EAAO,CACX,GAAI,2BACJ,QAAS,UACT,MAAO,CACL,CACE,IAAK,WACL,KAAM,8CACN,MACE,0HACF,MAAO,wBACP,OAAQ,uBACV,EACA,CACE,IAAK,WACL,KAAM,8CACN,MAAO,sFACP,MAAO,QACP,OAAQ,QACR,WAAY,gBACd,CACF,EACA,KAAM,CACJ,SAAU,CACR,KAAM,CACJ,CACE,MAAO,UACP,SAAU,CACR,cACA,wBACA,gCACA,WACA,oBACA,uBACA,gBACA,kBACA,qBACA,eACA,4BACA,wCACA,gBACA,WACA,cACA,YACA,OACF,EACA,UAAW,EACb,CACF,CACF,EACA,UAAW,CACT,MAAO,CACL,CACE,IAAK,WACL,OAAQ,wBACR,SAAU,CACR,QAAS,SACT,WAAY,cACZ,WAAY;AAAA;AAAA;AAAA;AAAA,oBACZ,UAAW,SACX,cAAe,SACf,cAAe,iBACf,eAAgB,SAChB,gBAAiB;AAAA;AAAA;AAAA,gCACjB,gBAAiB,YACjB,kBAAmB,0BACnB,oBAAqB,QACrB,qBAAsB,mBACtB,uBAAwB,SACxB,wBAAyB,SACzB,4BAA6B,UAC7B,gCAA4B,SAC5B,wCAAyC,oBAC3C,CACF,EACA,CACE,IAAK,WACL,OAAQ,QACR,SAAU,CACR,QAAS,SACT,WAAY,cACZ,WAAY;AAAA;AAAA;A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EACA,CACE,IAAK,qHACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,2HACL,QAAS,KACT,MAAO,KACP,OAAQ,GACV,EACA,CACE,IAAK,sGACL,QAAS,KACT,MAAO,KACP,OAAQ,GACV,EACA,CACE,IAAK,4HACL,QAAS,KACT,MAAO,KACP,OAAQ,GACV,EACA,CACE,IAAK,qHACL,QAAS,KACT,MAAO,KACP,OAAQ,GACV,CACF,EACA,SAAU,CACR,CACE,QAAS,eACT,iBAAkB,GAClB,QAAS,CACP,OAAQ,uBACV,EACA,GAAI,8CACJ,KAAM,QACN,IAAK,WACL,MAAO,OACP,MAAO,CACL,QAAS,KACT,IAAK,0HACL,MAAO,IACP,OAAQ,GACV,EACA,UAAW,KACX,iBAAkB,GAClB,kBAAmB,IACnB,oBAAqB,GACrB,uBAAwB,CAAC,EACzB,cAAe,wBACf,QAAS,CACP,CACE,MAAO,eACP,UAAW,2BACX,QAAS,KACT,mBAAoB,eACpB,WAAY,eACZ,MAAO,SACP,SAAU,MACV,YAAa,QACb,YAAa,OACb,qBAAsB,MACtB,cAAe,OACf,YAAa,GACb,OAAQ,MACR,eAAgB,0BAClB,CACF,CACF,CACF,EACA,QAAS,CACP,CACE,WAAY,uBACZ,GAAI,6CACJ,YAAa,QACb,KAAM,QACN,OAAQ,CACN,CACE,MAAO,QACP,UAAW,CAAC,SAAS,CACvB,EACA,CACE,MAAO,WACT,CACF,CACF,CACF,CACF,EACA,CACE,iBAAkB,GAClB,YACE,+uBACF,gBACE;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,OACF,MAAO,4CACP,GAAI,uCACJ,KAAM,4CACN,OAAQ,QACR,OAAQ,QACR,KAAM,SACN,KAAM,QACN,MAAO,CACL,MAAO,MACP,aAAc,KAChB,EACA,UAAW,EACX,OAAQ,CACN,CACE,IAAK,sHACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,sFACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,sFACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,sFACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,sFACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,EACA,CACE,IAAK,sFACL,QAAS,KACT,MAAO,KACP,OAAQ,IACV,CACF,EACA,SAAU,CACR,CACE,QAAS,eACT,iBAAkB,GAClB,QAAS,CACP,OAAQ,OACV,EACA,GAAI,8CACJ,KAAM,QACN,IAAK,WACL,MAAO,MACP,MAAO,CACL,QAAS,KACT,IAAK,sHACL,MAAO,KACP,OAAQ,IACV,EACA,UAAW,KACX,iBAAkB,GAClB,kBAAmB,IACnB,oBAAqB,GACrB,uBAAwB,CAAC,EACzB,cAAe,OACjB,CACF,EACA,kBAAmB,CAAC,EACpB,QAAS,CACP,CACE,WAAY,uBACZ,GAAI,6CACJ,YAAa,QACb,KAAM,QACN,OAAQ,CACN,CACE,MAAO,QACP,UAAW,CAAC,SAAS,CACvB,CACF,CACF,CACF,CACF,CACF,EACA,WAAY,CAAC,CACf,EAEaT,EAAU,OAEnB,OAAC,aACC,mBAAC,EAAAO,QAAA,
|
|
4
|
+
"sourcesContent": ["import type { Meta, StoryObj } from '@storybook/react'\n\nimport Specs from '../biz-components/Specs/index.js'\nimport { Container } from '../components/container.js'\n\nconst meta = {\n title: 'Biz-Components/Specs',\n component: Specs,\n parameters: {\n layout: 'fullscreen',\n },\n tags: ['autodocs'],\n} satisfies Meta<typeof Specs>\n\nexport default meta\n\ntype Story = StoryObj<typeof meta>\n\nconst data = {\n id: '68ea29e5ca34138c04aec30f',\n display: 'visible',\n items: [\n {\n sku: 'A1340011',\n name: 'Anker <b>325</b> Power Bank (PowerCore 20K)',\n image:\n 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1268013_1_2430b504-15c6-441e-9914-ae215095e8b4.png?v=1753755824',\n value: 'a1340-250w-power-bank',\n handle: 'a1340-250w-power-bank',\n },\n {\n sku: 'A2524014',\n name: 'Anker <b>337</b> Power Bank (PowerCore 26K)',\n image: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1277011_V1.png?v=1753755956',\n value: 'a2524',\n handle: 'a2524',\n shopify_id: '10034291441848',\n },\n ],\n data: {\n LeftMenu: {\n data: [\n {\n title: 'Product',\n subTitle: [\n 'Clean Types',\n 'Portable Deep Cleaner',\n 'HydroJet\u2122 Mopping System',\n 'Mop Type',\n 'Downward Pressure',\n 'Rotations Per Minute',\n 'Suction Power',\n 'Auto-Detangling',\n 'Obstacle Avoidance',\n 'Omni Station',\n 'Obstacle Clearance Height',\n 'Minimum Height and Width Restrictions',\n 'Robot/Station',\n 'Run Time',\n 'App Control',\n 'Bluetooth',\n 'Wi-Fi',\n ],\n isProduct: true,\n },\n ],\n },\n RightMenu: {\n menus: [\n {\n sku: 'A1340011',\n handle: 'a1340-250w-power-bank',\n subTitle: {\n 'Wi-Fi': '\u2705',\n 'Mop Type': 'Rolling Mop',\n 'Run Time': 'Vacuum and Mop\uFF1A\\n125 min (Standard)\\n\\nVacuum\uFF1A\\n216 min (Standard)',\n Bluetooth: '\u2705',\n 'App Control': '\u2705',\n 'Clean Types': 'Vacuum and Mop',\n 'Omni Station': '\u2705',\n 'Robot/Station': 'Robot: \\n12.83 \u00D7 13.72 \u00D7 4.40 in\\nStation\uFF1A\\n14.63 \u00D7 19.07 \u00D7 17.29 in',\n 'Suction Power': '20,000 Pa',\n 'Auto-Detangling': 'DuoSpiral\u2122 Brushes',\n 'Downward Pressure': '1.5kg',\n 'Obstacle Avoidance': 'RGB Camera + LED',\n 'Rotations Per Minute': '180RPM',\n 'Portable Deep Cleaner': '\u274C',\n 'Obstacle Clearance Height': '0.83 in',\n 'HydroJet\u2122 Mopping System': '\u2705',\n 'Minimum Height and Width Restrictions': '4.40 in / 12.83 in',\n },\n },\n {\n sku: 'A2524014',\n handle: 'a2524',\n subTitle: {\n 'Wi-Fi': '\u2705',\n 'Mop Type': 'Rolling Mop',\n 'Run Time': 'Vacuum and Mop\uFF1A\\n125 min (Standard)\\n\\nVacuum\uFF1A\\n216 min (Standard)',\n Bluetooth: '\u2705',\n 'App Control': '\u2705',\n 'Clean Types': 'Vacuum and Mop',\n 'Omni Station': '\u2705',\n 'Robot/Station': 'Robot: \\n12.83 \u00D7 13.72 \u00D7 4.40 in\\nStation\uFF1A\\n14.63 \u00D7 19.07 \u00D7 17.29 in',\n 'Suction Power': '20,000 Pa',\n 'Auto-Detangling': 'DuoSpiral\u2122 Brushes',\n 'Downward Pressure': '1.5kg',\n 'Obstacle Avoidance': 'RGB Camera + LED',\n 'Rotations Per Minute': '180RPM',\n 'Portable Deep Cleaner': '\u2705',\n 'Obstacle Clearance Height': '0.83 in',\n 'HydroJet\u2122 Mopping System': '\u2705',\n 'Minimum Height and Width Restrictions': '4.40 in / 12.83 in',\n },\n },\n ],\n },\n DefaultSelectMenu: {\n sku: 'A1340011,A2524014',\n buttonText: 'Buy Now',\n },\n },\n container: {\n mobileSpan: '12',\n desktopSpan: '12',\n },\n style:\n '.specs-wrapper {\\n\\tbackground: #fff !important;\\n}\\n\\n.specs-sku-node-text {\\n\\tborder-radius: 0 !important;\\n}',\n blockName: 'Specs',\n blockType: 'ipc-specs',\n}\n\nconst buildData = {\n products: [\n {\n availableForSale: true,\n productType: 'charging only',\n onlineStoreUrl: null,\n publishedAt: '2025-07-29T03:54:52Z',\n totalInventory: 399,\n description:\n '250W Multi-Device Fast Charging: Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\" (M2 Pro) to 50% in just 28 minutes. Intuitive Smart App: Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging. Small Size, Huge Power: The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 approximately 4.67 times. Please know that this power bank is 99.54Wh, which meets the requirements of the TSA(<100Wh) to be taken on airplanes as carry-on baggage. 170W Fast USB-C Recharge: Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes. What You Get: Anker Prime 27,650mAh Power Bank (250W), 2 ft / 0.6 m 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.',\n descriptionHtml:\n '<div data-mce-fragment=\"1\" data-docx-has-block-data=\"false\" data-page-id=\"BSbwdemQXoJ4lfxBpvVcKIWMnog\">\\n<div data-mce-fragment=\"1\" class=\"ace-line ace-line old-record-id-XkuPddt2Lo3pPXxN9MdcN04HnNb\">\\n<div style=\"font-family: -apple-system, BlinkMacSystemFont, \\'San Francisco\\', \\'Segoe UI\\', Roboto, \\'Helvetica Neue\\', sans-serif; font-size: 0.875rem;\">\\n<div data-docx-has-block-data=\"false\" data-page-id=\"BSbwdemQXoJ4lfxBpvVcKIWMnog\">\\n<div class=\"ace-line ace-line old-record-id-TNa5d1ywEoB7DGxde7Fc1Ua0nbb\">\\n<p>\u00A0</p>\\n<ul>\\n<li>\\n<div style=\"font-family: -apple-system, BlinkMacSystemFont, \\'San Francisco\\', \\'Segoe UI\\', Roboto, \\'Helvetica Neue\\', sans-serif; font-size: 0.875rem; display: inline !important;\">\\n<strong>250W Multi-Device\u00A0</strong><strong>Fast</strong><strong> Charging: </strong>Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\" (M2 Pro) to 50% in just 28 minutes.</div>\\n</li>\\n<li>\\n<strong>Intuitive Smart </strong><strong>App</strong><strong>: </strong>Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging.</li>\\n<li>\\n<strong>Small Size, Huge Power:</strong> The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 approximately 4.67 times. Please know that this power bank is 99.54Wh, which meets the requirements of the TSA(<100Wh) to be taken on airplanes as carry-on baggage.</li>\\n<li>\\n<strong>1</strong><strong>7</strong><strong>0W Fast </strong><strong>USB-C</strong><strong> Recharge: </strong>Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes.</li>\\n<li>\\n<strong>What You Get: </strong>Anker Prime 27,650mAh Power Bank (250W), 2 ft / 0.6 m 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.</li>\\n</ul>\\n</div>\\n</div>\\n</div>\\n</div>\\n</div>\\n<p><span data-mce-fragment=\"1\" class=\"lark-record-clipboard\" data-lark-record-format=\"docx/record\" data-lark-record-data=\\'{\"isCut\":false,\"rootId\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"parentId\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"blockIds\":[6,7,8,9,10],\"recordIds\":[\"XkuPddt2Lo3pPXxN9MdcN04HnNb\",\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\",\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\",\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\",\"KxuyddjiGok1j5xt8odceqn9nif\"],\"recordMap\":{\"XkuPddt2Lo3pPXxN9MdcN04HnNb\":{\"id\":\"XkuPddt2Lo3pPXxN9MdcN04HnNb\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7251516737602732034\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"initialAttributedTexts\":{\"text\":{\"0\":\"250W Multi-Device Fast Charging: Powered by the latest PD 3.1 technology, the power bank comes with 2 USB-C ports and 1 USB-A port to deliver up to 250W of power. Boost your MacBook Pro 16\\\\\" (M2 Pro) to 50% in just 28 minutes.\"},\"attribs\":{\"0\":\"*0*1+i*2*0*1+4*0*1+b*0+m*3*0+2*0+2y*0*4+u*5*4+4*0*4+h*6*4+2*0*4+9\"}},\"apool\":{\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"d422fb13-aa58-4592-a55c-e906b774afc6\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7181707785976119298\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"3\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"59fbf9ee-ca61-4090-a3d5-4819f343f070\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7257112388569497604,enterprise_46079230,enterprise_7257075173017862148,enterprise_7250018290582519812\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"4\":[\"comment-id-7251516737602732034\",\"true\"],\"5\":[\"author\",\"7251397625784664066\"],\"6\":[\"author\",\"6911999026934153218\"]},\"nextNum\":7}},\"align\":\"\",\"folded\":false}},\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\":{\"id\":\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":3,\"numToAttrib\":{\"0\":[\"bold\",\"true\"],\"1\":[\"author\",\"6960514286405844995\"],\"2\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"5689917c-5736-4006-a54b-fa3164aa54f5\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7158749951980011523\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*1*0+g*2*1*0+3*1*0+2*1+44\"},\"text\":{\"0\":\"Intuitive Smart App: Use the Anker app to quickly locate your power bank with sound alerts, access real-time stats, and optimize device battery life with smart charging.\"}}},\"align\":\"\",\"folded\":false}},\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\":{\"id\":\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7251518263719723010\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":5,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7251518263719723010\",\"true\"],\"3\":[\"author\",\"6911999026934153218\"],\"4\":[\"textHighlightBackground\",\"rgb(251,191,188)\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0*1+n*0+2f*0*2+1*3*2*4+2*0*2*4+5*3*2*4+1*0*2+c*0*2*4+1*3*2*4+2*0*2*4+1*0*4+1*3*4+a*0+g*0*4+1*3*4+2*0*4+7\"},\"text\":{\"0\":\"Small Size, Huge Power: The power bank is the size of a soda can with a capacity of 27,650mAh and can charge a 13-inch MacBook Air (M2) 1.28 times or an iPhone 14 XX times.\"}}},\"align\":\"\",\"folded\":false}},\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\":{\"id\":\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7257138127599321089\",\"7250360979459080193\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"apool\":{\"nextNum\":5,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7250360979459080193\",\"true\"],\"3\":[\"comment-id-7257138127599321089\",\"true\"],\"4\":[\"author\",\"6911999026934153218\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0*1*2*3+1*4*1*2*3+1*0*1*2*3+o*0*2*3+27*4*2*3+5*0*2*3+i*4*2*3+8*0*2*3+a*4*2*3+1*0*2*3+8*4*2*3+b\"},\"text\":{\"0\":\"170W Fast USB-C Recharge: Recharge your power bank at lightning speed with the convenience of dual USB-C ports, allowing you to fully replenish it in just 37 minutes.\"}}},\"align\":\"\",\"folded\":false}},\"KxuyddjiGok1j5xt8odceqn9nif\":{\"id\":\"KxuyddjiGok1j5xt8odceqn9nif\",\"snapshot\":{\"type\":\"text\",\"parent_id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"comments\":[\"7257121236814774275\",\"7251518550442344476\"],\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[],\"text\":{\"initialAttributedTexts\":{\"text\":{\"0\":\"What You Get: Anker Prime 27,650mAh Power Bank (250W), 2 ft (0.6 m) 140W USB-C to USB-C charging cable, travel pouch, quick start guide, our worry-free 24-month warranty, and friendly customer service.\"},\"attribs\":{\"0\":\"*0*1+e*0+14*0*2+1*3*2+1*0*2+c*0+1e*4*3+b*4*0*5+6*0+1u\"}},\"apool\":{\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"],\"1\":[\"bold\",\"true\"],\"2\":[\"comment-id-7257121236814774275\",\"true\"],\"3\":[\"author\",\"6911999026934153218\"],\"4\":[\"abbreviation-data\",\"{\\\\\"id\\\\\":\\\\\"c5b16e2c-8c3b-4d24-b1be-442fbe5196dc\\\\\",\\\\\"abbr_ids\\\\\":\\\\\"enterprise_7125383109633114114\\\\\",\\\\\"is_visible\\\\\":1,\\\\\"is_first\\\\\":1}\"],\"5\":[\"comment-id-7251518550442344476\",\"true\"]},\"nextNum\":6}},\"align\":\"\",\"folded\":false}},\"BSbwdemQXoJ4lfxBpvVcKIWMnog\":{\"id\":\"BSbwdemQXoJ4lfxBpvVcKIWMnog\",\"snapshot\":{\"type\":\"page\",\"parent_id\":\"\",\"comments\":null,\"locked\":false,\"hidden\":false,\"author\":\"6960514286405844995\",\"children\":[\"P1lYd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d2IusoTxXPxmSzucd62Unkd\",\"PIsDdxjDJo34tBxIw0ocu2n6nue\",\"KQJkdl7dCoLIsWxRBhlc1HlMnwb\",\"VuI6dRaTuohYuqxTjiPc8Y2RnTb\",\"BXGqdAZHso4IFDxpme5cApGCnQg\",\"Lrped7kXPocXelx5YthcZ0Kynmc\",\"M7JidVWO5orTtQxMaRKclvHon8b\",\"N33SddXYRowPtYxkIQrc2lc3nw3\",\"Tj3jdoV60o7QSTxLVaJccOb4nAb\",\"DDePdRYj4ojGy5xiU0Nc0Vk3nqg\",\"NLw9dY8Zaod5uxxFTxgcRFVfnog\"],\"text\":{\"apool\":{\"nextNum\":1,\"numToAttrib\":{\"0\":[\"author\",\"6960514286405844995\"]}},\"initialAttributedTexts\":{\"attribs\":{\"0\":\"*0+1j\"},\"text\":{\"0\":\"A1340 Listing - Anker Prime 27,650mAh Power Bank (250W)\"}}},\"align\":\"\",\"doc_info\":{\"editors\":[\"6960514286405844995\",\"6911999026934153218\",\"7020952465340153884\",\"7251397625784664066\"],\"options\":[\"editors\",\"create_time\"],\"deleted_editors\":[]}}}},\"payloadMap\":{\"XkuPddt2Lo3pPXxN9MdcN04HnNb\":{\"level\":1},\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\":{\"level\":1},\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\":{\"level\":1},\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\":{\"level\":1},\"KxuyddjiGok1j5xt8odceqn9nif\":{\"level\":1}},\"extra\":{\"mention_page_title\":{},\"external_mention_url\":{}},\"isKeepQuoteContainer\":false,\"selection\":[{\"id\":6,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":225},\"recordId\":\"XkuPddt2Lo3pPXxN9MdcN04HnNb\"},{\"id\":7,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":169},\"recordId\":\"TNa5d1ywEoB7DGxde7Fc1Ua0nbb\"},{\"id\":8,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":172},\"recordId\":\"Mbq6dRIj2oN6bDxdHUPcIluUnyg\"},{\"id\":9,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":166},\"recordId\":\"H9VtdIlVfoyZuhx957Zc3Mnbnnf\"},{\"id\":10,\"type\":\"text\",\"selection\":{\"start\":0,\"end\":201},\"recordId\":\"KxuyddjiGok1j5xt8odceqn9nif\"}],\"pasteFlag\":\"e5364435-867e-4bf8-bb9a-74ece20b1280\"}\\'></span> <button id=\"paste-helper-id\" style=\"width: 0px; height: 0px; padding: 0px; margin: 0px; border: 0px; display: none;\"></button></p>\\n<div id=\"gtx-trans\" style=\"position: absolute; left: 35px; top: -3.40625px;\">\\n<div class=\"gtx-trans-icon\"><br></div>\\n</div>',\n title: 'Anker Prime Power Bank (27K, 250W)',\n id: 'gid://shopify/Product/10034291638456',\n name: 'Anker Prime Power Bank (27K, 250W)',\n vendor: 'beta-anker-us',\n handle: 'a1340-250w-power-bank',\n path: '/a1340-250w-power-bank',\n slug: 'a1340-250w-power-bank',\n price: {\n value: 179.99,\n currencyCode: 'USD',\n },\n listPrice: 0,\n images: [\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/Rectangle1_25a10648-8f5f-4fa8-af31-78e60305985d.png?v=1753755974',\n altText: null,\n width: 3000,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD01_US_1200x1500px_V3.jpg?v=1753755974',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_TD03_V1_2fb91afe-dc06-4c64-a8ed-d8f17c96c33a.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD04_US.jpg?v=1753755974',\n altText: null,\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_TD05_V1_5b0cb041-ccf5-4d89-b5c9-e58fd5f7108a.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A1340011_Rich_image_TD02_US_1600x2000px_V1.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_20241009_TD_e4a4a55a-6221-494a-aa7e-aa2b8a834e1e.png?v=1753755975',\n altText: '2024-10-09-v1A13400B1',\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD01_US_1200x1500px_V3.jpg?v=1753755974',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/71pS0WHwYbL_f98f499f-1b1c-41b4-8c49-92fd9f5342cc.jpg?v=1753755973',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD04_US.jpg?v=1753755974',\n altText: null,\n width: 2400,\n height: 3000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/713YBqjTEfL_f9ecda02-b84a-4350-925f-9946b8bbe296.webp?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A13400B1_Rich_image_TD02_US_1600x2000px_V1.jpg?v=1753755974',\n altText: null,\n width: 1600,\n height: 2000,\n },\n ],\n variants: [\n {\n barcode: '194644130886',\n availableForSale: true,\n product: {\n handle: 'a1340-250w-power-bank',\n },\n id: 'gid://shopify/ProductVariant/51588168679608',\n name: 'Black',\n sku: 'A1340011',\n price: 179.99,\n image: {\n altText: null,\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/Rectangle1_25a10648-8f5f-4fa8-af31-78e60305985d.png?v=1753755974',\n width: 3000,\n height: 3000,\n },\n listPrice: null,\n requiresShipping: true,\n quantityAvailable: 199,\n currentlyNotInStock: false,\n sellingPlanAllocations: [],\n productHandle: 'a1340-250w-power-bank',\n coupons: [\n {\n title: 'WS24NJ137G95',\n starts_at: '2025-08-06T07:15:10.000Z',\n ends_at: null,\n variant_shopify_id: 51588168679608,\n value_type: 'fixed_amount',\n value: '-100.0',\n currency: 'USD',\n fixed_value: '100.0',\n value_style: '$100',\n variant_price4wscode: 79.99,\n discount_type: 'WS24',\n amazon_deal: false,\n cdi_id: 45745,\n cdi_updated_at: '2025-08-28T04:15:55.794Z',\n },\n ],\n },\n ],\n options: [\n {\n __typename: 'MultipleChoiceOption',\n id: 'gid://shopify/ProductOption/12066912338104',\n displayName: 'color',\n name: 'Color',\n values: [\n {\n label: 'Black',\n hexColors: ['#000000'],\n },\n {\n label: 'Champagne',\n },\n ],\n },\n ],\n },\n {\n availableForSale: true,\n description:\n \"The Anker Advantage: Join the 55+ million powered by our leading technology A Galaxy of Speed: A high-efficiency chipset provides 10W high-speed charging for Samsung Galaxy. iPhones get a boosted 5W charge at 10% faster than other wireless chargers Flip It: Charge in landscape orientation while watching videos or portrait mode for messaging and facial recognition Case Friendly: Don't fumble with your phone case. PowerWave charges directly through protective cases. Rubber/plastic/TPU cases less than 5 mm thick only. Magnetic and metal attachments or cards will prevent charging What You Get: Anker 313 Wireless Charger (Stand) / PowerWave Stand, 3 ft Micro USB Cable, welcome guide, worry-free 18-month warranty, and friendly customer service.\",\n descriptionHtml:\n '<meta charset=\"utf-8\">\\n<ul class=\"a-unordered-list a-vertical a-spacing-mini\" data-mce-fragment=\"1\">\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>The Anker Advantage</strong>: Join the 55+ million powered by our leading technology</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>A Galaxy of Speed</strong>: A high-efficiency chipset provides 10W high-speed charging for Samsung Galaxy. iPhones get a boosted 5W charge at 10% faster than other wireless chargers</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>Flip It</strong>: Charge in landscape orientation while watching videos or portrait mode for messaging and facial recognition</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>Case Friendly</strong>: Don\\'t fumble with your phone case. PowerWave charges directly through protective cases. Rubber/plastic/TPU cases less than 5 mm thick only. Magnetic and metal attachments or cards will prevent charging</span></li>\\n<li data-mce-fragment=\"1\"><span class=\"a-list-item\" data-mce-fragment=\"1\"><strong>What You Ge</strong>t: Anker <strong>313</strong> Wireless Charger (Stand) / PowerWave Stand, 3 ft Micro USB Cable, welcome guide, worry-free 18-month warranty, and friendly customer service.</span></li>\\n</ul>',\n title: 'Anker <b>313</b> Wireless Charger (Stand)',\n id: 'gid://shopify/Product/10034295144632',\n name: 'Anker <b>313</b> Wireless Charger (Stand)',\n vendor: 'Anker',\n handle: 'a2524',\n path: '/a2524',\n slug: 'a2524',\n price: {\n value: 23.99,\n currencyCode: 'USD',\n },\n listPrice: 0,\n images: [\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A2524011-Anker_313_Wireless_Charger_Stand_1.png?v=1753756317',\n altText: null,\n width: 1801,\n height: 1800,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61Df3AbF-PL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/71RT3xSwRJL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61NTug2RRHL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/714rrWliSiL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n {\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/61dbnVj78DL.jpg?v=1753756317',\n altText: null,\n width: 1200,\n height: 1500,\n },\n ],\n variants: [\n {\n barcode: '194644085698',\n availableForSale: true,\n product: {\n handle: 'a2524',\n },\n id: 'gid://shopify/ProductVariant/51588205707448',\n name: 'Black',\n sku: 'A2524014',\n price: 23.99,\n image: {\n altText: null,\n url: 'https://cdn.shopify.com/s/files/1/0517/6767/3016/files/A2524011-Anker_313_Wireless_Charger_Stand_1.png?v=1753756317',\n width: 1801,\n height: 1800,\n },\n listPrice: null,\n requiresShipping: true,\n quantityAvailable: 200,\n currentlyNotInStock: false,\n sellingPlanAllocations: [],\n productHandle: 'a2524',\n },\n ],\n sellingPlanGroups: [],\n options: [\n {\n __typename: 'MultipleChoiceOption',\n id: 'gid://shopify/ProductOption/12066916303032',\n displayName: 'color',\n name: 'Color',\n values: [\n {\n label: 'Black',\n hexColors: ['#000000'],\n },\n ],\n },\n ],\n },\n ],\n categories: [],\n}\n\nexport const Default = () => {\n return (\n <Container>\n <Specs data={data} buildData={buildData} />\n </Container>\n )\n}\n"],
|
|
5
|
+
"mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GA2YM,IAAAK,EAAA,6BAzYNC,EAAkB,+CAClBC,EAA0B,sCAE1B,MAAMC,EAAO,CACX,MAAO,uBACP,UAAW,EAAAC,QACX,WAAY,CACV,OAAQ,YACV,EACA,KAAM,CAAC,UAAU,CACnB,EAEA,IAAON,EAAQK,EAIf,MAAME,EAAO,CACX,GAAI,2BACJ,QAAS,UACT,MAAO,CACL,CACE,IAAK,WACL,KAAM,8CACN,MACE,0HACF,MAAO,wBACP,OAAQ,uBACV,EACA,CACE,IAAK,WACL,KAAM,8CACN,MAAO,sFACP,MAAO,QACP,OAAQ,QACR,WAAY,gBACd,CACF,EACA,KAAM,CACJ,SA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W,CAAC,SAAS,CACvB,CACF,CACF,CACF,CACF,CACF,EACA,WAAY,CAAC,CACf,EAEaT,EAAU,OAEnB,OAAC,aACC,mBAAC,EAAAO,QAAA,CAAM,KAAMC,EAAM,UAAWC,EAAW,EAC3C",
|
|
6
6
|
"names": ["specs_stories_exports", "__export", "Default", "specs_stories_default", "__toCommonJS", "import_jsx_runtime", "import_Specs", "import_container", "meta", "Specs", "data", "buildData"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/biz-components/AccordionCards/index.tsx"],
|
|
4
|
-
"sourcesContent": ["'use client'\nimport Title from '../Title/index.js'\nimport { cn } from '../../helpers/utils.js'\nimport Picture from '../../components/picture.js'\nimport Button from '../../components/button.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport React, { useState, useRef, useCallback, useImperativeHandle, useEffect, type RefObject } from 'react'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport type { Img } from '../../types/props.js'\nimport throttle from '../../shared/throttle.js'\nimport { Heading } from '../../components/heading.js'\n\nconst componentType = 'image'\nconst componentName = 'scene_banner'\n\n/** Hook\uFF1A\u76D1\u542C\u7A97\u53E3\u5BBD\u5EA6 */\ntype ItemType = {\n /** \u6807\u9898\u6587\u672C */\n title: string\n /** \u56FE\u7247*/\n img: Img\n mobileImg?: Img\n /** \u5185\u5BB9\u8282\u70B9 */\n subTitle: string\n link?: string\n imgLink?: string\n}\n\nexport type AccordionCardsType = {\n className?: string\n data: {\n key?: string\n title?: string\n products: Array<ItemType>\n /** \u6309\u94AE\u5F62\u72B6 */\n shape?: 'round' | 'square'\n /** \u5361\u7247\u5F62\u72B6 */\n itemShape?: 'round' | 'square'\n /** \u4E3B\u6309\u94AE\u914D\u7F6E */\n primaryButton?: string\n theme?: 'light' | 'dark'\n }\n /** \u6309\u94AE\u4E8B\u4EF6*/\n event?: {\n primaryButton?: (v: any, index: number) => void\n }\n}\n\nconst AccordionCardsPcItem = ({\n item,\n idx,\n itemShape,\n hoverIndex,\n getRef,\n handleSwiperItemClick,\n isAnimation,\n contentWidth,\n primaryButton,\n event,\n data,\n accordionRef,\n}: {\n item: ItemType\n idx: number\n itemShape: 'round' | 'square' | undefined\n hoverIndex: number | null\n getRef: (idx: number, el: HTMLDivElement) => void\n handleSwiperItemClick: (idx: number) => void\n isAnimation: any\n contentWidth: number\n primaryButton: string | undefined\n event: any\n data: AccordionCardsType['data']\n accordionRef: React.MutableRefObject<HTMLDivElement[]>\n}) => {\n const isExpanded = hoverIndex === idx\n const flexValue = isExpanded ? 8 : 1\n\n useExposure({ current: accordionRef.current[idx] } as RefObject<HTMLDivElement>, {\n componentType,\n componentName,\n componentTitle: item?.title,\n position: idx + 1,\n componentDescription: item?.subTitle,\n })\n\n return (\n <div\n key={idx}\n style={{\n flex: `${flexValue} 1 0%`,\n transition: 'all 0.6s',\n }}\n ref={(el: HTMLDivElement | null) => {\n if (el) getRef(idx, el)\n }}\n className={cn('relative cursor-pointer overflow-hidden', itemShape === 'round' ? 'rounded-2xl' : '')}\n onMouseEnter={() => handleSwiperItemClick(idx)}\n onMouseLeave={() => {\n isAnimation.current = false\n }}\n onClick={() => {\n handleSwiperItemClick(idx)\n }}\n >\n <a\n href={trackUrlRef(item?.imgLink, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${item?.title}#${item?.subTitle}`}\n >\n <Picture\n source={item?.img?.url}\n className=\"size-full object-cover [&_img]:h-full [&_img]:object-cover\"\n alt={item?.img?.alt || ''}\n />\n </a>\n <div\n style={{\n width: contentWidth,\n }}\n className={cn(\n 'absolute inset-x-0 bottom-0 flex w-full items-end justify-between overflow-hidden px-8 pb-8 opacity-0 transition-opacity duration-[600ms] ease-in',\n isExpanded && contentWidth ? 'opacity-100' : 'opacity-0'\n )}\n >\n <div className=\"mr-16 flex-1 overflow-hidden\">\n <Heading as=\"h3\" className=\"laptop:text-2xl desktop:text-[32px] text-info-primary mb-1 text-xl font-bold\">\n {item?.title}\n </Heading>\n <Heading\n as=\"h4\"\n className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary line-clamp-2 text-[14px] font-[700]\"\n >\n {item?.subTitle}\n </Heading>\n </div>\n <Button\n className={cn('mb-1.5 font-bold')}\n as=\"a\"\n href={trackUrlRef(item?.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${item?.title}#${item?.subTitle}#${primaryButton}`}\n onClick={() => event?.primaryButton?.(data, idx)}\n >\n {primaryButton}\n <span className=\"sr-only\">{item?.title ?? item?.subTitle}</span>\n </Button>\n </div>\n </div>\n )\n}\n\nconst MobileItem = ({ data, configuration }: { data: ItemType; configuration?: any }) => {\n const ref = useRef<HTMLDivElement>(null)\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: data?.title,\n position: configuration?.index + 1,\n componentDescription: data?.subTitle,\n })\n \n return (\n <div\n ref={ref}\n className={cn(\n 'bg-container-secondary-1 relative w-full shrink-0 grow-0 overflow-hidden border border-solid',\n configuration?.itemShape === 'round' ? 'rounded-2xl' : ''\n )}\n >\n <a\n href={trackUrlRef(data?.imgLink, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${data?.title}@${data?.subTitle}`}\n data-headless-nav-postion={`''#${configuration?.index + 1}`}\n >\n <Picture\n className=\"size-full object-cover [&_img]:h-full [&_img]:object-cover\"\n source={data?.mobileImg?.url || ''}\n alt={data?.mobileImg?.alt || ''}\n />\n </a>\n <div className={cn('absolute inset-x-0 bottom-0 overflow-hidden px-4 pb-4')}>\n <div className=\"tablet:mb-6 mb-4 flex-1 overflow-hidden\">\n <p className=\"text-info-primary text-2xl font-bold leading-[1.2]\">{data?.title}</p>\n <h3 className=\"text-info-primary line-clamp-2 text-sm font-semibold\">{data?.subTitle}</h3>\n </div>\n\n <Button\n as=\"a\"\n variant=\"secondary\"\n aria-label={data?.title ?? data?.subTitle}\n className={cn('text-info-primary text-sm font-bold')}\n href={trackUrlRef(data.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-nav-postion={`''#${configuration?.index + 1}`}\n data-headless-title-desc-button={`${data?.title}#${data?.subTitle}#${configuration?.primaryButton}`}\n >\n {configuration?.primaryButton}\n </Button>\n </div>\n </div>\n )\n}\n\nconst AccordionCards = React.forwardRef<HTMLDivElement, AccordionCardsType>(({ data, className = '', event }, ref) => {\n const [hoverIndex, setHoverIndex] = useState<number | null>(0)\n\n const hoverIndexRef = useRef<number>(0)\n const accordionRef = useRef<HTMLDivElement[]>([])\n const isAnimation = useRef<boolean>(false)\n const [contentWidth, setContentWidth] = useState<number>(0)\n\n const innerRef = useRef<HTMLDivElement>(null)\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n const getRef = (index: number, el: HTMLDivElement) => {\n if (el) {\n accordionRef.current[index] = el\n }\n }\n\n useEffect(() => {\n const handleResize = () => {\n if (accordionRef.current[hoverIndexRef.current]) {\n setContentWidth(accordionRef.current[hoverIndexRef.current].offsetWidth)\n }\n }\n handleResize()\n const throttleResize = throttle(handleResize, 300)\n window.addEventListener('resize', throttleResize)\n return () => window.removeEventListener('resize', throttleResize)\n }, [])\n\n\n\n const handleSwiperItemClick = useCallback(\n (idx: number) => {\n if (hoverIndex === idx || isAnimation.current) return\n isAnimation.current = true\n // \u66F4\u65B0\u5BBD\u5EA6\u76F8\u5173\u72B6\u6001\n setHoverIndex(idx)\n hoverIndexRef.current = idx\n },\n [data?.products, hoverIndex]\n )\n\n return (\n <>\n {data?.title && <Title data={{ title: data?.title }} />}\n <div ref={innerRef} className={cn('laptop:block hidden', { 'aiui-dark': data?.theme === 'dark' })}>\n <div\n className={cn(\n 'lg-desktop:h-[calc(560_/_1920*100vw)] desktop:h-[calc(448_/_1440*100vw)] laptop:h-[calc(336_/_1025*100vw)] flex max-h-[560px] min-h-[336px] w-full gap-4 overflow-hidden',\n className\n )}\n >\n {data?.products?.map((item, idx) => (\n <AccordionCardsPcItem\n key={idx}\n item={item}\n idx={idx}\n itemShape={data?.itemShape}\n hoverIndex={hoverIndex}\n getRef={getRef}\n handleSwiperItemClick={handleSwiperItemClick}\n isAnimation={isAnimation}\n contentWidth={contentWidth}\n primaryButton={data?.primaryButton}\n event={event}\n data={data}\n accordionRef={accordionRef}\n />\n ))}\n </div>\n </div>\n <div className={cn('laptop:hidden block', { 'aiui-dark': data?.theme === 'dark' })}>\n <SwiperBox\n className={cn('h-[400px] !overflow-visible', className)}\n id={'AccordionCards' + data?.key}\n data={{\n list: data?.products,\n configuration: {\n shape: data?.shape,\n itemShape: data?.itemShape,\n primaryButton: data?.primaryButton,\n event: event,\n title: data?.title,\n },\n }}\n Slide={MobileItem}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1.2,\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: 2.3,\n },\n }}\n />\n </div>\n </>\n )\n})\nexport default withLayout(AccordionCards)\n"],
|
|
5
|
-
"mappings": "aAgHQ,
|
|
4
|
+
"sourcesContent": ["'use client'\nimport Title from '../Title/index.js'\nimport { cn } from '../../helpers/utils.js'\nimport Picture from '../../components/picture.js'\nimport Button from '../../components/button.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport React, { useState, useRef, useCallback, useImperativeHandle, useEffect, type RefObject } from 'react'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport type { Img } from '../../types/props.js'\nimport throttle from '../../shared/throttle.js'\nimport { Heading } from '../../components/heading.js'\n\nconst componentType = 'image'\nconst componentName = 'scene_banner'\n\n/** Hook\uFF1A\u76D1\u542C\u7A97\u53E3\u5BBD\u5EA6 */\ntype ItemType = {\n /** \u6807\u9898\u6587\u672C */\n title: string\n /** \u56FE\u7247*/\n img: Img\n mobileImg?: Img\n /** \u5185\u5BB9\u8282\u70B9 */\n subTitle: string\n link?: string\n imgLink?: string\n}\n\nexport type AccordionCardsType = {\n className?: string\n data: {\n key?: string\n title?: string\n products: Array<ItemType>\n /** \u6309\u94AE\u5F62\u72B6 */\n shape?: 'round' | 'square'\n /** \u5361\u7247\u5F62\u72B6 */\n itemShape?: 'round' | 'square'\n /** \u4E3B\u6309\u94AE\u914D\u7F6E */\n primaryButton?: string\n theme?: 'light' | 'dark'\n }\n /** \u6309\u94AE\u4E8B\u4EF6*/\n event?: {\n primaryButton?: (v: any, index: number) => void\n }\n}\n\nconst AccordionCardsPcItem = ({\n item,\n idx,\n itemShape,\n hoverIndex,\n getRef,\n handleSwiperItemClick,\n isAnimation,\n contentWidth,\n primaryButton,\n event,\n data,\n accordionRef,\n}: {\n item: ItemType\n idx: number\n itemShape: 'round' | 'square' | undefined\n hoverIndex: number | null\n getRef: (idx: number, el: HTMLDivElement) => void\n handleSwiperItemClick: (idx: number) => void\n isAnimation: any\n contentWidth: number\n primaryButton: string | undefined\n event: any\n data: AccordionCardsType['data']\n accordionRef: React.MutableRefObject<HTMLDivElement[]>\n}) => {\n const isExpanded = hoverIndex === idx\n const flexValue = isExpanded ? 8 : 1\n\n useExposure({ current: accordionRef.current[idx] } as RefObject<HTMLDivElement>, {\n componentType,\n componentName,\n componentTitle: item?.title,\n position: idx + 1,\n componentDescription: item?.subTitle,\n })\n\n return (\n <div\n key={idx}\n style={{\n flex: `${flexValue} 1 0%`,\n transition: 'all 0.6s',\n }}\n ref={(el: HTMLDivElement | null) => {\n if (el) getRef(idx, el)\n }}\n className={cn('relative cursor-pointer overflow-hidden', itemShape === 'round' ? 'rounded-2xl' : '')}\n onMouseEnter={() => handleSwiperItemClick(idx)}\n onMouseLeave={() => {\n isAnimation.current = false\n }}\n onClick={() => {\n handleSwiperItemClick(idx)\n }}\n >\n <a\n href={trackUrlRef(item?.imgLink, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${item?.title}#${item?.subTitle}`}\n >\n <Picture\n source={item?.img?.url}\n className=\"size-full object-cover [&_img]:h-full [&_img]:object-cover\"\n alt={item?.img?.alt || ''}\n />\n </a>\n <div\n style={{\n width: contentWidth,\n }}\n className={cn(\n 'absolute inset-x-0 bottom-0 flex w-full items-end justify-between overflow-hidden px-8 pb-8 opacity-0 transition-opacity duration-[600ms] ease-in',\n isExpanded && contentWidth ? 'opacity-100' : 'opacity-0'\n )}\n >\n <div className=\"mr-16 flex-1 overflow-hidden\">\n <Heading as=\"h3\" className=\"laptop:text-2xl desktop:text-[32px] text-info-primary mb-1 text-xl font-bold\">\n {item?.title}\n </Heading>\n <Heading\n as=\"h4\"\n className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary line-clamp-2 text-[14px] font-[700]\"\n >\n {item?.subTitle}\n </Heading>\n </div>\n <Button\n className={cn('mb-1.5 font-bold')}\n as=\"a\"\n href={trackUrlRef(item?.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${item?.title}#${item?.subTitle}#${primaryButton}`}\n onClick={() => event?.primaryButton?.(data, idx)}\n >\n {primaryButton}\n <span className=\"sr-only\">{item?.title ?? item?.subTitle}</span>\n </Button>\n </div>\n </div>\n )\n}\n\nconst MobileItem = ({ data, configuration }: { data: ItemType; configuration?: any }) => {\n const ref = useRef<HTMLDivElement>(null)\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: data?.title,\n position: configuration?.index + 1,\n componentDescription: data?.subTitle,\n })\n\n return (\n <div\n ref={ref}\n className={cn(\n 'bg-container-secondary-1 relative w-full shrink-0 grow-0 overflow-hidden border border-solid',\n configuration?.itemShape === 'round' ? 'rounded-2xl' : ''\n )}\n >\n <a\n href={trackUrlRef(data?.imgLink, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${data?.title}@${data?.subTitle}`}\n data-headless-nav-postion={`''#${configuration?.index + 1}`}\n >\n <Picture\n className=\"size-full object-cover [&_img]:h-full [&_img]:object-cover\"\n source={data?.mobileImg?.url || ''}\n alt={data?.mobileImg?.alt || ''}\n />\n </a>\n <div className={cn('absolute inset-x-0 bottom-0 overflow-hidden px-4 pb-4')}>\n <div className=\"tablet:mb-6 mb-4 flex-1 overflow-hidden\">\n <p className=\"text-info-primary text-2xl font-bold leading-[1.2]\">{data?.title}</p>\n <h3 className=\"text-info-primary line-clamp-2 text-sm font-semibold\">{data?.subTitle}</h3>\n </div>\n\n <Button\n as=\"a\"\n variant=\"secondary\"\n aria-label={data?.title ?? data?.subTitle}\n className={cn('text-info-primary text-sm font-bold')}\n href={trackUrlRef(data.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-nav-postion={`''#${configuration?.index + 1}`}\n data-headless-title-desc-button={`${data?.title}#${data?.subTitle}#${configuration?.primaryButton}`}\n >\n {configuration?.primaryButton}\n </Button>\n </div>\n </div>\n )\n}\n\nconst AccordionCards = React.forwardRef<HTMLDivElement, AccordionCardsType>(({ data, className = '', event }, ref) => {\n const [hoverIndex, setHoverIndex] = useState<number | null>(0)\n\n const hoverIndexRef = useRef<number>(0)\n const accordionRef = useRef<HTMLDivElement[]>([])\n const isAnimation = useRef<boolean>(false)\n const [contentWidth, setContentWidth] = useState<number>(0)\n\n const innerRef = useRef<HTMLDivElement>(null)\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n const getRef = (index: number, el: HTMLDivElement) => {\n if (el) {\n accordionRef.current[index] = el\n }\n }\n\n useEffect(() => {\n const handleResize = () => {\n if (accordionRef.current[hoverIndexRef.current]) {\n setContentWidth(accordionRef.current[hoverIndexRef.current].offsetWidth)\n }\n }\n handleResize()\n const throttleResize = throttle(handleResize, 300)\n window.addEventListener('resize', throttleResize)\n return () => window.removeEventListener('resize', throttleResize)\n }, [])\n\n const handleSwiperItemClick = useCallback(\n (idx: number) => {\n if (hoverIndex === idx || isAnimation.current) return\n isAnimation.current = true\n // \u66F4\u65B0\u5BBD\u5EA6\u76F8\u5173\u72B6\u6001\n setHoverIndex(idx)\n hoverIndexRef.current = idx\n },\n [data?.products, hoverIndex]\n )\n\n return (\n <>\n {data?.title && <Title data={{ title: data?.title }} />}\n <div ref={innerRef} className={cn('laptop:block hidden', { 'aiui-dark': data?.theme === 'dark' })}>\n <div\n className={cn(\n 'lg-desktop:h-[calc(560_/_1920*100vw)] desktop:h-[calc(448_/_1440*100vw)] laptop:h-[calc(336_/_1025*100vw)] flex max-h-[560px] min-h-[336px] w-full gap-4 overflow-hidden',\n className\n )}\n >\n {data?.products?.map((item, idx) => (\n <AccordionCardsPcItem\n key={idx}\n item={item}\n idx={idx}\n itemShape={data?.itemShape}\n hoverIndex={hoverIndex}\n getRef={getRef}\n handleSwiperItemClick={handleSwiperItemClick}\n isAnimation={isAnimation}\n contentWidth={contentWidth}\n primaryButton={data?.primaryButton}\n event={event}\n data={data}\n accordionRef={accordionRef}\n />\n ))}\n </div>\n </div>\n <div className={cn('laptop:hidden block', { 'aiui-dark': data?.theme === 'dark' })}>\n <SwiperBox\n className={cn('h-[400px] !overflow-visible', className)}\n id={'AccordionCards' + data?.key}\n data={{\n list: data?.products,\n configuration: {\n shape: data?.shape,\n itemShape: data?.itemShape,\n primaryButton: data?.primaryButton,\n event: event,\n title: data?.title,\n },\n }}\n Slide={MobileItem}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1.2,\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: 2.3,\n },\n }}\n />\n </div>\n </>\n )\n})\nexport default withLayout(AccordionCards)\n"],
|
|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iBAAmBT,GAAM,IAC7B,KAAM,CACJ,KAAMA,GAAM,SACZ,cAAe,CACb,MAAOA,GAAM,MACb,UAAWA,GAAM,UACjB,cAAeA,GAAM,cACrB,MAAOD,EACP,MAAOC,GAAM,KACf,CACF,EACA,MAAOK,EACP,YAAa,CACX,EAAG,CACD,aAAc,GACd,SAAU,GACV,cAAe,CACjB,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAe,GACjB,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAe,GACjB,CACF,EACF,EACF,GACF,CAEJ,CAAC,EACD,IAAOY,EAAQzC,EAAWgC,CAAc",
|
|
6
6
|
"names": ["Fragment", "jsx", "jsxs", "Title", "cn", "Picture", "Button", "SwiperBox", "withLayout", "React", "useState", "useRef", "useCallback", "useImperativeHandle", "useEffect", "useExposure", "trackUrlRef", "throttle", "Heading", "componentType", "componentName", "AccordionCardsPcItem", "item", "idx", "itemShape", "hoverIndex", "getRef", "handleSwiperItemClick", "isAnimation", "contentWidth", "primaryButton", "event", "data", "accordionRef", "isExpanded", "flexValue", "el", "MobileItem", "configuration", "ref", "AccordionCards", "className", "setHoverIndex", "hoverIndexRef", "setContentWidth", "innerRef", "index", "handleResize", "throttleResize", "AccordionCards_default"]
|
|
7
7
|
}
|
|
@@ -3,6 +3,10 @@ interface AiuiContextType {
|
|
|
3
3
|
trackingData: Record<string, any>;
|
|
4
4
|
locale?: string;
|
|
5
5
|
copyWriting?: Record<string, string>;
|
|
6
|
+
pathname?: string;
|
|
7
|
+
storeDomain?: string;
|
|
8
|
+
isLogin?: boolean;
|
|
9
|
+
currencyCode?: string;
|
|
6
10
|
}
|
|
7
11
|
export declare const AiuiContext: React.Context<AiuiContextType>;
|
|
8
12
|
export declare const useAiuiContext: () => AiuiContextType;
|