@trafilea/afrodita-components 7.2.0 → 7.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/es/components/collection/product/mobile/ProductItemMobile.js +1 -1
- package/build/es/components/collection/product/mobile/styled.js +1 -1
- package/build/es/components/collection/product/truekind/ProductItemTK.js +1 -1
- package/build/es/components/collection/product/truekind/styled.js +2 -0
- package/build/es/components/collection/product/truekind/styled.js.map +1 -0
- package/build/es/components/molecules/BenefitsList/BenefitsList.js +1 -1
- package/build/es/components/molecules/CouponCard/CouponCard.js +1 -1
- package/build/es/components/molecules/LikeButton/LikeButton.js +1 -1
- package/build/es/components/molecules/OfferAtCartBenefits/OfferAtCartBenefits.js +1 -1
- package/build/es/components/organisms/AutoshipPdpCard/AutoshipPdpCard.js +1 -1
- package/build/es/components/organisms/OfferAtCart/OfferAtCart.js +1 -1
- package/build/es/components/organisms/OfferAtCartV2/OfferAtCartV2.js +1 -1
- package/build/es/components/organisms/OfferAtCartV4/OfferAtCartV4.js +1 -1
- package/build/es/components/organisms/OfferAtPDP/OfferAtPDP.js +1 -1
- package/build/es/components/organisms/ProductGalleryMobile/ProductGalleryMobileV3/ImageProductSlideV3.js +1 -1
- package/build/es/components/organisms/ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/index.js +1 -1
- package/build/es/components/organisms/SubscriptionPlanSelector/SubscriptionPlanSelector.js +1 -1
- package/build/es/components/organisms/TwoCtasAtCart/TwoCtasAtCart.js +1 -1
- package/build/index.d.ts +2 -1
- package/build/lib/components/collection/product/mobile/ProductItemMobile.js +1 -1
- package/build/lib/components/collection/product/mobile/styled.js +1 -1
- package/build/lib/components/collection/product/truekind/ProductItemTK.js +1 -1
- package/build/lib/components/collection/product/truekind/styled.js +2 -0
- package/build/lib/components/collection/product/truekind/styled.js.map +1 -0
- package/build/lib/components/molecules/BenefitsList/BenefitsList.js +1 -1
- package/build/lib/components/molecules/CouponCard/CouponCard.js +1 -1
- package/build/lib/components/molecules/LikeButton/LikeButton.js +1 -1
- package/build/lib/components/molecules/OfferAtCartBenefits/OfferAtCartBenefits.js +1 -1
- package/build/lib/components/organisms/AutoshipPdpCard/AutoshipPdpCard.js +1 -1
- package/build/lib/components/organisms/OfferAtCart/OfferAtCart.js +1 -1
- package/build/lib/components/organisms/OfferAtCartV2/OfferAtCartV2.js +1 -1
- package/build/lib/components/organisms/OfferAtCartV4/OfferAtCartV4.js +1 -1
- package/build/lib/components/organisms/OfferAtPDP/OfferAtPDP.js +1 -1
- package/build/lib/components/organisms/ProductGalleryMobile/ProductGalleryMobileV3/ImageProductSlideV3.js +1 -1
- package/build/lib/components/organisms/ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/index.js +1 -1
- package/build/lib/components/organisms/SubscriptionPlanSelector/SubscriptionPlanSelector.js +1 -1
- package/build/lib/components/organisms/TwoCtasAtCart/TwoCtasAtCart.js +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as t}from"tslib";import{jsxs as r,jsx as o}from"react/jsx-runtime";import{useOfferAtCartForAutoshipCrossSell as e}from"../../../hooks/useOfferAtCartForAutoshipCrossSell/index.js";import{ComponentSize as i}from"../../../types/enums.js";import{isDangerouslySetInnerHTML as s}from"../../../utils/common/index.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"react";import"../../../core/theme/Theme.js";import l from"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import{Text as a}from"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import{OfferAtCartBenefits as m}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as p}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as d}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../../molecules/BenefitsList/styled.js";import"../../timer/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../iconsWithTitle/index.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../icon-button/IconButton.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/
|
|
1
|
+
import{__assign as t}from"tslib";import{jsxs as r,jsx as o}from"react/jsx-runtime";import{useOfferAtCartForAutoshipCrossSell as e}from"../../../hooks/useOfferAtCartForAutoshipCrossSell/index.js";import{ComponentSize as i}from"../../../types/enums.js";import{isDangerouslySetInnerHTML as s}from"../../../utils/common/index.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"react";import"../../../core/theme/Theme.js";import l from"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import{Text as a}from"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import{OfferAtCartBenefits as m}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as p}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as d}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../../molecules/BenefitsList/styled.js";import"../../timer/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../iconsWithTitle/index.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../icon-button/IconButton.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/styled.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import c from"../../cta/secondary/ButtonSecondary.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"../../textWithImage/index.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import{Container as n,Body as j,RightContent as u,Benefits as y,Actions as b}from"./styled.js";import"../OfferAtCartV2/styled.js";import"../OfferAtCartV3/styled.js";import"../OfferAtCartV4/styled.js";import"../OfferAtPDP/styled.js";import"../OfferAtPDP/types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../SubscriptionPlanSelector/styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";var P=function(t){var r=t.content,o=t.bold;return"string"==typeof r?{content:r,bold:o}:s(r)?{dangerouslySetInnerHTML:r}:{content:r}},f=function(r,e){return o(a,t({variant:"body",weight:"demi",size:"small",color:r.colors.semantic.urgent.color},{children:null!=e?e:"Please select a size first"}),void 0)},C=function(t,e,s,a,m){return r(b,{children:[t&&o(l,{placeHolder:"Size",options:t,onChange:function(t){s(!1),e(t)}},void 0),o(c,{wide:!0,text:a,size:i.Small,onClick:m},void 0)]},void 0)},g=function(i){var s=e(i),l=s.className,a=s.title,c=a.content,b=a.bold,g=s.image,h=s.benefits,S=s.ctaText,T=void 0===S?"Yes, I want this offer":S,V=s.sizeOptions,v=s.rating,M=s.bottomCopy,G=s.theme,A=s.setSelectedSize,w=s.setShowErrorMessage,I=s.isMobile,B=s.showErrorMessage,L=s.handleOnClick,O=function(){return C(V,A,w,T,L)};return r(n,t({className:l},{children:[o(d,t({},P({content:c,bold:b})),void 0),r(j,t({height:I?"120px":"162px"},{children:[g&&o(p,{isMobile:I,src:g.src,alt:g.alt,rating:v},void 0),r(u,{children:[o(y,t({id:"benefits"},{children:o(m,{benefits:h},void 0)}),void 0),!I&&O(),!I&&B&&f(G)]},void 0)]}),void 0),I&&O(),I&&B&&f(G),M&&o("span",{dangerouslySetInnerHTML:{__html:M}},void 0)]}),void 0)};export{C as ActionsSection,f as ErrorMessage,g as OfferAtCart,P as getTitleProps};
|
|
2
2
|
//# sourceMappingURL=OfferAtCart.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as t}from"tslib";import{jsx as r,jsxs as o}from"react/jsx-runtime";import{useState as e}from"react";import{OfferAtCartBenefits as i}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as s}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as l}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import{ComponentSize as a}from"../../../types/enums.js";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import m from"../../../hooks/useDeviceType/useDeviceType.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/
|
|
1
|
+
import{__assign as t}from"tslib";import{jsx as r,jsxs as o}from"react/jsx-runtime";import{useState as e}from"react";import{OfferAtCartBenefits as i}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as s}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as l}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import{ComponentSize as a}from"../../../types/enums.js";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import m from"../../../hooks/useDeviceType/useDeviceType.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/styled.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import p from"../../cta/secondary/ButtonSecondary.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/IconButton.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../iconsWithTitle/index.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"@emotion/react";import"../../textWithImage/index.js";import"../../timer/styled.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import{getTitleProps as d}from"../OfferAtCart/OfferAtCart.js";import{renderBottomCopy as c}from"./components/DangerousHtmlRenders.js";import{SizeOptions as n}from"./components/SizeOptions.js";import{ActionsV2 as j,ContainerV2 as y,VariantType as u,BottomCopyWrapper as b}from"./styled.js";import"../OfferAtCartV3/styled.js";import"../OfferAtCartV4/styled.js";import"../OfferAtPDP/styled.js";import"../OfferAtPDP/types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../SubscriptionPlanSelector/styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";import"../../molecules/CouponCard/styled.js";import"../../molecules/BenefitsList/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import{Body as P,RightContent as f,Benefits as C}from"../OfferAtCart/styled.js";var g=function(g){var h=g.className,S=g.title,T=S.content,v=S.bold,V=g.image,A=g.benefits,G=g.ctaText,M=void 0===G?"Yes, I want this offer":G,w=g.sizeOptions,I=g.rating,O=g.onAddToCart,B=g.bottomCopy,L="mobile"===m(),k=e(!0),z=k[0],D=k[1],x=null!=V?V:{},R=x.src,F=x.alt,H=r(j,{children:z?r(p,{wide:!0,text:M,size:a.Small,onClick:function(){D(!1)}},void 0):w&&r(n,{sizeOptions:w,onAddToCart:O},void 0)},void 0);return o(y,t({className:h,variant:B?u.V2:u.V1},{children:[r(l,t({},d({content:T,bold:v})),void 0),o(P,{children:[R&&F&&r(s,{isMobile:L,src:R,alt:F,rating:I,width:L?"90px":"122px"},void 0),r(f,{children:r(C,{children:r(i,{benefits:A},void 0)},void 0)},void 0)]},void 0),r("div",{children:!L&&H},void 0),L&&H,B&&r(b,{children:c(B)},void 0)]}),void 0)};export{g as OfferAtCartV2};
|
|
2
2
|
//# sourceMappingURL=OfferAtCartV2.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as t}from"tslib";import{jsx as r,jsxs as e,Fragment as o}from"react/jsx-runtime";import{useOfferAtCartForAutoshipCrossSell as i}from"../../../hooks/useOfferAtCartForAutoshipCrossSell/index.js";import{OfferAtCartBenefits as s}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as l}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as a}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"react";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"../../../types/enums.js";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/
|
|
1
|
+
import{__assign as t}from"tslib";import{jsx as r,jsxs as e,Fragment as o}from"react/jsx-runtime";import{useOfferAtCartForAutoshipCrossSell as i}from"../../../hooks/useOfferAtCartForAutoshipCrossSell/index.js";import{OfferAtCartBenefits as s}from"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.js";import{OfferAtCartImage as l}from"../../molecules/OfferAtCartImage/OfferAtCartImage.js";import{OfferAtCartTitle as a}from"../../molecules/OfferAtCartTitle/OfferAtCartTitle.js";import"react";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"../../../types/enums.js";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/styled.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/IconButton.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../iconsWithTitle/index.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"@emotion/react";import"../../textWithImage/index.js";import"../../timer/styled.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import{getTitleProps as m,ActionsSection as p,ErrorMessage as d}from"../OfferAtCart/OfferAtCart.js";import"../OfferAtCartV2/styled.js";import"../OfferAtCartV3/styled.js";import c from"./style.module.css.js";import{Container as n,TitleWrapper as j,Body as y,Benefits as u}from"./styled.js";import"../OfferAtPDP/styled.js";import"../OfferAtPDP/types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../SubscriptionPlanSelector/styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";import"../../molecules/CouponCard/styled.js";import"../../molecules/BenefitsList/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import{RightContent as b}from"../OfferAtCart/styled.js";var P=function(P){var f=i(P),C=f.className,g=f.title,h=g.content,S=g.bold,T=f.image,V=f.benefits,A=f.ctaText,M=void 0===A?"Yes, I want this offer":A,v=f.sizeOptions,G=f.rating,w=f.bottomCopy,I=f.theme,O=f.setSelectedSize,B=f.setShowErrorMessage,L=f.isMobile,k=f.showErrorMessage,z=f.handleOnClick,x=function(){return p(v,O,B,M,z)};return r(n,t({className:C},{children:e(o,{children:[e(j,{children:[T&&r(l,{width:"66px",height:"66px",isMobile:L,src:T.src,alt:T.alt,rating:G},void 0),r(a,t({},m({content:h,bold:S})),void 0)]},void 0),e(y,t({height:L?"120px":"162px"},{children:[r("span",{children:"Includes:"},void 0),e(b,{children:[r(u,t({id:"benefits",className:c.benefits},{children:r(s,{benefits:V},void 0)}),void 0),!L&&x(),!L&&k&&d(I)]},void 0)]}),void 0),L&&x(),L&&k&&d(I),w&&r("span",{dangerouslySetInnerHTML:{__html:w}},void 0)]},void 0)}),void 0)};export{P as OfferAtCartV4};
|
|
2
2
|
//# sourceMappingURL=OfferAtCartV4.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as t}from"tslib";import{jsxs as r,jsx as o}from"react/jsx-runtime";import{ComponentSize as e}from"../../../types/enums.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"react";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import{Image as i}from"../../atoms/Image/Image.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../../molecules/BenefitsList/styled.js";import"../../timer/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../iconsWithTitle/index.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../icon-button/IconButton.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/
|
|
1
|
+
import{__assign as t}from"tslib";import{jsxs as r,jsx as o}from"react/jsx-runtime";import{ComponentSize as e}from"../../../types/enums.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"react";import"../../../core/theme/Theme.js";import"../../../utils/constants/offerAtCart.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import{Image as i}from"../../atoms/Image/Image.js";import"../../atoms/Toggle/toggle.styled.js";import"../../radio/input/styles.js";import"../../tooltip/Styled.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../text/Text.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../../molecules/BenefitsList/styled.js";import"../../timer/styled.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../iconsWithTitle/index.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../icon-button/IconButton.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/styled.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import s from"../../cta/secondary/ButtonSecondary.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"../../textWithImage/index.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import"../OfferAtCart/styled.js";import"../OfferAtCartV2/styled.js";import"../OfferAtCartV3/styled.js";import"../OfferAtCartV4/styled.js";import{Container as l,ProductImageContainer as a,QuatityLabel as m,Body as p,OfferTitle as d,OfferText as c,DiscountValueText as n,OfferButton as j}from"./styled.js";import{VariantType as y}from"./types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../SubscriptionPlanSelector/styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";var u=function(u){var b=u.title,P=u.image,C=u.ctaText,g=u.onAddToCart,h=u.variant,f=u.discountText,S=u.discountValue,v=u.quantity,V=void 0===v?"2X":v,T=null!=P?P:{},G=T.src,M=T.alt,w=void 0===M?"Product image":M,A=T.width,I=void 0===A?"116px":A,B=T.height,L=void 0===B?"100%":B,k=T.borderRadius,z=void 0===k?"8px":k;return h==y.V1?r(l,{children:[G&&r(a,{children:[o(i,{src:G,alt:w,width:I,height:L,borderRadius:z},void 0),r(m,{children:[" ",V]},void 0)]},void 0),r(p,{children:[o(d,t({variant:"body",weight:"bold"},{children:b}),void 0),r(c,t({variant:"body"},{children:[f," ",o(n,{children:S},void 0)]}),void 0),o(j,{text:C,size:e.Medium,onClick:g},void 0)]},void 0)]},void 0):o(s,{onClick:g,wide:!0,size:e.Large,text:C},void 0)};export{u as OfferAtPDP};
|
|
2
2
|
//# sourceMappingURL=OfferAtPDP.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__makeTemplateObject as t,__assign as r}from"tslib";import{jsxs as o,Fragment as e,jsx as i}from"react/jsx-runtime";import s from"@ant-design/react-slick";import n from"@emotion/styled";import{useRef as l,useState as a,useCallback as d,useEffect as p}from"react";import m from"react-inner-image-zoom";import c from"../../../cta/primary/ButtonPrimary.js";import"@emotion/react/jsx-runtime";import"../../../../core/theme/Theme.js";import"../../../../types/enums.js";import"../../../cta/styled.js";import{usePreventVerticalScroll as u}from"../../../../hooks/usePreventVerticalScroll/usePreventVerticalScroll.js";import{stopVideoCommand as j,playVideoCommand as y}from"../utils/sendCommandToIframe.js";import{Icon as b}from"../../../icons/index.js";import"../../../PackSelectorV2/PackSelectoV2.js";import"../../../absorbency-level/AbsorbencyLevel.js";import"../../../accordion-options/AccordionOptions.js";import"../../../accordion/Accordion.js";import"../../../../utils/constants/offerAtCart.js";import"../../../../utils/media.js";import"../../../../utils/mock-content/CancellationFlowAccordion.js";import"../../../dropdown/variants/simple/SimpleDropdown.js";import"../../../radio/input/styles.js";import"../../../tooltip/Styled.js";import"../../../autoship/styled.js";import"../../../autoshipV2/styled.js";import"../../../before-after/BeforeAfter.js";import"../../../pricing/clubOffer/ClubOfferTag.js";import"../../../pricing/discount/styled.js";import"../../../pricing/styles.js";import"../../../pricing/priceLabelV2/PriceLabelV2.js";import"../../../pricing/priceLabelV3/PriceLabelV3.js";import"../../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../../shared/card/Card.js";import"../../../bundle/minimalistic/styled.js";import"../../../text/Text.js";import"../../../bundle/motivator/styled.js";import"../../../bundle/simple/Simple.js";import"../../../buynowpaylater/BuyNowPayLater.js";import"../../../offer-banner/OfferBanner.js";import"../../../cartProductItem/CloseIcon/CloseButton.js";import"../../../cartProductItem/Description/Description.js";import"../../../cartProductItem/Promo/Promo.js";import"../../../cartProductItem/Title/Title.js";import"../../../cartProductItem/TrashIcon/styled.js";import"../../../checkbox/Checkbox.js";import"../../../SkeletonBox/SkeletonBox.js";import"../../../atoms/PriceLabel/PriceLabel.js";import"../../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../../atoms/Icon/Icon.js";import"../../../atoms/Image/styled.js";import"../../../atoms/Toggle/toggle.styled.js";import"../../../club-price-label/ClubPriceLabel.js";import"../../../strength-bars/StrengthBars.js";import"../../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../../rating/starList/StarList.js";import"../../../rating/styles.js";import"../../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../../molecules/ArrowTip/ArrowTip.styled.js";import"../../../molecules/BenefitsList/styled.js";import"../../../timer/styled.js";import"../../../molecules/HurryUp/styled.js";import"../../../molecules/Spinner/styled.js";import"../../../molecules/Video/components/styled.js";import"../../../molecules/Video/styled.js";import"../../../iconsWithTitle/index.js";import"../../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../../molecules/LikeButton/styled.js";import"../../../icon-button/IconButton.js";import"../../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../../pricing/priceLabelV4/PriceLabelV4.js";import"../../../collection/product/mobile/styled.js";import"../../../collection/product/truekind/ProductItemTK.js";import"../../../collection/grid/WithProductGrid.js";import"../../../color/ColorRadioGroup.js";import"../../../color/selector/PatternSelector.js";import"../../../color/styles/ColorPickerwithTootip.styled.js";import"../../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../../delivery-details/DeliveryDetails.js";import"../../../delivery-details/Note/Note.js";import"../../../drawer/Drawer.js";import"../../../dropdown-list-icons/Styled.js";import"../../../dropdown/size-dropdown/Styled.js";import"../../../dropdown/variants/dialog/DropdownDialog.js";import"../../../dropdown/base/BaseDropdown.js";import"../../../filtering/Accordion.js";import"../../../filtering/FiltersStyled.js";import"../../../filtering/Tags/Tags.js";import"../../../fit-guarantee/FitGuarantee.js";import"../../../fit/FitPredictor.js";import"../../../slider/ArrowButton.js";import"../../../slider/StyledSlider.js";import"../../../gallery/components/ImageSmallPreview/styled.js";import"../../../gallery/components/ImagePreviewList/styled.js";import"../../../gallery/components/ImageProductSlide/styled.js";import"../../../gallery/styled.js";import"../../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../../image-card/ImageCard.js";import"../../../input/label/Label.js";import"../../../input/base/Error.js";import"../../../input/base/Styled.js";import"../../../input/custom/Custom.js";import"../../../input/basePlusButton/BasePlusButton.js";import"../../../input/basePlusIcon/BasePlusIcon.js";import"../../../modal/Modal.js";import"../../../motivator-progress-bar/MotivatorProgressBar.js";import"../../../order-bar/OrderBar.js";import"../../../packs/selector/PackSelector.js";import"../../../pagination/styles.js";import"../../../payment-methods/PaymentMethod.js";import"../../../product/order/item/SimpleOrderItem.js";import"../../../progress-bar/ProgressBar.js";import"../../../quantityPicker/QuantityPicker.js";import"../../../radio/RadioPrimary/radioPrimary.js";import"../../../radio/clubRadioInput/clubRadio.js";import"../../../review-detail/ReviewDetail.js";import"../../../review/Review.js";import"../../../reviews-header/ReviewsHeader.js";import"../../../scroll-to-top/ScrollToTop.js";import"../../../search-bar/components/ClearButton/styled.js";import"../../../search-bar/components/Footer/styled.js";import"../../../search-bar/components/ProductItem/styled.js";import"../../../search-bar/components/ResultsPanel/styled.js";import"../../../search-bar/components/SearchControl/styled.js";import"../../../search-bar/styled.js";import"../../../search-navigation/styled.js";import"react-dom";import"../../../short-banner/ShortBanner.js";import"../../../size-chart/styled.js";import"../../../size-table/SizeTable.js";import"../../../size/guide/SizeFitGuide.js";import"../../../size/selector/styled.js";import"../../../tabs/Tab.js";import"../../../tabs/Tabs.js";import"../../../tag/Tag.js";import"../../../textWithImage/index.js";import"../../../toast/Toast.js";import"../../../totals/total/styled.js";import"../../../totals/subtotal/Subtotal.js";import"../../../tracking-progress-v2/TrackingProgressV2.js";import"../../../tracking-progress/TrackingProgress.js";import"../../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../../BasicAccordion/BasicAccordion.js";import"../../CartItemCard/CartItem.js";import"../../ClubOfferSelector/styled.js";import"../../ClubOfferSelector2/styled.js";import"../../JoinClubCard/joinClubCard.js";import"../../OfferAtCart/styled.js";import"../../OfferAtCartV2/styled.js";import"../../OfferAtCartV3/styled.js";import"../../OfferAtCartV4/styled.js";import"../../OfferAtPDP/styled.js";import"../../OfferAtPDP/types.js";import"../../ProductCard/ProductCardV1/ProductCard.js";import"../../ProductCard/ProductCardV2/styled.js";import"../../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"./ProductGalleryMobileV3.js";import"../ProductGalleryMobileV4/ContentGallery/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobileV6/styled.js";import"../../SizeCharTable/SizeChartTableV2/styled.js";import"../../SizeCharTable/SizeChartTableV3/styled.js";import"../../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../../SubscriptionPlanSelector/styled.js";import"../../TwoCtasAtCart/Greeting.styled.js";import"../../TwoCtasAtCart/Card.styled.js";var f,h,g,v,P,C,x,w,S,V=n.div(f||(f=t(["\n ","\n position: relative;\n max-height: 524px;\n overflow: hidden;\n & .slick-dots li.slick-active button:before {\n background-color: ",";\n }\n"],["\n ","\n position: relative;\n max-height: 524px;\n overflow: hidden;\n & .slick-dots li.slick-active button:before {\n background-color: ",";\n }\n"])),(function(t){return t.borderRadiusVariant&&"\n border-radius: 40px;\n "}),(function(t){return t.theme.component.slideNavigation.slideDots.selectedDotColor})),T=n.div(h||(h=t(["\n position: absolute;\n left: ",";\n top: ",";\n"],["\n position: absolute;\n left: ",";\n top: ",";\n"])),(function(t){return t.borderRadiusVariant?"13px":"0"}),(function(t){return t.borderRadiusVariant?"11px":"0"})),k=n.div(g||(g=t(["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"],["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"]))),A=n.div(v||(v=t(["\n content: '';\n background: transparent;\n width: 100%;\n height: 100%;\n min-height: 1px;\n position: absolute;\n top: 0;\n"],["\n content: '';\n background: transparent;\n width: 100%;\n height: 100%;\n min-height: 1px;\n position: absolute;\n top: 0;\n"]))),I=n.div(P||(P=t(["\n position: relative;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 510px;\n background: #efefef;\n\n & > iframe {\n border: none;\n }\n"],["\n position: relative;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 510px;\n background: #efefef;\n\n & > iframe {\n border: none;\n }\n"]))),B=n.div(C||(C=t(["\n gap: 8px;\n position: absolute;\n width: 100%;\n bottom: 50px;\n display: flex;\n padding: 8.6px 0;\n font-weight: 600;\n align-items: center;\n background: #f7f7f7;\n justify-content: center;\n"],["\n gap: 8px;\n position: absolute;\n width: 100%;\n bottom: 50px;\n display: flex;\n padding: 8.6px 0;\n font-weight: 600;\n align-items: center;\n background: #f7f7f7;\n justify-content: center;\n"]))),G=n.div(x||(x=t(["\n padding-top: 3px;\n"],["\n padding-top: 3px;\n"]))),L=n.div(w||(w=t(["\n height: 40px;\n width: 40px;\n"],["\n height: 40px;\n width: 40px;\n"]))),z=n.button(S||(S=t(["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n z-index: 5;\n height: 40px !important;\n cursor: pointer;\n"],["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n z-index: 5;\n height: 40px !important;\n cursor: pointer;\n"]))),O={dots:!0,infinite:!1,speed:200,slidesToShow:1,slidesToScroll:1,initialSlide:0},M=function(t){var n=t.images,f=t.customClick,h=void 0!==f&&f,g=t.topTag,v=t.bottomTag,P=t.testId,C=t.borderRadiusVariant,x=t.selectedValue,w=l(null),S=l(null),M=l(null),D=a(!1),R=D[0],F=D[1];u(S);var W=d((function(t){var r;null===(r=w.current)||void 0===r||r.slickGoTo(t)}),[w]),N=function(){j(),F((function(t){return t?!t:t}))},H=function(){y(),F((function(t){return t?!t:t}))};return p((function(){var t;if(x){var r=n.findIndex((function(t){return t.url===x.url}));-1!==r&&(null===(t=w.current)||void 0===t||t.slickGoTo(r))}}),[n,x]),o(e,{children:[h&&i("div",r({style:{display:"flex",marginBottom:"20px",gap:"10px"}},{children:n.map((function(t,r){return i(c,{onClick:function(){return W(r)},text:String(r+1),inline:!0},r)}))}),void 0),i(V,r({"data-testid":P,borderRadiusVariant:C,ref:S},{children:i(s,r({afterChange:function(t){var r,o=n[t];(null===(r=null==o?void 0:o.url)||void 0===r?void 0:r.includes("autoplay=1"))?H():N()}},O,{nextArrow:i(L,{children:i(z,{children:i(b.Arrows.ChevronRight,{height:2.125,width:1.25,fill:"#292929"},void 0)},void 0)},void 0),prevArrow:i(L,{children:i(z,{children:i(b.Arrows.ChevronLeft,{height:2.125,width:1.25,fill:"#292929"},void 0)},void 0)},void 0),ref:w},{children:n.map((function(t){var s,n;return o("div",{children:[!(null===(s=null==t?void 0:t.alt)||void 0===s?void 0:s.includes("-video"))&&o(e,{children:[i(m,{src:t.url,zoomSrc:t.url,zoomType:"hover",imgAttributes:{alt:t.alt,width:"100%",height:"510px"},height:510,fullscreenOnMobile:!0,className:"zoomWrapper"},void 0),i(T,r({borderRadiusVariant:C,"data-testid":"topTag"},{children:g}),void 0),i(k,r({"data-testid":"bottomTag"},{children:v}),void 0)]},void 0),(null===(n=null==t?void 0:t.alt)||void 0===n?void 0:n.includes("-video"))&&o(I,{children:[i("iframe",{id:"vwo-video",ref:M,allowFullScreen:!0,title:t.alt,width:"100%",height:"220px",src:null==t?void 0:t.url,allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"},void 0),i(A,{onClick:function(){R?N():H()}},void 0),o(B,{children:[i(b.PDP.PlayMini,{width:1.5},void 0),i(G,{children:"VIDEO"},void 0)]},void 0)]},void 0)]},t.key)}))}),void 0)}),void 0)]},void 0)};export{M as ImageProductSlideV3};
|
|
1
|
+
import{__makeTemplateObject as t,__assign as r}from"tslib";import{jsxs as o,Fragment as e,jsx as i}from"react/jsx-runtime";import s from"@ant-design/react-slick";import n from"@emotion/styled";import{useRef as l,useState as a,useCallback as d,useEffect as p}from"react";import m from"react-inner-image-zoom";import c from"../../../cta/primary/ButtonPrimary.js";import"@emotion/react/jsx-runtime";import"../../../../core/theme/Theme.js";import"../../../../types/enums.js";import"../../../cta/styled.js";import{usePreventVerticalScroll as u}from"../../../../hooks/usePreventVerticalScroll/usePreventVerticalScroll.js";import{stopVideoCommand as j,playVideoCommand as y}from"../utils/sendCommandToIframe.js";import{Icon as b}from"../../../icons/index.js";import"../../../PackSelectorV2/PackSelectoV2.js";import"../../../absorbency-level/AbsorbencyLevel.js";import"../../../accordion-options/AccordionOptions.js";import"../../../accordion/Accordion.js";import"../../../../utils/constants/offerAtCart.js";import"../../../../utils/media.js";import"../../../../utils/mock-content/CancellationFlowAccordion.js";import"../../../dropdown/variants/simple/SimpleDropdown.js";import"../../../radio/input/styles.js";import"../../../tooltip/Styled.js";import"../../../autoship/styled.js";import"../../../autoshipV2/styled.js";import"../../../before-after/BeforeAfter.js";import"../../../pricing/clubOffer/ClubOfferTag.js";import"../../../pricing/discount/styled.js";import"../../../pricing/styles.js";import"../../../pricing/priceLabelV2/PriceLabelV2.js";import"../../../pricing/priceLabelV3/PriceLabelV3.js";import"../../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../../shared/card/Card.js";import"../../../bundle/minimalistic/styled.js";import"../../../text/Text.js";import"../../../bundle/motivator/styled.js";import"../../../bundle/simple/Simple.js";import"../../../buynowpaylater/BuyNowPayLater.js";import"../../../offer-banner/OfferBanner.js";import"../../../cartProductItem/CloseIcon/CloseButton.js";import"../../../cartProductItem/Description/Description.js";import"../../../cartProductItem/Promo/Promo.js";import"../../../cartProductItem/Title/Title.js";import"../../../cartProductItem/TrashIcon/styled.js";import"../../../checkbox/Checkbox.js";import"../../../SkeletonBox/SkeletonBox.js";import"../../../atoms/PriceLabel/PriceLabel.js";import"../../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../../atoms/Icon/Icon.js";import"../../../atoms/Image/styled.js";import"../../../atoms/Toggle/toggle.styled.js";import"../../../club-price-label/ClubPriceLabel.js";import"../../../strength-bars/StrengthBars.js";import"../../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../../rating/starList/StarList.js";import"../../../rating/styles.js";import"../../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../../molecules/CouponCard/styled.js";import"@emotion/react";import"../../../molecules/ArrowTip/ArrowTip.styled.js";import"../../../molecules/BenefitsList/styled.js";import"../../../timer/styled.js";import"../../../molecules/HurryUp/styled.js";import"../../../molecules/Spinner/styled.js";import"../../../molecules/Video/components/styled.js";import"../../../molecules/Video/styled.js";import"../../../iconsWithTitle/index.js";import"../../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../../molecules/LikeButton/styled.js";import"../../../icon-button/IconButton.js";import"../../../molecules/ScarcityTag/ScarcityTag.styled.js";import"../../../pricing/priceLabelV4/PriceLabelV4.js";import"../../../collection/product/mobile/styled.js";import"../../../collection/product/truekind/styled.js";import"../../../collection/grid/WithProductGrid.js";import"../../../color/ColorRadioGroup.js";import"../../../color/selector/PatternSelector.js";import"../../../color/styles/ColorPickerwithTootip.styled.js";import"../../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../../delivery-details/DeliveryDetails.js";import"../../../delivery-details/Note/Note.js";import"../../../drawer/Drawer.js";import"../../../dropdown-list-icons/Styled.js";import"../../../dropdown/size-dropdown/Styled.js";import"../../../dropdown/variants/dialog/DropdownDialog.js";import"../../../dropdown/base/BaseDropdown.js";import"../../../filtering/Accordion.js";import"../../../filtering/FiltersStyled.js";import"../../../filtering/Tags/Tags.js";import"../../../fit-guarantee/FitGuarantee.js";import"../../../fit/FitPredictor.js";import"../../../slider/ArrowButton.js";import"../../../slider/StyledSlider.js";import"../../../gallery/components/ImageSmallPreview/styled.js";import"../../../gallery/components/ImagePreviewList/styled.js";import"../../../gallery/components/ImageProductSlide/styled.js";import"../../../gallery/styled.js";import"../../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../../image-card/ImageCard.js";import"../../../input/label/Label.js";import"../../../input/base/Error.js";import"../../../input/base/Styled.js";import"../../../input/custom/Custom.js";import"../../../input/basePlusButton/BasePlusButton.js";import"../../../input/basePlusIcon/BasePlusIcon.js";import"../../../modal/Modal.js";import"../../../motivator-progress-bar/MotivatorProgressBar.js";import"../../../order-bar/OrderBar.js";import"../../../packs/selector/PackSelector.js";import"../../../pagination/styles.js";import"../../../payment-methods/PaymentMethod.js";import"../../../product/order/item/SimpleOrderItem.js";import"../../../progress-bar/ProgressBar.js";import"../../../quantityPicker/QuantityPicker.js";import"../../../radio/RadioPrimary/radioPrimary.js";import"../../../radio/clubRadioInput/clubRadio.js";import"../../../review-detail/ReviewDetail.js";import"../../../review/Review.js";import"../../../reviews-header/ReviewsHeader.js";import"../../../scroll-to-top/ScrollToTop.js";import"../../../search-bar/components/ClearButton/styled.js";import"../../../search-bar/components/Footer/styled.js";import"../../../search-bar/components/ProductItem/styled.js";import"../../../search-bar/components/ResultsPanel/styled.js";import"../../../search-bar/components/SearchControl/styled.js";import"../../../search-bar/styled.js";import"../../../search-navigation/styled.js";import"react-dom";import"../../../short-banner/ShortBanner.js";import"../../../size-chart/styled.js";import"../../../size-table/SizeTable.js";import"../../../size/guide/SizeFitGuide.js";import"../../../size/selector/styled.js";import"../../../tabs/Tab.js";import"../../../tabs/Tabs.js";import"../../../tag/Tag.js";import"../../../textWithImage/index.js";import"../../../toast/Toast.js";import"../../../totals/total/styled.js";import"../../../totals/subtotal/Subtotal.js";import"../../../tracking-progress-v2/TrackingProgressV2.js";import"../../../tracking-progress/TrackingProgress.js";import"../../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../../BasicAccordion/BasicAccordion.js";import"../../CartItemCard/CartItem.js";import"../../ClubOfferSelector/styled.js";import"../../ClubOfferSelector2/styled.js";import"../../JoinClubCard/joinClubCard.js";import"../../OfferAtCart/styled.js";import"../../OfferAtCartV2/styled.js";import"../../OfferAtCartV3/styled.js";import"../../OfferAtCartV4/styled.js";import"../../OfferAtPDP/styled.js";import"../../OfferAtPDP/types.js";import"../../ProductCard/ProductCardV1/ProductCard.js";import"../../ProductCard/ProductCardV2/styled.js";import"../../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"./ProductGalleryMobileV3.js";import"../ProductGalleryMobileV4/ContentGallery/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobileV6/styled.js";import"../../SizeCharTable/SizeChartTableV2/styled.js";import"../../SizeCharTable/SizeChartTableV3/styled.js";import"../../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../../SubscriptionPlanSelector/styled.js";import"../../TwoCtasAtCart/Greeting.styled.js";import"../../TwoCtasAtCart/Card.styled.js";var f,h,g,v,P,C,x,w,S,V=n.div(f||(f=t(["\n ","\n position: relative;\n max-height: 524px;\n overflow: hidden;\n & .slick-dots li.slick-active button:before {\n background-color: ",";\n }\n"],["\n ","\n position: relative;\n max-height: 524px;\n overflow: hidden;\n & .slick-dots li.slick-active button:before {\n background-color: ",";\n }\n"])),(function(t){return t.borderRadiusVariant&&"\n border-radius: 40px;\n "}),(function(t){return t.theme.component.slideNavigation.slideDots.selectedDotColor})),T=n.div(h||(h=t(["\n position: absolute;\n left: ",";\n top: ",";\n"],["\n position: absolute;\n left: ",";\n top: ",";\n"])),(function(t){return t.borderRadiusVariant?"13px":"0"}),(function(t){return t.borderRadiusVariant?"11px":"0"})),k=n.div(g||(g=t(["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"],["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"]))),A=n.div(v||(v=t(["\n content: '';\n background: transparent;\n width: 100%;\n height: 100%;\n min-height: 1px;\n position: absolute;\n top: 0;\n"],["\n content: '';\n background: transparent;\n width: 100%;\n height: 100%;\n min-height: 1px;\n position: absolute;\n top: 0;\n"]))),I=n.div(P||(P=t(["\n position: relative;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 510px;\n background: #efefef;\n\n & > iframe {\n border: none;\n }\n"],["\n position: relative;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 510px;\n background: #efefef;\n\n & > iframe {\n border: none;\n }\n"]))),B=n.div(C||(C=t(["\n gap: 8px;\n position: absolute;\n width: 100%;\n bottom: 50px;\n display: flex;\n padding: 8.6px 0;\n font-weight: 600;\n align-items: center;\n background: #f7f7f7;\n justify-content: center;\n"],["\n gap: 8px;\n position: absolute;\n width: 100%;\n bottom: 50px;\n display: flex;\n padding: 8.6px 0;\n font-weight: 600;\n align-items: center;\n background: #f7f7f7;\n justify-content: center;\n"]))),G=n.div(x||(x=t(["\n padding-top: 3px;\n"],["\n padding-top: 3px;\n"]))),L=n.div(w||(w=t(["\n height: 40px;\n width: 40px;\n"],["\n height: 40px;\n width: 40px;\n"]))),z=n.button(S||(S=t(["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n z-index: 5;\n height: 40px !important;\n cursor: pointer;\n"],["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n z-index: 5;\n height: 40px !important;\n cursor: pointer;\n"]))),O={dots:!0,infinite:!1,speed:200,slidesToShow:1,slidesToScroll:1,initialSlide:0},M=function(t){var n=t.images,f=t.customClick,h=void 0!==f&&f,g=t.topTag,v=t.bottomTag,P=t.testId,C=t.borderRadiusVariant,x=t.selectedValue,w=l(null),S=l(null),M=l(null),D=a(!1),R=D[0],F=D[1];u(S);var W=d((function(t){var r;null===(r=w.current)||void 0===r||r.slickGoTo(t)}),[w]),N=function(){j(),F((function(t){return t?!t:t}))},H=function(){y(),F((function(t){return t?!t:t}))};return p((function(){var t;if(x){var r=n.findIndex((function(t){return t.url===x.url}));-1!==r&&(null===(t=w.current)||void 0===t||t.slickGoTo(r))}}),[n,x]),o(e,{children:[h&&i("div",r({style:{display:"flex",marginBottom:"20px",gap:"10px"}},{children:n.map((function(t,r){return i(c,{onClick:function(){return W(r)},text:String(r+1),inline:!0},r)}))}),void 0),i(V,r({"data-testid":P,borderRadiusVariant:C,ref:S},{children:i(s,r({afterChange:function(t){var r,o=n[t];(null===(r=null==o?void 0:o.url)||void 0===r?void 0:r.includes("autoplay=1"))?H():N()}},O,{nextArrow:i(L,{children:i(z,{children:i(b.Arrows.ChevronRight,{height:2.125,width:1.25,fill:"#292929"},void 0)},void 0)},void 0),prevArrow:i(L,{children:i(z,{children:i(b.Arrows.ChevronLeft,{height:2.125,width:1.25,fill:"#292929"},void 0)},void 0)},void 0),ref:w},{children:n.map((function(t){var s,n;return o("div",{children:[!(null===(s=null==t?void 0:t.alt)||void 0===s?void 0:s.includes("-video"))&&o(e,{children:[i(m,{src:t.url,zoomSrc:t.url,zoomType:"hover",imgAttributes:{alt:t.alt,width:"100%",height:"510px"},height:510,fullscreenOnMobile:!0,className:"zoomWrapper"},void 0),i(T,r({borderRadiusVariant:C,"data-testid":"topTag"},{children:g}),void 0),i(k,r({"data-testid":"bottomTag"},{children:v}),void 0)]},void 0),(null===(n=null==t?void 0:t.alt)||void 0===n?void 0:n.includes("-video"))&&o(I,{children:[i("iframe",{id:"vwo-video",ref:M,allowFullScreen:!0,title:t.alt,width:"100%",height:"220px",src:null==t?void 0:t.url,allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"},void 0),i(A,{onClick:function(){R?N():H()}},void 0),o(B,{children:[i(b.PDP.PlayMini,{width:1.5},void 0),i(G,{children:"VIDEO"},void 0)]},void 0)]},void 0)]},t.key)}))}),void 0)}),void 0)]},void 0)};export{M as ImageProductSlideV3};
|
|
2
2
|
//# sourceMappingURL=ImageProductSlideV3.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as t}from"tslib";import{jsx as r,jsxs as o,Fragment as e}from"react/jsx-runtime";import i from"@ant-design/react-slick";import{useRef as s,useState as l,useEffect as a,useLayoutEffect as m}from"react";import"../../../../PackSelectorV2/PackSelectoV2.js";import"../../../../absorbency-level/AbsorbencyLevel.js";import"../../../../accordion-options/AccordionOptions.js";import"../../../../accordion/Accordion.js";import"../../../../../types/enums.js";import"../../../../../core/theme/Theme.js";import"../../../../../utils/constants/offerAtCart.js";import{debounce as p}from"../../../../../utils/debounce/index.js";import"../../../../../utils/media.js";import"../../../../../utils/mock-content/CancellationFlowAccordion.js";import"../../../../dropdown/variants/simple/SimpleDropdown.js";import"../../../../atoms/PriceLabel/PriceLabel.js";import"../../../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../../../atoms/Icon/Icon.js";import{Image as d}from"../../../../atoms/Image/Image.js";import"../../../../atoms/Toggle/toggle.styled.js";import"../../../../radio/input/styles.js";import"../../../../tooltip/Styled.js";import"../../../../autoship/styled.js";import"../../../../autoshipV2/styled.js";import"../../../../before-after/BeforeAfter.js";import"../../../../pricing/clubOffer/ClubOfferTag.js";import"../../../../pricing/discount/styled.js";import"../../../../pricing/styles.js";import"../../../../pricing/priceLabelV2/PriceLabelV2.js";import"../../../../pricing/priceLabelV3/PriceLabelV3.js";import"../../../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../../../shared/card/Card.js";import"../../../../bundle/minimalistic/styled.js";import"../../../../text/Text.js";import"../../../../bundle/motivator/styled.js";import"../../../../bundle/simple/Simple.js";import"../../../../buynowpaylater/BuyNowPayLater.js";import"../../../../offer-banner/OfferBanner.js";import"../../../../cartProductItem/CloseIcon/CloseButton.js";import"../../../../cartProductItem/Description/Description.js";import"../../../../cartProductItem/Promo/Promo.js";import"../../../../cartProductItem/Title/Title.js";import"../../../../cartProductItem/TrashIcon/styled.js";import"../../../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../../../SkeletonBox/SkeletonBox.js";import"../../../../club-price-label/ClubPriceLabel.js";import"../../../../strength-bars/StrengthBars.js";import"../../../../pricing/priceLabelV4/PriceLabelV4.js";import"../../../../rating/starList/StarList.js";import"../../../../rating/styles.js";import"../../../../collection/product/mobile/styled.js";import"../../../../collection/product/truekind/ProductItemTK.js";import"../../../../collection/grid/WithProductGrid.js";import"../../../../color/ColorRadioGroup.js";import"../../../../color/selector/PatternSelector.js";import"../../../../color/styles/ColorPickerwithTootip.styled.js";import"../../../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../../../cta/styled.js";import"../../../../delivery-details/DeliveryDetails.js";import"../../../../delivery-details/Note/Note.js";import"../../../../drawer/Drawer.js";import"../../../../dropdown-list-icons/Styled.js";import"../../../../dropdown/size-dropdown/Styled.js";import"../../../../dropdown/variants/dialog/DropdownDialog.js";import"../../../../dropdown/base/BaseDropdown.js";import"../../../../filtering/Accordion.js";import"../../../../filtering/FiltersStyled.js";import"../../../../filtering/Tags/Tags.js";import"../../../../fit-guarantee/FitGuarantee.js";import"../../../../fit/FitPredictor.js";import"../../../../slider/ArrowButton.js";import"../../../../slider/StyledSlider.js";import"../../../../gallery/components/ImageSmallPreview/styled.js";import"../../../../gallery/components/ImagePreviewList/styled.js";import{Video as n}from"../../../../molecules/Video/Video.js";import"../../../../gallery/components/ImageProductSlide/styled.js";import"../../../../gallery/styled.js";import"../../../../icon-button/IconButton.js";import"../../../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../../../iconsWithTitle/index.js";import"../../../../image-card/ImageCard.js";import"../../../../input/label/Label.js";import"../../../../input/base/Error.js";import"../../../../input/base/Styled.js";import"../../../../input/custom/Custom.js";import"../../../../input/basePlusButton/BasePlusButton.js";import"../../../../input/basePlusIcon/BasePlusIcon.js";import"../../../../modal/Modal.js";import"../../../../motivator-progress-bar/MotivatorProgressBar.js";import"../../../../order-bar/OrderBar.js";import"../../../../packs/selector/PackSelector.js";import"../../../../pagination/styles.js";import"../../../../payment-methods/PaymentMethod.js";import"../../../../product/order/item/SimpleOrderItem.js";import"../../../../progress-bar/ProgressBar.js";import"../../../../quantityPicker/QuantityPicker.js";import"../../../../radio/RadioPrimary/radioPrimary.js";import"../../../../radio/clubRadioInput/clubRadio.js";import"../../../../review-detail/ReviewDetail.js";import"../../../../review/Review.js";import"../../../../reviews-header/ReviewsHeader.js";import"../../../../scroll-to-top/ScrollToTop.js";import"../../../../search-bar/components/ClearButton/styled.js";import"../../../../search-bar/components/Footer/styled.js";import"../../../../search-bar/components/ProductItem/styled.js";import"../../../../search-bar/components/ResultsPanel/styled.js";import"../../../../search-bar/components/SearchControl/styled.js";import"../../../../search-bar/styled.js";import"../../../../search-navigation/styled.js";import"react-dom";import"../../../../short-banner/ShortBanner.js";import"../../../../size-chart/styled.js";import"../../../../size-table/SizeTable.js";import"../../../../size/guide/SizeFitGuide.js";import"../../../../size/selector/styled.js";import"../../../../tabs/Tab.js";import"../../../../tabs/Tabs.js";import"../../../../tag/Tag.js";import"@emotion/react";import"../../../../textWithImage/index.js";import"../../../../timer/styled.js";import"../../../../toast/Toast.js";import"../../../../totals/total/styled.js";import"../../../../totals/subtotal/Subtotal.js";import"../../../../tracking-progress-v2/TrackingProgressV2.js";import"../../../../tracking-progress/TrackingProgress.js";import"../../../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../../../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../../../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../../../BasicAccordion/BasicAccordion.js";import"../../../CartItemCard/CartItem.js";import"../../../ClubOfferSelector/styled.js";import"../../../ClubOfferSelector2/styled.js";import"../../../JoinClubCard/joinClubCard.js";import"../../../OfferAtCart/styled.js";import"../../../OfferAtCartV2/styled.js";import"../../../OfferAtCartV3/styled.js";import"../../../OfferAtCartV4/styled.js";import"../../../OfferAtPDP/styled.js";import"../../../OfferAtPDP/types.js";import"../../../ProductCard/ProductCardV1/ProductCard.js";import"../../../ProductCard/ProductCardV2/styled.js";import"../../../ProductCard/ProductCardV3/styled.js";import"../../ProductGalleryMobileV1/ProductGalleryMobile.js";import"../../ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../../ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"../../ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../../ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../../ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../../ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../../ProductGalleryMobileV5/styled.js";import"../ColorVariantsGallery/styled.js";import{MainGalleryContainer as c,TopTag as j,BottomTag as u,TopRightTag as y}from"./styled.js";import"../styled.js";import"../../../SizeCharTable/SizeChartTableV2/styled.js";import"../../../SizeCharTable/SizeChartTableV3/styled.js";import"../../../../molecules/ArrowTip/ArrowTip.styled.js";import"../../../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../../../SubscriptionPlanSelector/styled.js";import"../../../TwoCtasAtCart/Greeting.styled.js";import"../../../TwoCtasAtCart/Card.styled.js";import"../../../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../../../molecules/CouponCard/styled.js";import"../../../../molecules/BenefitsList/styled.js";import"../../../../molecules/HurryUp/styled.js";import"../../../../molecules/Spinner/styled.js";import"../../../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../../../molecules/LikeButton/styled.js";import"../../../../molecules/ScarcityTag/ScarcityTag.styled.js";var b={dots:!1,infinite:!1,speed:200,slidesToScroll:1,initialSlide:0},f=function(t){if(!(null==t?void 0:t.current))return 1.1;return(t.current.offsetWidth-15)/312-1e-4},P=function(P){var g,C,h,v=P.contents,S=P.topTag,T=P.topRightTag,V=P.bottomTag,w=P.containerRef,A=s(null),I=s(null),L=l(null!==(g=f(w))&&void 0!==g?g:1),B=L[0],k=L[1],G=null===(C=null==v?void 0:v[0])||void 0===C?void 0:C.key;return a((function(){var t;null===(t=A.current)||void 0===t||t.slickGoTo(0,!0)}),[G]),m((function(){if(null==w?void 0:w.current){var t=p((function(){var t;k(null!==(t=f(w))&&void 0!==t?t:1)}),300);return t(),window.addEventListener("resize",t),function(){return window.removeEventListener("resize",t)}}}),[w,null===(h=null==w?void 0:w.current)||void 0===h?void 0:h.offsetWidth]),r(c,t({ref:I},{children:r(i,t({},b,{slidesToShow:B,ref:A,centerPadding:"80"},{children:v.map((function(i,s){var l,a=null==i?void 0:i.url,m=null!==(l=null==i?void 0:i.isVideo)&&void 0!==l&&l;return r("div",t({"data-testid":"main-gallery-div-content-".concat(s)},{children:m?r(n,{source:a,thumbnail:null==i?void 0:i.thumbnailUrl},void 0):o(e,{children:[r(d,{src:a,alt:i.alt,width:"".concat(312,"px"),loading:"eager"},void 0),r(j,t({"data-testid":"topTag"},{children:S}),void 0),r(u,t({"data-testid":"bottomTag"},{children:V}),void 0),!!T&&r(y,{children:T},void 0)]},void 0)}),i.key)}))}),void 0)}),void 0)};export{P as MainGallery};
|
|
1
|
+
import{__assign as t}from"tslib";import{jsx as r,jsxs as o,Fragment as e}from"react/jsx-runtime";import i from"@ant-design/react-slick";import{useRef as s,useState as l,useEffect as a,useLayoutEffect as m}from"react";import"../../../../PackSelectorV2/PackSelectoV2.js";import"../../../../absorbency-level/AbsorbencyLevel.js";import"../../../../accordion-options/AccordionOptions.js";import"../../../../accordion/Accordion.js";import"../../../../../types/enums.js";import"../../../../../core/theme/Theme.js";import"../../../../../utils/constants/offerAtCart.js";import{debounce as p}from"../../../../../utils/debounce/index.js";import"../../../../../utils/media.js";import"../../../../../utils/mock-content/CancellationFlowAccordion.js";import"../../../../dropdown/variants/simple/SimpleDropdown.js";import"../../../../atoms/PriceLabel/PriceLabel.js";import"../../../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../../../atoms/Icon/Icon.js";import{Image as d}from"../../../../atoms/Image/Image.js";import"../../../../atoms/Toggle/toggle.styled.js";import"../../../../radio/input/styles.js";import"../../../../tooltip/Styled.js";import"../../../../autoship/styled.js";import"../../../../autoshipV2/styled.js";import"../../../../before-after/BeforeAfter.js";import"../../../../pricing/clubOffer/ClubOfferTag.js";import"../../../../pricing/discount/styled.js";import"../../../../pricing/styles.js";import"../../../../pricing/priceLabelV2/PriceLabelV2.js";import"../../../../pricing/priceLabelV3/PriceLabelV3.js";import"../../../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../../../shared/card/Card.js";import"../../../../bundle/minimalistic/styled.js";import"../../../../text/Text.js";import"../../../../bundle/motivator/styled.js";import"../../../../bundle/simple/Simple.js";import"../../../../buynowpaylater/BuyNowPayLater.js";import"../../../../offer-banner/OfferBanner.js";import"../../../../cartProductItem/CloseIcon/CloseButton.js";import"../../../../cartProductItem/Description/Description.js";import"../../../../cartProductItem/Promo/Promo.js";import"../../../../cartProductItem/Title/Title.js";import"../../../../cartProductItem/TrashIcon/styled.js";import"../../../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../../../SkeletonBox/SkeletonBox.js";import"../../../../club-price-label/ClubPriceLabel.js";import"../../../../strength-bars/StrengthBars.js";import"../../../../pricing/priceLabelV4/PriceLabelV4.js";import"../../../../rating/starList/StarList.js";import"../../../../rating/styles.js";import"../../../../collection/product/mobile/styled.js";import"../../../../collection/product/truekind/styled.js";import"../../../../collection/grid/WithProductGrid.js";import"../../../../color/ColorRadioGroup.js";import"../../../../color/selector/PatternSelector.js";import"../../../../color/styles/ColorPickerwithTootip.styled.js";import"../../../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../../../cta/styled.js";import"../../../../delivery-details/DeliveryDetails.js";import"../../../../delivery-details/Note/Note.js";import"../../../../drawer/Drawer.js";import"../../../../dropdown-list-icons/Styled.js";import"../../../../dropdown/size-dropdown/Styled.js";import"../../../../dropdown/variants/dialog/DropdownDialog.js";import"../../../../dropdown/base/BaseDropdown.js";import"../../../../filtering/Accordion.js";import"../../../../filtering/FiltersStyled.js";import"../../../../filtering/Tags/Tags.js";import"../../../../fit-guarantee/FitGuarantee.js";import"../../../../fit/FitPredictor.js";import"../../../../slider/ArrowButton.js";import"../../../../slider/StyledSlider.js";import"../../../../gallery/components/ImageSmallPreview/styled.js";import"../../../../gallery/components/ImagePreviewList/styled.js";import{Video as n}from"../../../../molecules/Video/Video.js";import"../../../../gallery/components/ImageProductSlide/styled.js";import"../../../../gallery/styled.js";import"../../../../icon-button/IconButton.js";import"../../../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../../../iconsWithTitle/index.js";import"../../../../image-card/ImageCard.js";import"../../../../input/label/Label.js";import"../../../../input/base/Error.js";import"../../../../input/base/Styled.js";import"../../../../input/custom/Custom.js";import"../../../../input/basePlusButton/BasePlusButton.js";import"../../../../input/basePlusIcon/BasePlusIcon.js";import"../../../../modal/Modal.js";import"../../../../motivator-progress-bar/MotivatorProgressBar.js";import"../../../../order-bar/OrderBar.js";import"../../../../packs/selector/PackSelector.js";import"../../../../pagination/styles.js";import"../../../../payment-methods/PaymentMethod.js";import"../../../../product/order/item/SimpleOrderItem.js";import"../../../../progress-bar/ProgressBar.js";import"../../../../quantityPicker/QuantityPicker.js";import"../../../../radio/RadioPrimary/radioPrimary.js";import"../../../../radio/clubRadioInput/clubRadio.js";import"../../../../review-detail/ReviewDetail.js";import"../../../../review/Review.js";import"../../../../reviews-header/ReviewsHeader.js";import"../../../../scroll-to-top/ScrollToTop.js";import"../../../../search-bar/components/ClearButton/styled.js";import"../../../../search-bar/components/Footer/styled.js";import"../../../../search-bar/components/ProductItem/styled.js";import"../../../../search-bar/components/ResultsPanel/styled.js";import"../../../../search-bar/components/SearchControl/styled.js";import"../../../../search-bar/styled.js";import"../../../../search-navigation/styled.js";import"react-dom";import"../../../../short-banner/ShortBanner.js";import"../../../../size-chart/styled.js";import"../../../../size-table/SizeTable.js";import"../../../../size/guide/SizeFitGuide.js";import"../../../../size/selector/styled.js";import"../../../../tabs/Tab.js";import"../../../../tabs/Tabs.js";import"../../../../tag/Tag.js";import"@emotion/react";import"../../../../textWithImage/index.js";import"../../../../timer/styled.js";import"../../../../toast/Toast.js";import"../../../../totals/total/styled.js";import"../../../../totals/subtotal/Subtotal.js";import"../../../../tracking-progress-v2/TrackingProgressV2.js";import"../../../../tracking-progress/TrackingProgress.js";import"../../../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../../../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../../../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../../../BasicAccordion/BasicAccordion.js";import"../../../CartItemCard/CartItem.js";import"../../../ClubOfferSelector/styled.js";import"../../../ClubOfferSelector2/styled.js";import"../../../JoinClubCard/joinClubCard.js";import"../../../OfferAtCart/styled.js";import"../../../OfferAtCartV2/styled.js";import"../../../OfferAtCartV3/styled.js";import"../../../OfferAtCartV4/styled.js";import"../../../OfferAtPDP/styled.js";import"../../../OfferAtPDP/types.js";import"../../../ProductCard/ProductCardV1/ProductCard.js";import"../../../ProductCard/ProductCardV2/styled.js";import"../../../ProductCard/ProductCardV3/styled.js";import"../../ProductGalleryMobileV1/ProductGalleryMobile.js";import"../../ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../../ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"../../ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../../ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../../ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../../ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../../ProductGalleryMobileV5/styled.js";import"../ColorVariantsGallery/styled.js";import{MainGalleryContainer as c,TopTag as j,BottomTag as u,TopRightTag as y}from"./styled.js";import"../styled.js";import"../../../SizeCharTable/SizeChartTableV2/styled.js";import"../../../SizeCharTable/SizeChartTableV3/styled.js";import"../../../../molecules/ArrowTip/ArrowTip.styled.js";import"../../../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import"../../../SubscriptionPlanSelector/styled.js";import"../../../TwoCtasAtCart/Greeting.styled.js";import"../../../TwoCtasAtCart/Card.styled.js";import"../../../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../../../molecules/CouponCard/styled.js";import"../../../../molecules/BenefitsList/styled.js";import"../../../../molecules/HurryUp/styled.js";import"../../../../molecules/Spinner/styled.js";import"../../../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../../../molecules/LikeButton/styled.js";import"../../../../molecules/ScarcityTag/ScarcityTag.styled.js";var b={dots:!1,infinite:!1,speed:200,slidesToScroll:1,initialSlide:0},f=function(t){if(!(null==t?void 0:t.current))return 1.1;return(t.current.offsetWidth-15)/312-1e-4},P=function(P){var g,C,h,v=P.contents,S=P.topTag,T=P.topRightTag,V=P.bottomTag,w=P.containerRef,A=s(null),I=s(null),L=l(null!==(g=f(w))&&void 0!==g?g:1),B=L[0],k=L[1],G=null===(C=null==v?void 0:v[0])||void 0===C?void 0:C.key;return a((function(){var t;null===(t=A.current)||void 0===t||t.slickGoTo(0,!0)}),[G]),m((function(){if(null==w?void 0:w.current){var t=p((function(){var t;k(null!==(t=f(w))&&void 0!==t?t:1)}),300);return t(),window.addEventListener("resize",t),function(){return window.removeEventListener("resize",t)}}}),[w,null===(h=null==w?void 0:w.current)||void 0===h?void 0:h.offsetWidth]),r(c,t({ref:I},{children:r(i,t({},b,{slidesToShow:B,ref:A,centerPadding:"80"},{children:v.map((function(i,s){var l,a=null==i?void 0:i.url,m=null!==(l=null==i?void 0:i.isVideo)&&void 0!==l&&l;return r("div",t({"data-testid":"main-gallery-div-content-".concat(s)},{children:m?r(n,{source:a,thumbnail:null==i?void 0:i.thumbnailUrl},void 0):o(e,{children:[r(d,{src:a,alt:i.alt,width:"".concat(312,"px"),loading:"eager"},void 0),r(j,t({"data-testid":"topTag"},{children:S}),void 0),r(u,t({"data-testid":"bottomTag"},{children:V}),void 0),!!T&&r(y,{children:T},void 0)]},void 0)}),i.key)}))}),void 0)}),void 0)};export{P as MainGallery};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"tslib";import{jsxs as i,jsx as t,Fragment as r}from"react/jsx-runtime";import{useState as o,useEffect as s,useCallback as l,useMemo as c,Children as a,isValidElement as n,cloneElement as d}from"react";import{ComponentSize as m}from"../../../types/enums.js";import"../../../utils/constants/offerAtCart.js";import{decimalFormat as p}from"../../../utils/decimalParser/decimalParser.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import{Text as u}from"../../text/Text.js";import{Icon as b}from"../../icons/index.js";import{RadioInput as j}from"../../radio/input/radio.js";import{Tooltip as y}from"../../tooltip/Tooltip.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"../../../core/theme/Theme.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/ProductItemTK.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/IconButton.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../iconsWithTitle/index.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"@emotion/react";import"../../textWithImage/index.js";import"../../timer/styled.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import"../OfferAtCart/styled.js";import"../OfferAtCartV2/styled.js";import"../OfferAtCartV3/styled.js";import"../OfferAtCartV4/styled.js";import"../OfferAtPDP/styled.js";import"../OfferAtPDP/types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import{Container as h,SubscriptionContainer as P,DiscountTag as f,SubscriptionHeader as g,FlexContainer as C,TooltipWrapper as T,StyledPrice as v,BenefitsContainer as k,SinglePurchaseContainer as S}from"./styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";import"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../molecules/CouponCard/styled.js";import{AutoshipFrequencyDropdown as V}from"../../molecules/AutoshipFrequencyDropdown/AutoshipFrequencyDropdown.js";import{BenefitsList as A}from"../../molecules/BenefitsList/BenefitsList.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";var G=function(G){var M=G.children,w=G.benefits,I=G.tooltip,B=G.pricing,L=G.frequency,z=G.onChange,x=G.className,O=G.discountTagClassName,D=G.closeIcon,F=G.currencySymbol,N=G.discountLabel,R=G.radios,q=G.termsAndConditions,W=o({oneTime:R.oneTime,subscription:R.subscription}),H=W[0],$=W[1];s((function(){$((function(i){return e(e({},i),{oneTime:e(e({},i.oneTime),{checked:!i.oneTime.disabled&&i.oneTime.checked}),subscription:e(e({},i.subscription),{checked:!i.subscription.disabled&&i.subscription.checked})})}))}),[H.oneTime.disabled,H.subscription.disabled]);var E=o(null==L?void 0:L.values[0]),Q=E[0],J=E[1],K=B.listPrice,U=B.discountedPrice,_=B.subscriptionDiscountPercentage,X=Number((U-U*(_/100)).toFixed(2)),Y=Math.floor(K-X),Z=Y/K*100,ee=5*Math.round(Z/5),ie=l((function(){return H.subscription.checked?Number((U-U*(_/100)).toFixed(2)):U}),[U,H.subscription.checked,_]),te=c((function(){return{subscriptionPeriod:Q,withSubscription:H.subscription.checked,originalPrice:K,discountedPrice:ie()}}),[Q,H.subscription.checked,K,ie]);s((function(){te&&z(te)}),[te,z]);var re=function(i){var t;"subscription"===(t=i)&&H.subscription.disabled||"oneTime"===t&&H.oneTime.disabled||($((function(t){return e(e({},t),{oneTime:e(e({},t.oneTime),{checked:"oneTime"===i}),subscription:e(e({},t.subscription),{checked:"subscription"===i})})})),"oneTime"===i?J(void 0):"subscription"===i&&L&&J(L.values[0]))};return i(h,e({className:x},{children:[i(P,e({highlighted:H.subscription.checked,onClick:function(){return re("subscription")},"data-testid":"subscription-purchase-block",disabled:H.subscription.disabled},{children:[t(f,e({className:O,selected:H.subscription.checked},{children:null!=N?N:"".concat(ee,"% OFF - SAVE ").concat(F).concat(Y.toFixed(2))}),void 0),i(g,e({showBorder:H.subscription.checked},{children:[i(C,e({"data-testid":"subscription-block",onClick:function(){return re("subscription")}},{children:[t(j,{label:R.subscription.label,icon:R.subscription.icon,name:"subscription",id:"subscription",value:"subscription",size:m.Medium,style:{marginRight:"10px"},useV2Style:!0,onChange:function(){$((function(i){return{subscription:e(e({},i.subscription),{checked:!0}),oneTime:e(e({},i.oneTime),{checked:!1})}}))},checked:!H.subscription.disabled&&H.subscription.checked,disabled:H.subscription.disabled},void 0),I&&t(T,{children:t(y,e({position:0,content:I.content,header:I.header,maxWidth:"248px",showCloseIcon:D,closeBtnSize:.7},{children:t(b.Actions.CircleQuestion,{width:1},void 0)}),void 0)},void 0)]}),void 0),t(v,{testId:"subscription",finalPrice:"$".concat(p(Number(X))),disabled:H.subscription.disabled,highlighted:!H.subscription.disabled&&H.subscription.highlighted,size:m.Large,originalPrice:"$".concat(p(Number(K)))},void 0)]}),void 0),H.subscription.checked&&i(r,{children:[t(k,e({disabled:H.subscription.disabled},{children:function(){var i=H.subscription.disabled;if(M){var r=i?{opacity:.5,pointerEvents:"none"}:{};return a.map(M,(function(i){return n(i)?d(i,{style:e(e({},i.props.style),r)}):i}))}return w?t(A,{benefits:w,disabled:i},void 0):null}()}),void 0),q&&t(u,e({variant:"link",underline:!0,href:q.url,size:"regular",target:"_blank"},{children:q.text}),void 0),(null==L?void 0:L.showFrequencyText)&&t(V,{frequency:L,onChange:function(e){J(H.subscription.checked?e.value:void 0)}},void 0)]},void 0)]}),void 0),i(S,e({"data-testid":"single-purchase-block",highlighted:H.oneTime.checked,disabled:H.oneTime.disabled,onClick:function(){return re("oneTime")}},{children:[t(j,{label:R.oneTime.label,icon:R.oneTime.icon,name:"oneTime",id:"oneTime",value:"oneTime",size:m.Medium,onChange:function(){$((function(i){return{subscription:e(e({},i.subscription),{checked:!1}),oneTime:e(e({},i.oneTime),{checked:!0})}}))},useV2Style:!0,checked:!H.oneTime.disabled&&H.oneTime.checked,disabled:H.oneTime.disabled},void 0),t(v,{testId:"single-purchase",finalPrice:"$".concat(p(Number(U))),disabled:H.oneTime.disabled,highlighted:!H.oneTime.disabled&&H.oneTime.highlighted,size:m.Large,originalPrice:"$".concat(p(Number(K)))},void 0)]}),void 0)]}),void 0)};export{G as SubscriptionPlanSelector};
|
|
1
|
+
import{__assign as e}from"tslib";import{jsxs as i,jsx as t,Fragment as r}from"react/jsx-runtime";import{useState as o,useEffect as s,useCallback as l,useMemo as c,Children as a,isValidElement as n,cloneElement as d}from"react";import{ComponentSize as m}from"../../../types/enums.js";import"../../../utils/constants/offerAtCart.js";import{decimalFormat as p}from"../../../utils/decimalParser/decimalParser.js";import"../../../utils/media.js";import"../../../utils/mock-content/CancellationFlowAccordion.js";import{Text as u}from"../../text/Text.js";import{Icon as b}from"../../icons/index.js";import{RadioInput as j}from"../../radio/input/radio.js";import{Tooltip as y}from"../../tooltip/Tooltip.js";import"../../PackSelectorV2/PackSelectoV2.js";import"../../absorbency-level/AbsorbencyLevel.js";import"../../accordion-options/AccordionOptions.js";import"../../accordion/Accordion.js";import"../../../core/theme/Theme.js";import"../../dropdown/variants/simple/SimpleDropdown.js";import"../../autoship/styled.js";import"../../autoshipV2/styled.js";import"../../before-after/BeforeAfter.js";import"../../pricing/clubOffer/ClubOfferTag.js";import"../../pricing/discount/styled.js";import"../../pricing/styles.js";import"../../pricing/priceLabelV2/PriceLabelV2.js";import"../../pricing/priceLabelV3/PriceLabelV3.js";import"../../pricing/priceLabelV5/PriceLabelV5.styled.js";import"../../shared/card/Card.js";import"../../bundle/minimalistic/styled.js";import"../../bundle/motivator/styled.js";import"../../bundle/simple/Simple.js";import"../../buynowpaylater/BuyNowPayLater.js";import"../../offer-banner/OfferBanner.js";import"../../cartProductItem/CloseIcon/CloseButton.js";import"../../cartProductItem/Description/Description.js";import"../../cartProductItem/Promo/Promo.js";import"../../cartProductItem/Title/Title.js";import"../../cartProductItem/TrashIcon/styled.js";import"../../checkbox/Checkbox.js";import"@emotion/react/jsx-runtime";import"../../SkeletonBox/SkeletonBox.js";import"../../atoms/PriceLabel/PriceLabel.js";import"../../atoms/PriceLabelV2/PriceLabelV2.js";import"../../atoms/ClubPriceMemberLabel/ClubPriceMemberLabel.styled.js";import"../../atoms/HorizontalDivider/HorizontalDivider.js";import"../../atoms/Icon/Icon.js";import"../../atoms/Image/styled.js";import"../../atoms/Toggle/toggle.styled.js";import"../../club-price-label/ClubPriceLabel.js";import"../../strength-bars/StrengthBars.js";import"../../pricing/priceLabelV4/PriceLabelV4.js";import"../../rating/starList/StarList.js";import"../../rating/styles.js";import"../../collection/product/mobile/styled.js";import"../../collection/product/truekind/styled.js";import"../../collection/grid/WithProductGrid.js";import"../../color/ColorRadioGroup.js";import"../../color/selector/PatternSelector.js";import"../../color/styles/ColorPickerwithTootip.styled.js";import"../../cross-sell/Checkbox/CrossSellCheckbox.js";import"../../cta/styled.js";import"../../delivery-details/DeliveryDetails.js";import"../../delivery-details/Note/Note.js";import"../../drawer/Drawer.js";import"../../dropdown-list-icons/Styled.js";import"../../dropdown/size-dropdown/Styled.js";import"../../dropdown/variants/dialog/DropdownDialog.js";import"../../dropdown/base/BaseDropdown.js";import"../../filtering/Accordion.js";import"../../filtering/FiltersStyled.js";import"../../filtering/Tags/Tags.js";import"../../fit-guarantee/FitGuarantee.js";import"../../fit/FitPredictor.js";import"../../slider/ArrowButton.js";import"../../slider/StyledSlider.js";import"../../gallery/components/ImageSmallPreview/styled.js";import"../../gallery/components/ImagePreviewList/styled.js";import"../../molecules/Video/components/styled.js";import"../../molecules/Video/styled.js";import"../../gallery/components/ImageProductSlide/styled.js";import"../../gallery/styled.js";import"../../icon-button/IconButton.js";import"../../icon-button/amazonAndPaypal/AmazonPaypalButtons.js";import"../../iconsWithTitle/index.js";import"../../image-card/ImageCard.js";import"../../input/label/Label.js";import"../../input/base/Error.js";import"../../input/base/Styled.js";import"../../input/custom/Custom.js";import"../../input/basePlusButton/BasePlusButton.js";import"../../input/basePlusIcon/BasePlusIcon.js";import"../../modal/Modal.js";import"../../motivator-progress-bar/MotivatorProgressBar.js";import"../../order-bar/OrderBar.js";import"../../packs/selector/PackSelector.js";import"../../pagination/styles.js";import"../../payment-methods/PaymentMethod.js";import"../../product/order/item/SimpleOrderItem.js";import"../../progress-bar/ProgressBar.js";import"../../quantityPicker/QuantityPicker.js";import"../../radio/RadioPrimary/radioPrimary.js";import"../../radio/clubRadioInput/clubRadio.js";import"../../review-detail/ReviewDetail.js";import"../../review/Review.js";import"../../reviews-header/ReviewsHeader.js";import"../../scroll-to-top/ScrollToTop.js";import"../../search-bar/components/ClearButton/styled.js";import"../../search-bar/components/Footer/styled.js";import"../../search-bar/components/ProductItem/styled.js";import"../../search-bar/components/ResultsPanel/styled.js";import"../../search-bar/components/SearchControl/styled.js";import"../../search-bar/styled.js";import"../../search-navigation/styled.js";import"react-dom";import"../../short-banner/ShortBanner.js";import"../../size-chart/styled.js";import"../../size-table/SizeTable.js";import"../../size/guide/SizeFitGuide.js";import"../../size/selector/styled.js";import"../../tabs/Tab.js";import"../../tabs/Tabs.js";import"../../tag/Tag.js";import"@emotion/react";import"../../textWithImage/index.js";import"../../timer/styled.js";import"../../toast/Toast.js";import"../../totals/total/styled.js";import"../../totals/subtotal/Subtotal.js";import"../../tracking-progress-v2/TrackingProgressV2.js";import"../../tracking-progress/TrackingProgress.js";import"../AutoshipOfferCard/AutoshipOfferCardItem.styled.js";import"../AutoshipOfferCardCta/AutoshipOfferCardItem.styled.js";import"../AutoshipPdpCard/AutoshipPdpCard.styled.js";import"../BasicAccordion/BasicAccordion.js";import"../CartItemCard/CartItem.js";import"../ClubOfferSelector/styled.js";import"../ClubOfferSelector2/styled.js";import"../JoinClubCard/joinClubCard.js";import"../OfferAtCart/styled.js";import"../OfferAtCartV2/styled.js";import"../OfferAtCartV3/styled.js";import"../OfferAtCartV4/styled.js";import"../OfferAtPDP/styled.js";import"../OfferAtPDP/types.js";import"../ProductCard/ProductCardV1/ProductCard.js";import"../ProductCard/ProductCardV2/styled.js";import"../ProductCard/ProductCardV3/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV1/ProductGalleryMobile.js";import"../ProductGalleryMobile/ProductGalleryMobileV2/ProductGalleryMobileV2.js";import"../ProductGalleryMobile/ProductGalleryMobileV3/ProductGalleryMobileV3.js";import"@ant-design/react-slick";import"../ProductGalleryMobile/ProductGalleryMobileV4/ContentGallery/styled.js";import"react-inner-image-zoom";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/MainContent/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/Slider/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV4/GalleryDetailed/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV5/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/ColorVariantsGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/MainGallery/styled.js";import"../ProductGalleryMobile/ProductGalleryMobileV6/styled.js";import"../SizeCharTable/SizeChartTableV2/styled.js";import"../SizeCharTable/SizeChartTableV3/styled.js";import"../../molecules/ArrowTip/ArrowTip.styled.js";import"../SizeCharTable/SizeChartTableV4/SizeChartTableV4.styled.js";import{Container as h,SubscriptionContainer as P,DiscountTag as f,SubscriptionHeader as g,FlexContainer as C,TooltipWrapper as T,StyledPrice as v,BenefitsContainer as k,SinglePurchaseContainer as S}from"./styled.js";import"../TwoCtasAtCart/Greeting.styled.js";import"../TwoCtasAtCart/Card.styled.js";import"../../molecules/OfferAtCartBenefits/OfferAtCartBenefits.styled.js";import"../../molecules/OfferAtCartImage/OfferAtCartImage.styled.js";import"../../molecules/CouponCard/styled.js";import{AutoshipFrequencyDropdown as V}from"../../molecules/AutoshipFrequencyDropdown/AutoshipFrequencyDropdown.js";import{BenefitsList as A}from"../../molecules/BenefitsList/BenefitsList.js";import"../../molecules/HurryUp/styled.js";import"../../molecules/Spinner/styled.js";import"../../molecules/IconsWithTitleList/IconsWithTitleList.styled.js";import"../../molecules/LikeButton/styled.js";import"../../molecules/ScarcityTag/ScarcityTag.styled.js";var G=function(G){var M=G.children,w=G.benefits,I=G.tooltip,B=G.pricing,L=G.frequency,z=G.onChange,x=G.className,O=G.discountTagClassName,D=G.closeIcon,F=G.currencySymbol,N=G.discountLabel,R=G.radios,q=G.termsAndConditions,W=o({oneTime:R.oneTime,subscription:R.subscription}),H=W[0],$=W[1];s((function(){$((function(i){return e(e({},i),{oneTime:e(e({},i.oneTime),{checked:!i.oneTime.disabled&&i.oneTime.checked}),subscription:e(e({},i.subscription),{checked:!i.subscription.disabled&&i.subscription.checked})})}))}),[H.oneTime.disabled,H.subscription.disabled]);var E=o(null==L?void 0:L.values[0]),Q=E[0],J=E[1],U=B.listPrice,_=B.discountedPrice,K=B.subscriptionDiscountPercentage,X=Number((_-_*(K/100)).toFixed(2)),Y=Math.floor(U-X),Z=Y/U*100,ee=5*Math.round(Z/5),ie=l((function(){return H.subscription.checked?Number((_-_*(K/100)).toFixed(2)):_}),[_,H.subscription.checked,K]),te=c((function(){return{subscriptionPeriod:Q,withSubscription:H.subscription.checked,originalPrice:U,discountedPrice:ie()}}),[Q,H.subscription.checked,U,ie]);s((function(){te&&z(te)}),[te,z]);var re=function(i){var t;"subscription"===(t=i)&&H.subscription.disabled||"oneTime"===t&&H.oneTime.disabled||($((function(t){return e(e({},t),{oneTime:e(e({},t.oneTime),{checked:"oneTime"===i}),subscription:e(e({},t.subscription),{checked:"subscription"===i})})})),"oneTime"===i?J(void 0):"subscription"===i&&L&&J(L.values[0]))};return i(h,e({className:x},{children:[i(P,e({highlighted:H.subscription.checked,onClick:function(){return re("subscription")},"data-testid":"subscription-purchase-block",disabled:H.subscription.disabled},{children:[t(f,e({className:O,selected:H.subscription.checked},{children:null!=N?N:"".concat(ee,"% OFF - SAVE ").concat(F).concat(Y.toFixed(2))}),void 0),i(g,e({showBorder:H.subscription.checked},{children:[i(C,e({"data-testid":"subscription-block",onClick:function(){return re("subscription")}},{children:[t(j,{label:R.subscription.label,icon:R.subscription.icon,name:"subscription",id:"subscription",value:"subscription",size:m.Medium,style:{marginRight:"10px"},useV2Style:!0,onChange:function(){$((function(i){return{subscription:e(e({},i.subscription),{checked:!0}),oneTime:e(e({},i.oneTime),{checked:!1})}}))},checked:!H.subscription.disabled&&H.subscription.checked,disabled:H.subscription.disabled},void 0),I&&t(T,{children:t(y,e({position:0,content:I.content,header:I.header,maxWidth:"248px",showCloseIcon:D,closeBtnSize:.7},{children:t(b.Actions.CircleQuestion,{width:1},void 0)}),void 0)},void 0)]}),void 0),t(v,{testId:"subscription",finalPrice:"$".concat(p(Number(X))),disabled:H.subscription.disabled,highlighted:!H.subscription.disabled&&H.subscription.highlighted,size:m.Large,originalPrice:"$".concat(p(Number(U)))},void 0)]}),void 0),H.subscription.checked&&i(r,{children:[t(k,e({disabled:H.subscription.disabled},{children:function(){var i=H.subscription.disabled;if(M){var r=i?{opacity:.5,pointerEvents:"none"}:{};return a.map(M,(function(i){return n(i)?d(i,{style:e(e({},i.props.style),r)}):i}))}return w?t(A,{benefits:w,disabled:i},void 0):null}()}),void 0),q&&t(u,e({variant:"link",underline:!0,href:q.url,size:"regular",target:"_blank"},{children:q.text}),void 0),(null==L?void 0:L.showFrequencyText)&&t(V,{frequency:L,onChange:function(e){J(H.subscription.checked?e.value:void 0)}},void 0)]},void 0)]}),void 0),i(S,e({"data-testid":"single-purchase-block",highlighted:H.oneTime.checked,disabled:H.oneTime.disabled,onClick:function(){return re("oneTime")}},{children:[t(j,{label:R.oneTime.label,icon:R.oneTime.icon,name:"oneTime",id:"oneTime",value:"oneTime",size:m.Medium,onChange:function(){$((function(i){return{subscription:e(e({},i.subscription),{checked:!1}),oneTime:e(e({},i.oneTime),{checked:!0})}}))},useV2Style:!0,checked:!H.oneTime.disabled&&H.oneTime.checked,disabled:H.oneTime.disabled},void 0),t(v,{testId:"single-purchase",finalPrice:"$".concat(p(Number(_))),disabled:H.oneTime.disabled,highlighted:!H.oneTime.disabled&&H.oneTime.highlighted,size:m.Large,originalPrice:"$".concat(p(Number(U)))},void 0)]}),void 0)]}),void 0)};export{G as SubscriptionPlanSelector};
|
|
2
2
|
//# sourceMappingURL=SubscriptionPlanSelector.js.map
|