@trafilea/afrodita-components 4.0.1-beta.1 → 4.0.2-beta.10
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/index.d.ts +133 -75
- package/build/index.esm.js +487 -389
- package/build/index.esm.js.map +1 -1
- package/build/index.js +490 -390
- package/build/index.js.map +1 -1
- package/build/{dts/core/theme/shapermint.theme.d.ts → theme/shapermint.d.ts} +5 -3
- package/build/theme/shapermint.theme.js +147 -59
- package/build/{dts/core/theme/Theme.d.ts → theme/truekind.d.ts} +26 -25
- package/build/theme/truekind.theme.js +171 -86
- package/package.json +14 -10
- package/build/dts/components/Icon-wrapper/IconWrapper.d.ts +0 -12
- package/build/dts/components/Icon-wrapper/IconWrapper.test.d.ts +0 -1
- package/build/dts/components/accordion/Accordion.d.ts +0 -13
- package/build/dts/components/accordion/Accordion.stories.d.ts +0 -9
- package/build/dts/components/accordion/Accordion.test.d.ts +0 -1
- package/build/dts/components/accordion/styles.d.ts +0 -16
- package/build/dts/components/bundle/index.d.ts +0 -5
- package/build/dts/components/bundle/minimalistic/Minimalistic.d.ts +0 -15
- package/build/dts/components/bundle/minimalistic/Minimalistic.stories.d.ts +0 -9
- package/build/dts/components/bundle/minimalistic/Minimalistic.test.d.ts +0 -1
- package/build/dts/components/bundle/simple/Simple.d.ts +0 -10
- package/build/dts/components/bundle/simple/Simple.stories.d.ts +0 -9
- package/build/dts/components/bundle/simple/Simple.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/CloseIcon/Close.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/CloseIcon/CloseButton.d.ts +0 -5
- package/build/dts/components/cartProductItem/CloseIcon/CloseButton.stories.d.ts +0 -9
- package/build/dts/components/cartProductItem/Description/Description.d.ts +0 -5
- package/build/dts/components/cartProductItem/Description/Description.stories.d.ts +0 -9
- package/build/dts/components/cartProductItem/Description/Description.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/Promo/Promo.d.ts +0 -5
- package/build/dts/components/cartProductItem/Promo/Promo.stories.d.ts +0 -9
- package/build/dts/components/cartProductItem/Promo/Promo.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/ThinPrice/ThinPrice.d.ts +0 -5
- package/build/dts/components/cartProductItem/ThinPrice/ThinPrice.stories.d.ts +0 -9
- package/build/dts/components/cartProductItem/ThinPrice/ThinPrice.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/Title/Title.d.ts +0 -5
- package/build/dts/components/cartProductItem/Title/Title.stories.d.ts +0 -9
- package/build/dts/components/cartProductItem/Title/Title.test.d.ts +0 -1
- package/build/dts/components/cartProductItem/index.d.ts +0 -8
- package/build/dts/components/checkbox/Checkbox.d.ts +0 -21
- package/build/dts/components/checkbox/Checkbox.stories.d.ts +0 -24
- package/build/dts/components/checkbox/Checkbox.test.d.ts +0 -1
- package/build/dts/components/checkbox/styles.d.ts +0 -9
- package/build/dts/components/collection/grid/WithProductGrid.d.ts +0 -11
- package/build/dts/components/collection/grid/WithProductGrid.stories.d.ts +0 -9
- package/build/dts/components/collection/grid/WithProductGrid.test.d.ts +0 -1
- package/build/dts/components/collection/index.d.ts +0 -5
- package/build/dts/components/collection/product/mobile/ProductItemMobile.d.ts +0 -7
- package/build/dts/components/collection/product/mobile/ProductItemMobile.stories.d.ts +0 -24
- package/build/dts/components/collection/product/mobile/ProductItemMobile.test.d.ts +0 -1
- package/build/dts/components/collection/product/types.d.ts +0 -14
- package/build/dts/components/color/ColorRadioGroup.d.ts +0 -24
- package/build/dts/components/color/MultiColorPicker.d.ts +0 -10
- package/build/dts/components/color/MultiColorPicker.stories.d.ts +0 -9
- package/build/dts/components/color/MultiColorPicker.test.d.ts +0 -1
- package/build/dts/components/color/SingleColorPicker.d.ts +0 -10
- package/build/dts/components/color/SingleColorPicker.stories.d.ts +0 -9
- package/build/dts/components/color/SingleColorPicker.test.d.ts +0 -1
- package/build/dts/components/color/selector/ColorSelector.d.ts +0 -15
- package/build/dts/components/color/selector/ColorSelector.stories.d.ts +0 -14
- package/build/dts/components/color/selector/ColorSelector.test.d.ts +0 -1
- package/build/dts/components/color/selector/OneColorSelector.d.ts +0 -8
- package/build/dts/components/color/selector/OutOfStock.d.ts +0 -6
- package/build/dts/components/color/selector/PatternSelector.d.ts +0 -8
- package/build/dts/components/color/selector/PatternSelector.test.d.ts +0 -1
- package/build/dts/components/color/selector/ThreeColorSelector.d.ts +0 -10
- package/build/dts/components/color/selector/TwoColorSelector.d.ts +0 -9
- package/build/dts/components/cross-sell/Checkbox/CrossSellCheckbox.d.ts +0 -13
- package/build/dts/components/cross-sell/Checkbox/CrossSellCheckbox.stories.d.ts +0 -9
- package/build/dts/components/cross-sell/Checkbox/CrossSellCheckbox.test.d.ts +0 -1
- package/build/dts/components/cross-sell/index.d.ts +0 -1
- package/build/dts/components/cta/BaseCTA.d.ts +0 -13
- package/build/dts/components/cta/BaseCTA.test.d.ts +0 -1
- package/build/dts/components/cta/index.d.ts +0 -3
- package/build/dts/components/cta/primary/ButtonPrimary.d.ts +0 -3
- package/build/dts/components/cta/primary/ButtonPrimary.stories.d.ts +0 -37
- package/build/dts/components/cta/primary/ButtonPrimary.test.d.ts +0 -1
- package/build/dts/components/cta/secondary/ButtonSecondary.d.ts +0 -3
- package/build/dts/components/cta/secondary/ButtonSecondary.stories.d.ts +0 -37
- package/build/dts/components/cta/secondary/ButtonSecondary.test.d.ts +0 -1
- package/build/dts/components/cta/secondary/ButtonSecondaryOutline.d.ts +0 -3
- package/build/dts/components/cta/secondary/ButtonSecondaryOutline.stories.d.ts +0 -37
- package/build/dts/components/cta/secondary/ButtonSecondaryOutline.test.d.ts +0 -1
- package/build/dts/components/delivery-details/DeliveryDetails.d.ts +0 -26
- package/build/dts/components/delivery-details/DeliveryDetails.stories.d.ts +0 -9
- package/build/dts/components/delivery-details/DeliveryDetails.test.d.ts +0 -1
- package/build/dts/components/delivery-details/Note/Note.d.ts +0 -9
- package/build/dts/components/delivery-details/Note/Note.stories.d.ts +0 -9
- package/build/dts/components/delivery-details/Note/Note.test.d.ts +0 -1
- package/build/dts/components/drawer/Drawer.d.ts +0 -13
- package/build/dts/components/drawer/Drawer.stories.d.ts +0 -14
- package/build/dts/components/drawer/Drawer.test.d.ts +0 -1
- package/build/dts/components/dropdown/base/BaseDropdown.d.ts +0 -17
- package/build/dts/components/dropdown/base/BaseDropdownButton.d.ts +0 -12
- package/build/dts/components/dropdown/base/BaseDropdownOption.d.ts +0 -11
- package/build/dts/components/dropdown/base/BaseDropdownOptions.d.ts +0 -6
- package/build/dts/components/dropdown/variants/filtering/Filtering.test.d.ts +0 -1
- package/build/dts/components/dropdown/variants/filtering/FilteringDropdown.d.ts +0 -13
- package/build/dts/components/dropdown/variants/filtering/FilteringDropdown.stories.d.ts +0 -12
- package/build/dts/components/dropdown/variants/simple/SimpleDropdown.d.ts +0 -20
- package/build/dts/components/dropdown/variants/simple/SimpleDropdown.stories.d.ts +0 -13
- package/build/dts/components/dropdown/variants/simple/SimpleDropdown.test.d.ts +0 -1
- package/build/dts/components/dropdown-list-icons/DropdownListIcons.d.ts +0 -6
- package/build/dts/components/dropdown-list-icons/DropdownListIcons.stories.d.ts +0 -9
- package/build/dts/components/dropdown-list-icons/DropdownListIcons.test.d.ts +0 -1
- package/build/dts/components/dropdown-list-icons/Styled.d.ts +0 -34
- package/build/dts/components/filtering/Accordion.d.ts +0 -8
- package/build/dts/components/filtering/Filters.d.ts +0 -15
- package/build/dts/components/filtering/Filters.stories.d.ts +0 -9
- package/build/dts/components/filtering/Filters.test.d.ts +0 -1
- package/build/dts/components/filtering/FiltersStyled.d.ts +0 -43
- package/build/dts/components/filtering/Tags/Tags.d.ts +0 -24
- package/build/dts/components/filtering/Tags/Tags.stories.d.ts +0 -9
- package/build/dts/components/filtering/Tags/Tags.test.d.ts +0 -1
- package/build/dts/components/fit/FitPredictor.d.ts +0 -5
- package/build/dts/components/fit/FitPredictor.stories.d.ts +0 -7
- package/build/dts/components/fit/FitPredictor.test.d.ts +0 -1
- package/build/dts/components/gallery/ImagePreviewList.d.ts +0 -9
- package/build/dts/components/gallery/ImagePreviewList.test.d.ts +0 -1
- package/build/dts/components/gallery/ImageProductWithTags.d.ts +0 -10
- package/build/dts/components/gallery/ImageProductWithTags.test.d.ts +0 -1
- package/build/dts/components/gallery/ImageSmallPreview.d.ts +0 -9
- package/build/dts/components/gallery/ImageSmallPreview.test.d.ts +0 -1
- package/build/dts/components/gallery/ProductGallery.d.ts +0 -12
- package/build/dts/components/gallery/ProductGallery.stories.d.ts +0 -9
- package/build/dts/components/gallery/ProductGallery.test.d.ts +0 -1
- package/build/dts/components/icon-button/IconButton.d.ts +0 -16
- package/build/dts/components/icon-button/IconButton.stories.d.ts +0 -23
- package/build/dts/components/icon-button/IconButton.test.d.ts +0 -1
- package/build/dts/components/icon-button/amazonAndPaypal/AmazonPaypalButtons.d.ts +0 -6
- package/build/dts/components/icon-button/amazonAndPaypal/AmazonPaypalButtons.stories.d.ts +0 -7
- package/build/dts/components/icon-button/amazonAndPaypal/AmazonPaypalButtons.test.d.ts +0 -1
- package/build/dts/components/icons/Actions/Check.d.ts +0 -3
- package/build/dts/components/icons/Actions/ClearLight.d.ts +0 -3
- package/build/dts/components/icons/Actions/Close.d.ts +0 -3
- package/build/dts/components/icons/Actions/LightCheck.d.ts +0 -6
- package/build/dts/components/icons/Actions/LightExclamation.d.ts +0 -3
- package/build/dts/components/icons/Actions/Question.d.ts +0 -3
- package/build/dts/components/icons/Actions/Trash.d.ts +0 -3
- package/build/dts/components/icons/Actions/index.d.ts +0 -7
- package/build/dts/components/icons/Arrows/ChevronDown.d.ts +0 -3
- package/build/dts/components/icons/Arrows/ChevronLeft.d.ts +0 -3
- package/build/dts/components/icons/Arrows/ChevronRight.d.ts +0 -3
- package/build/dts/components/icons/Arrows/ChevronRightVariant.d.ts +0 -3
- package/build/dts/components/icons/Arrows/ChevronUp.d.ts +0 -3
- package/build/dts/components/icons/Arrows/ChevronUpSolid.d.ts +0 -3
- package/build/dts/components/icons/Arrows/CircleUp.d.ts +0 -3
- package/build/dts/components/icons/Arrows/index.d.ts +0 -7
- package/build/dts/components/icons/Custom/SixtyDaysGuarantee.d.ts +0 -3
- package/build/dts/components/icons/Custom/index.d.ts +0 -1
- package/build/dts/components/icons/Download/AppleStore.d.ts +0 -3
- package/build/dts/components/icons/Download/GooglePlay.d.ts +0 -3
- package/build/dts/components/icons/Download/index.d.ts +0 -2
- package/build/dts/components/icons/Messaging/Comment.d.ts +0 -3
- package/build/dts/components/icons/Messaging/Messenger.d.ts +0 -3
- package/build/dts/components/icons/Messaging/QuestionCircle.d.ts +0 -3
- package/build/dts/components/icons/Messaging/index.d.ts +0 -3
- package/build/dts/components/icons/Navigation/MapMarker.d.ts +0 -3
- package/build/dts/components/icons/Navigation/Search.d.ts +0 -3
- package/build/dts/components/icons/Navigation/ShoppingBag.d.ts +0 -3
- package/build/dts/components/icons/Navigation/User.d.ts +0 -3
- package/build/dts/components/icons/Navigation/index.d.ts +0 -4
- package/build/dts/components/icons/Other/FitPredictor.d.ts +0 -3
- package/build/dts/components/icons/Other/Loading.d.ts +0 -6
- package/build/dts/components/icons/Other/Shapermint.d.ts +0 -3
- package/build/dts/components/icons/Other/index.d.ts +0 -4
- package/build/dts/components/icons/Other/mcAfee.d.ts +0 -3
- package/build/dts/components/icons/PDP/Clock.d.ts +0 -3
- package/build/dts/components/icons/PDP/FlagUSA.d.ts +0 -3
- package/build/dts/components/icons/PDP/Minus.d.ts +0 -3
- package/build/dts/components/icons/PDP/Plus.d.ts +0 -3
- package/build/dts/components/icons/PDP/Rule.d.ts +0 -3
- package/build/dts/components/icons/PDP/Shipping.d.ts +0 -3
- package/build/dts/components/icons/PDP/Star.d.ts +0 -3
- package/build/dts/components/icons/PDP/StarEmpty.d.ts +0 -3
- package/build/dts/components/icons/PDP/StarHalf.d.ts +0 -3
- package/build/dts/components/icons/PDP/Stopwatch.d.ts +0 -3
- package/build/dts/components/icons/PDP/index.d.ts +0 -10
- package/build/dts/components/icons/Payment/Amazon.d.ts +0 -3
- package/build/dts/components/icons/Payment/Amex.d.ts +0 -3
- package/build/dts/components/icons/Payment/JCB.d.ts +0 -3
- package/build/dts/components/icons/Payment/Klarna.d.ts +0 -3
- package/build/dts/components/icons/Payment/MasterCard.d.ts +0 -3
- package/build/dts/components/icons/Payment/Paypal.d.ts +0 -3
- package/build/dts/components/icons/Payment/Visa.d.ts +0 -3
- package/build/dts/components/icons/Payment/index.d.ts +0 -7
- package/build/dts/components/icons/SlideDots/SlideDot.d.ts +0 -3
- package/build/dts/components/icons/SlideDots/index.d.ts +0 -1
- package/build/dts/components/icons/SocialMedia/Facebook.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/FacebookSolid.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/Instagram.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/InstagramSolid.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/Pinterest.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/Twitter.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/Youtube.d.ts +0 -3
- package/build/dts/components/icons/SocialMedia/index.d.ts +0 -7
- package/build/dts/components/icons/index.d.ts +0 -27
- package/build/dts/components/index.d.ts +0 -48
- package/build/dts/components/input/base/BaseInput.d.ts +0 -14
- package/build/dts/components/input/base/BaseInput.stories.d.ts +0 -9
- package/build/dts/components/input/base/BaseInput.test.d.ts +0 -1
- package/build/dts/components/input/base/Error.d.ts +0 -6
- package/build/dts/components/input/base/Styled.d.ts +0 -31
- package/build/dts/components/input/basePlusButton/BasePlusButton.d.ts +0 -13
- package/build/dts/components/input/basePlusButton/BasePlusButton.stories.d.ts +0 -9
- package/build/dts/components/input/basePlusButton/BasePlusButton.test.d.ts +0 -1
- package/build/dts/components/input/basePlusButton/Success.d.ts +0 -6
- package/build/dts/components/input/basePlusIcon/BasePlusIcon.d.ts +0 -7
- package/build/dts/components/input/basePlusIcon/BasePlusIcon.stories.d.ts +0 -9
- package/build/dts/components/input/basePlusIcon/BasePlusIcon.test.d.ts +0 -1
- package/build/dts/components/input/custom/Custom.d.ts +0 -8
- package/build/dts/components/input/custom/Custom.stories.d.ts +0 -9
- package/build/dts/components/input/custom/Custom.test.d.ts +0 -1
- package/build/dts/components/input/index.d.ts +0 -7
- package/build/dts/components/input/label/Label.d.ts +0 -15
- package/build/dts/components/input/label/Label.stories.d.ts +0 -9
- package/build/dts/components/input/label/Label.test.d.ts +0 -1
- package/build/dts/components/mobile/gallery/ImageProductWithTagsMobile.d.ts +0 -10
- package/build/dts/components/mobile/gallery/ProductGalleryMobile.d.ts +0 -12
- package/build/dts/components/mobile/gallery/ProductGalleryMobile.stories.d.ts +0 -8
- package/build/dts/components/mobile/gallery/ProductGalleryMobile.test.d.ts +0 -1
- package/build/dts/components/mobile/gallery/slide_navigation/ArrowButton.d.ts +0 -8
- package/build/dts/components/mobile/gallery/slide_navigation/SlideDots.d.ts +0 -8
- package/build/dts/components/mobile/gallery/slide_navigation/SlideDots.test.d.ts +0 -1
- package/build/dts/components/mobile/gallery/slide_navigation/SlideNavigation.d.ts +0 -9
- package/build/dts/components/mobile/gallery/slide_navigation/SlideNavigation.test.d.ts +0 -1
- package/build/dts/components/offer-banner/OfferBanner.d.ts +0 -15
- package/build/dts/components/offer-banner/OfferBanner.stories.d.ts +0 -9
- package/build/dts/components/offer-banner/OfferBanner.test.d.ts +0 -1
- package/build/dts/components/order-bar/OrderBar.d.ts +0 -17
- package/build/dts/components/order-bar/OrderBar.stories.d.ts +0 -9
- package/build/dts/components/order-bar/OrderBar.test.d.ts +0 -1
- package/build/dts/components/pagination/Pagination.d.ts +0 -11
- package/build/dts/components/pagination/Pagination.stories.d.ts +0 -9
- package/build/dts/components/pagination/Pagination.test.d.ts +0 -1
- package/build/dts/components/pagination/styles.d.ts +0 -29
- package/build/dts/components/payment-methods/PaymentMethod.d.ts +0 -20
- package/build/dts/components/payment-methods/PaymentMethod.stories.d.ts +0 -13
- package/build/dts/components/payment-methods/PaymentMethod.test.d.ts +0 -1
- package/build/dts/components/pricing/discount/DiscountTag.d.ts +0 -21
- package/build/dts/components/pricing/discount/DiscountTag.stories.d.ts +0 -23
- package/build/dts/components/pricing/discount/DiscountTag.test.d.ts +0 -1
- package/build/dts/components/pricing/index.d.ts +0 -2
- package/build/dts/components/pricing/price/PriceLabel.d.ts +0 -11
- package/build/dts/components/pricing/price/PriceLabel.stories.d.ts +0 -23
- package/build/dts/components/pricing/price/PriceLabel.test.d.ts +0 -1
- package/build/dts/components/product/order/item/SimpleOrderItem.d.ts +0 -20
- package/build/dts/components/product/order/item/SimpleOrderItem.stories.d.ts +0 -11
- package/build/dts/components/product/order/item/SimpleOrderItem.test.d.ts +0 -1
- package/build/dts/components/progress-bar/ProgressBar.d.ts +0 -8
- package/build/dts/components/progress-bar/ProgressBar.stories.d.ts +0 -8
- package/build/dts/components/progress-bar/ProgressBar.test.d.ts +0 -1
- package/build/dts/components/quantityPicker/QuantityPicker.d.ts +0 -6
- package/build/dts/components/quantityPicker/QuantityPicker.stories.d.ts +0 -9
- package/build/dts/components/quantityPicker/QuantityPicker.test.d.ts +0 -1
- package/build/dts/components/radio/container/group.d.ts +0 -12
- package/build/dts/components/radio/container/group.stories.d.ts +0 -23
- package/build/dts/components/radio/container/group.test.d.ts +0 -1
- package/build/dts/components/radio/index.d.ts +0 -1
- package/build/dts/components/radio/input/radio.d.ts +0 -13
- package/build/dts/components/radio/input/radio.stories.d.ts +0 -23
- package/build/dts/components/radio/input/radio.test.d.ts +0 -1
- package/build/dts/components/radio/input/styles.d.ts +0 -13
- package/build/dts/components/rating/Rating.d.ts +0 -9
- package/build/dts/components/rating/Rating.stories.d.ts +0 -24
- package/build/dts/components/rating/Rating.test.d.ts +0 -1
- package/build/dts/components/rating/starList/StarList.d.ts +0 -9
- package/build/dts/components/rating/starList/StarList.stories.d.ts +0 -24
- package/build/dts/components/rating/starList/StarList.test.d.ts +0 -1
- package/build/dts/components/rating/starList/styles.d.ts +0 -12
- package/build/dts/components/rating/styles.d.ts +0 -13
- package/build/dts/components/review/Review.d.ts +0 -19
- package/build/dts/components/review/Review.stories.d.ts +0 -9
- package/build/dts/components/review/Review.test.d.ts +0 -1
- package/build/dts/components/scroll-to-top/ScrollToTop.d.ts +0 -18
- package/build/dts/components/scroll-to-top/ScrollToTop.stories.d.ts +0 -9
- package/build/dts/components/scroll-to-top/ScrollToTop.test.d.ts +0 -1
- package/build/dts/components/search-bar/ClearButton.d.ts +0 -6
- package/build/dts/components/search-bar/ClearButton.test.d.ts +0 -1
- package/build/dts/components/search-bar/Footer.d.ts +0 -7
- package/build/dts/components/search-bar/Input.d.ts +0 -9
- package/build/dts/components/search-bar/ProductItem.d.ts +0 -8
- package/build/dts/components/search-bar/ProductItem.test.d.ts +0 -1
- package/build/dts/components/search-bar/ResultsPanel.d.ts +0 -12
- package/build/dts/components/search-bar/ResultsPanel.test.d.ts +0 -1
- package/build/dts/components/search-bar/SearchBar.d.ts +0 -11
- package/build/dts/components/search-bar/SearchBar.stories.d.ts +0 -7
- package/build/dts/components/search-bar/SearchBar.test.d.ts +0 -1
- package/build/dts/components/search-bar/SearchControl.d.ts +0 -7
- package/build/dts/components/search-bar/SearchControl.test.d.ts +0 -1
- package/build/dts/components/search-bar/index.d.ts +0 -1
- package/build/dts/components/selector/simple/SelectorSecondary.d.ts +0 -4
- package/build/dts/components/selector/simple/SelectorSecondary.stories.d.ts +0 -23
- package/build/dts/components/selector/simple/SelectorSecondary.test.d.ts +0 -1
- package/build/dts/components/selector/simple/SimpleSelector.d.ts +0 -11
- package/build/dts/components/selector/simple/SimpleSelector.test.d.ts +0 -1
- package/build/dts/components/shared/button/BaseButton.d.ts +0 -13
- package/build/dts/components/shared/button/BaseButton.stories.d.ts +0 -14
- package/build/dts/components/shared/card/Card.d.ts +0 -18
- package/build/dts/components/shared/card/Card.stories.d.ts +0 -7
- package/build/dts/components/shared/card/Card.test.d.ts +0 -1
- package/build/dts/components/shared/card/CardBody.d.ts +0 -5
- package/build/dts/components/shared/card/CardSection.d.ts +0 -6
- package/build/dts/components/shared/card/index.d.ts +0 -2
- package/build/dts/components/shared/image/Image.d.ts +0 -14
- package/build/dts/components/shared/image/Image.test.d.ts +0 -1
- package/build/dts/components/shared/label/label.d.ts +0 -13
- package/build/dts/components/shared/label/label.test.d.ts +0 -1
- package/build/dts/components/shared/label/styles.d.ts +0 -7
- package/build/dts/components/shared/select/BaseSelect.d.ts +0 -16
- package/build/dts/components/shared/select/BaseSelect.stories.d.ts +0 -11
- package/build/dts/components/shared/select/BaseSelectButton.d.ts +0 -17
- package/build/dts/components/shared/select/BaseSelectOption.d.ts +0 -22
- package/build/dts/components/shared/select/BaseSelectOptions.d.ts +0 -7
- package/build/dts/components/size/guide/SizeFitGuide.d.ts +0 -9
- package/build/dts/components/size/guide/SizeFitGuide.stories.d.ts +0 -9
- package/build/dts/components/size/guide/SizeFitGuide.test.d.ts +0 -1
- package/build/dts/components/size/selector/SizeSelector.d.ts +0 -8
- package/build/dts/components/size/selector/SizeSelector.stories.d.ts +0 -7
- package/build/dts/components/size/selector/SizeSelector.test.d.ts +0 -1
- package/build/dts/components/size-table/SizeTable.d.ts +0 -6
- package/build/dts/components/size-table/SizeTable.stories.d.ts +0 -9
- package/build/dts/components/size-table/SizeTable.test.d.ts +0 -1
- package/build/dts/components/slider/ArrowButton.d.ts +0 -14
- package/build/dts/components/slider/SliderNatigation.test.d.ts +0 -1
- package/build/dts/components/slider/SliderNavigation.d.ts +0 -17
- package/build/dts/components/slider/SliderNavigation.stories.d.ts +0 -9
- package/build/dts/components/slider/StyledSlider.d.ts +0 -16
- package/build/dts/components/spinner/Spinner.d.ts +0 -10
- package/build/dts/components/spinner/Spinner.stories.d.ts +0 -9
- package/build/dts/components/spinner/Spinner.test.d.ts +0 -1
- package/build/dts/components/tag/Tag.d.ts +0 -7
- package/build/dts/components/tag/Tag.test.d.ts +0 -1
- package/build/dts/components/tag/index.d.ts +0 -3
- package/build/dts/components/tag/variants/pdp/category/CategoryTag.d.ts +0 -8
- package/build/dts/components/tag/variants/pdp/category/CategoryTag.stories.d.ts +0 -22
- package/build/dts/components/tag/variants/pdp/category/CategoryTag.test.d.ts +0 -1
- package/build/dts/components/tag/variants/pdp/season-offer/SeasonOfferTag.d.ts +0 -9
- package/build/dts/components/tag/variants/pdp/season-offer/SeasonOfferTag.stories.d.ts +0 -22
- package/build/dts/components/tag/variants/pdp/season-offer/SeasonOfferTag.test.d.ts +0 -1
- package/build/dts/components/text/Text.d.ts +0 -98
- package/build/dts/components/text/Text.stories.d.ts +0 -16
- package/build/dts/components/text-button/TextButton.d.ts +0 -13
- package/build/dts/components/text-button/TextButton.stories.d.ts +0 -58
- package/build/dts/components/text-button/TextButton.test.d.ts +0 -1
- package/build/dts/components/timer/Timer.d.ts +0 -13
- package/build/dts/components/timer/Timer.stories.d.ts +0 -9
- package/build/dts/components/timer/Timer.test.d.ts +0 -1
- package/build/dts/components/tooltip/Arrow.d.ts +0 -6
- package/build/dts/components/tooltip/Styled.d.ts +0 -56
- package/build/dts/components/tooltip/Tooltip.d.ts +0 -15
- package/build/dts/components/tooltip/Tooltip.stories.d.ts +0 -35
- package/build/dts/components/tooltip/Tooltip.test.d.ts +0 -1
- package/build/dts/components/tooltip/utils.d.ts +0 -7
- package/build/dts/components/totals/index.d.ts +0 -5
- package/build/dts/components/totals/subtotal/Subtotal.d.ts +0 -22
- package/build/dts/components/totals/subtotal/Subtotal.stories.d.ts +0 -9
- package/build/dts/components/totals/subtotal/Subtotal.test.d.ts +0 -1
- package/build/dts/components/totals/total/Total.d.ts +0 -38
- package/build/dts/components/totals/total/Total.stories.d.ts +0 -9
- package/build/dts/components/totals/total/Total.test.d.ts +0 -1
- package/build/dts/config/breakpoints.d.ts +0 -5
- package/build/dts/core/theme/Theme.test.d.ts +0 -1
- package/build/dts/core/theme/theme.helpers.d.ts +0 -13
- package/build/dts/core/theme/truekind.theme.d.ts +0 -3
- package/build/dts/hooks/WindowDimensions.d.ts +0 -8
- package/build/dts/hooks/click-outside.d.ts +0 -3
- package/build/dts/hooks/index.d.ts +0 -3
- package/build/dts/index.d.ts +0 -5
- package/build/dts/setupTests.d.ts +0 -1
- package/build/dts/types/enums.d.ts +0 -21
- package/build/dts/types/types.d.ts +0 -81
- package/build/dts/utils/dateFormatter/dateFormatter.d.ts +0 -1
- package/build/dts/utils/dateFormatter/dateFormatter.test.d.ts +0 -1
- package/build/dts/utils/decimalParser/decimalParser.d.ts +0 -4
- package/build/dts/utils/decimalParser/decimalParser.test.d.ts +0 -1
- package/build/dts/utils/index.d.ts +0 -4
- package/build/dts/utils/media.d.ts +0 -7
- package/build/dts/utils/simulateClick/simulateClick.d.ts +0 -1
- package/build/dts/utils/simulateClick/simulateClick.test.d.ts +0 -1
- package/build/dts/utils/sliceString/sliceString.d.ts +0 -1
- package/build/dts/utils/sliceString/sliceString.test.d.ts +0 -1
- package/build/dts/utils/validations/validations.d.ts +0 -5
- package/build/dts/utils/validations/validations.test.d.ts +0 -1
package/build/index.esm.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsxs as jsxs$1, jsx as jsx$1, Fragment as Fragment$1 } from 'react/jsx-runtime';
|
|
2
2
|
import React, { forwardRef, useContext, createElement, createContext, Fragment as Fragment$2, useRef, useLayoutEffect, useMemo, useState, useEffect, isValidElement, cloneElement, useCallback, useReducer, createRef } from 'react';
|
|
3
|
+
import { createPortal } from 'react-dom';
|
|
3
4
|
|
|
4
5
|
/*! *****************************************************************************
|
|
5
6
|
Copyright (c) Microsoft Corporation.
|
|
@@ -55,8 +56,8 @@ function __makeTemplateObject(cooked, raw) {
|
|
|
55
56
|
}
|
|
56
57
|
|
|
57
58
|
var IconWrapper = function (_a) {
|
|
58
|
-
var height = _a.height,
|
|
59
|
-
return (jsxs$1("svg", __assign({ width: width ? "".concat(width, "rem") : '100%', height: height ? "".concat(height, "rem") : '100%', viewBox: "0 0 ".concat(viewBoxX, " ").concat(viewBoxY), xmlns: "http://www.w3.org/2000/svg", "data-testid": testid ? testid : 'IconWrapper', fill: fill }, { children: [jsxs$1("title", { children: [title, " icon"] }, void 0), children] }), void 0));
|
|
59
|
+
var height = _a.height, _b = _a.width, width = _b === void 0 ? 1 : _b, title = _a.title, viewBoxX = _a.viewBoxX, viewBoxY = _a.viewBoxY, children = _a.children, testid = _a.testid, fill = _a.fill;
|
|
60
|
+
return (jsxs$1("svg", __assign({ style: { display: 'inline-block', verticalAlign: 'middle' }, width: width ? "".concat(width, "rem") : '100%', height: height ? "".concat(height, "rem") : width ? "".concat(width, "rem") : '100%', viewBox: "0 0 ".concat(viewBoxX, " ").concat(viewBoxY), xmlns: "http://www.w3.org/2000/svg", "data-testid": testid ? testid : 'IconWrapper', fill: fill }, { children: [jsxs$1("title", { children: [title, " icon"] }, void 0), children] }), void 0));
|
|
60
61
|
};
|
|
61
62
|
|
|
62
63
|
var SixtyDaysGuarantee = function (_a) {
|
|
@@ -342,11 +343,23 @@ var Comment = function (_a) {
|
|
|
342
343
|
return (jsx$1(IconWrapper, __assign({ width: width, height: height, viewBoxX: 22, viewBoxY: 20, title: "Comment" }, { children: jsx$1("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M0 10C0 4.46565 4.92593 0 11 0C17.037 0 22 4.46565 22 10C22 15.5344 17.0741 20 11 20C9 20 7.03704 19.5038 5.33333 18.5496C4.40741 19.0458 3.40741 19.2748 2.2963 19.2748C1.96296 19.2748 1.59259 19.2366 1.25926 19.1985C0.925926 19.1603 0.62963 18.8931 0.555556 18.5496C0.481481 18.2061 0.62963 17.8244 0.925926 17.6336C1.48148 17.2519 1.92593 16.7176 2.22222 16.0305C0.777778 14.313 0 12.1756 0 10ZM5.55556 17.4046C7.18518 18.3588 9.03704 18.855 10.963 18.855C16.4444 18.855 20.8519 14.8855 20.8519 10C20.8519 5.1145 16.4074 1.14504 10.963 1.14504C5.51852 1.14504 1.11111 5.1145 1.11111 10C1.11111 12.0229 1.85185 13.9695 3.22222 15.5344C3.37037 15.687 3.40741 15.916 3.33333 16.1069C3.03704 16.9084 2.62963 17.5954 2.03704 18.1298C3.14815 18.1679 4.14815 17.9389 5 17.4046C5.02318 17.3966 5.04475 17.3887 5.06538 17.381L5.0654 17.381C5.14364 17.3521 5.20837 17.3282 5.2963 17.3282C5.37037 17.3282 5.48148 17.3664 5.55556 17.4046ZM12.1579 10.2941C12.1579 10.7814 11.7691 11.1765 11.2895 11.1765C10.8099 11.1765 10.4211 10.7814 10.4211 10.2941C10.4211 9.80681 10.8099 9.41177 11.2895 9.41177C11.7691 9.41177 12.1579 9.80681 12.1579 10.2941ZM7.23683 11.1765C7.71644 11.1765 8.10525 10.7814 8.10525 10.2941C8.10525 9.8068 7.71644 9.41176 7.23683 9.41176C6.75721 9.41176 6.36841 9.8068 6.36841 10.2941C6.36841 10.7814 6.75721 11.1765 7.23683 11.1765ZM16.2105 10.2941C16.2105 10.7814 15.8217 11.1765 15.3421 11.1765C14.8625 11.1765 14.4737 10.7814 14.4737 10.2941C14.4737 9.80681 14.8625 9.41177 15.3421 9.41177C15.8217 9.41177 16.2105 9.80681 16.2105 10.2941Z", fill: fill }, void 0) }), void 0));
|
|
343
344
|
};
|
|
344
345
|
|
|
346
|
+
var Message = function (_a) {
|
|
347
|
+
var height = _a.height, width = _a.width, fill = _a.fill;
|
|
348
|
+
return (jsx$1(IconWrapper, __assign({ width: width, height: height, viewBoxX: 22, viewBoxY: 20, title: "message icon" }, { children: jsx$1("path", { d: "M0 10C0 4.46565 4.92593 0 11 0C17.037 0 22 4.46565 22 10C22 15.5344 17.0741 20 11 20C9 20 7.03704 19.5038 5.33333 18.5496C4.40741 19.0458 3.40741 19.2748 2.2963 19.2748C1.96296 19.2748 1.59259 19.2366 1.25926 19.1985C0.925926 19.1603 0.62963 18.8931 0.555556 18.5496C0.481481 18.2061 0.62963 17.8244 0.925926 17.6336C1.48148 17.2519 1.92593 16.7176 2.22222 16.0305C0.777778 14.313 0 12.1756 0 10ZM5.55556 17.4046C7.18518 18.3588 9.03704 18.855 10.963 18.855C16.4444 18.855 20.8519 14.8855 20.8519 10C20.8519 5.1145 16.4074 1.14504 10.963 1.14504C5.51852 1.14504 1.11111 5.1145 1.11111 10C1.11111 12.0229 1.85185 13.9695 3.22222 15.5344C3.37037 15.687 3.40741 15.916 3.33333 16.1069C3.03704 16.9084 2.62963 17.5954 2.03704 18.1298C3.14815 18.1679 4.14815 17.9389 5 17.4046C5.02318 17.3966 5.04475 17.3887 5.06538 17.381L5.0654 17.381C5.14364 17.3521 5.20837 17.3282 5.2963 17.3282C5.37037 17.3282 5.48148 17.3664 5.55556 17.4046ZM12.1579 10.2941C12.1579 10.7814 11.7691 11.1765 11.2895 11.1765C10.8099 11.1765 10.4211 10.7814 10.4211 10.2941C10.4211 9.80681 10.8099 9.41177 11.2895 9.41177C11.7691 9.41177 12.1579 9.80681 12.1579 10.2941ZM7.23683 11.1765C7.71644 11.1765 8.10525 10.7814 8.10525 10.2941C8.10525 9.8068 7.71644 9.41176 7.23683 9.41176C6.75721 9.41176 6.36841 9.8068 6.36841 10.2941C6.36841 10.7814 6.75721 11.1765 7.23683 11.1765ZM16.2105 10.2941C16.2105 10.7814 15.8217 11.1765 15.3421 11.1765C14.8625 11.1765 14.4737 10.7814 14.4737 10.2941C14.4737 9.80681 14.8625 9.41177 15.3421 9.41177C15.8217 9.41177 16.2105 9.80681 16.2105 10.2941Z", fill: fill }, void 0) }), void 0));
|
|
349
|
+
};
|
|
350
|
+
|
|
351
|
+
var Mail = function (_a) {
|
|
352
|
+
var height = _a.height, width = _a.width;
|
|
353
|
+
return (jsxs$1(IconWrapper, __assign({ width: width, height: height, viewBoxX: 24, viewBoxY: 24, title: "message icon" }, { children: [jsx$1("path", { d: "M21.4-14.3c0,0.1,0,0.2,0,0.3c0.1,0,0.1,0,0.2,0s0.1,0,0.2,0s0.1,0,0.2,0c0,0.1,0,0.1,0,0.2c0,0.1,0,0.2,0,0.2\n\tc0,0.1,0,0.2,0,0.2h0.1c0,0.1,0,0.2,0,0.3l0,0l0,0c0-0.1,0-0.2,0-0.3c0.1,0,0.1,0,0.2,0c0,0,0,0,0,0.1s0,0.2,0,0.2\n\tc0,0.1,0,0.3,0,0.4l0,0l0,0c0,0,0,0,0,0.1c0,0.2,0,0.3,0,0.5c0,0.1,0,0.2,0,0.3v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1\n\tv0.1v0.1v0.1v0.1c0,0,0,0,0,0.1c0,0,0,0,0,0.1c0,0.2,0,0.3,0,0.5c0,0.1,0,0.2,0,0.3v0.1V-9v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1v0.1V-8\n\tv0.1v0.1v0.1v0.1c0,0,0,0,0,0.1c0,0,0,0,0,0.1c0,0.2,0,0.3,0,0.5c0,0.1,0,0.2,0,0.3v0.1v0.1v0.1v0.1v0.1V-6v0.1v0.1v0.1v0.1\n\tc0,0.2,0,0.5,0,0.7c-0.1,0-0.1,0-0.2,0c0-0.1,0-0.2,0-0.3v0.1V-5v0.1H22c0,0,0,0,0,0.1s0,0.1,0,0.2s0,0.1,0,0.2s0,0.1,0,0.2\n\tc-0.2,0-0.4,0-0.7,0c0,0.1,0,0.2,0,0.3l0,0l0,0c-4.5,0-9,0-13.5,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.2,0-0.4,0-0.6\n\tc-0.1,0-0.2,0-0.3,0l0,0l0,0c0.1,0,0.2,0,0.3,0v-0.1c-0.1,0-0.2,0-0.3,0c0-2.9,0-5.9,0-8.8c0.1,0,0.2,0,0.3,0v-0.1\n\tc-0.1,0-0.2,0-0.3,0l0,0c0.1,0,0.2,0,0.3,0c0-0.2,0-0.4,0-0.6c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3C12.4-14.3,16.9-14.3,21.4-14.3z\n\t M21-4.4L21-4.4c0-0.2,0-0.3,0-0.4c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3l0,0l0,0\n\tc-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3\n\tc-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3l0,0l0,0\n\tc-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.2,0-0.4,0-0.7,0l0,0c0,0.1,0,0.2,0,0.3\n\tc-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.2,0c-0.1,0-0.2,0-0.2,0c-0.1,0-0.1,0-0.2,0c0,0.1,0,0.2,0,0.3\n\tc-0.1,0-0.2,0-0.3,0l0,0c0,0.1,0,0.2,0,0.3c-0.5,0-1,0-1.5,0c0-0.1,0-0.1,0-0.2c0.1,0,0.1,0,0.2,0c-0.1,0-0.1,0-0.2,0v-0.1l0,0v0.1\n\th-0.1v-0.1c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.2,0c-0.1,0-0.1,0-0.2,0c-0.1,0-0.1,0-0.2,0c0-0.1,0-0.2,0-0.3l0,0\n\tl0,0c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c0,0,0,0,0-0.1h-0.1h-0.1H13h-0.1h-0.1h-0.1h-0.1v0.1v0.1v0.1c-0.1,0-0.2,0-0.3,0\n\tc0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0c0,0,0,0,0,0.1c0,0,0,0,0,0.1c0,0,0,0,0,0.1\n\tc0,0,0,0,0,0.1c0,0,0,0,0,0.1c-0.1,0-0.2,0-0.3,0l0,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0l0,0c0,0,0,0,0,0.1s0,0.2,0,0.3\n\tc-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.2,0c-0.1,0-0.2,0-0.2,0c-0.1,0-0.1,0-0.2,0c0,0.1,0,0.2,0,0.3c0,0,0,0,0,0.1\n\tc-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3c0,0,0,0-0.1,0c0,0,0,0-0.1,0c0,0,0,0-0.1,0c0,0,0,0-0.1,0c0,0,0,0-0.1,0c0,0,0,0-0.1,0\n\tc0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.2,0,12.4,0,12.5,0\n\tC21-4.2,21-4.3,21-4.4C21-4.3,21-4.3,21-4.4C21-4.3,21-4.3,21-4.4z M21-13.4c0-0.1,0-0.1,0-0.2c-4.2,0-8.3,0-12.5,0\n\tc0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0c0,0.3,0,0.7,0,1c0.1,0,0.2,0,0.2,0c0.1,0,0.2,0,0.2,0c0.1,0,0.1,0,0.2,0c0,0.1,0,0.2,0,0.3\n\tc0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3l0,0l0,0c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.1,0,0.2,0c0.1,0,0.1,0,0.2,0\n\tc0.1,0,0.1,0,0.2,0c0,0,0,0,0.1,0c0,0.1,0,0.2,0,0.3l0,0c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0l0,0\n\tc0,0.1,0,0.2,0,0.3c0.1,0,0.1,0,0.2,0c0.1,0,0.1,0,0.2,0c0,0,0,0,0.1,0c0,0.1,0,0.2,0,0.3l0,0l0,0c0-0.1,0-0.2,0-0.3\n\tc0.1,0,0.1,0,0.2,0c0,0.1,0,0.2,0,0.3l0,0c0.1,0,0.2,0,0.3,0v0.1v0.1v0.1l0,0c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3\n\tc0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.2,0c0.1,0,0.2,0,0.2,0c0.1,0,0.1,0,0.2,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0\n\tc0,0,0,0,0,0.1s0,0.2,0,0.3c0.1,0,0.2,0,0.3,0c0,0,0,0,0.1,0c0,0.1,0,0.2,0,0.3c0.6,0,1.1,0,1.7,0c0-0.1,0-0.2,0-0.3l0,0\n\tc0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3l0,0c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.2,0c0.1,0,0.1,0,0.2,0s0.1,0,0.2,0\n\tc0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0,0,0,0,0-0.1c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0l0,0\n\tc0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.2,0c0.1,0,0.2,0,0.2,0c0.1,0,0.1,0,0.2,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3\n\tc0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.2,0c0.1,0,0.2,0,0.2,0c0.1,0,0.1,0,0.2,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0\n\tc0-0.1,0-0.2,0-0.3l0,0l0,0c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.1,0-0.2h0.1h0.1c0,0.1,0,0.1,0,0.2\n\tl0,0l0,0c0-0.1,0-0.1,0-0.2h0.1l0,0h-0.1v-0.1h0.1c0-0.2,0-0.4,0-0.7c-0.1,0-0.2,0-0.3,0C21-13.3,21-13.3,21-13.4\n\tC21-13.3,21-13.3,21-13.4L21-13.4L21-13.4z M18.3-9.2c0,0.2,0,0.5,0,0.7l0,0h0.1h0.1c0,0,0,0,0.1,0h0.1c0,0.1,0,0.2,0,0.3l0,0\n\tc0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0l0,0l0,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3\n\tc0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3l0,0l0,0c0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3\n\tc0.1,0,0.2,0,0.3,0c0,0.1,0,0.2,0,0.3c0.1,0,0.2,0,0.3,0c0-1.8,0-3.6,0-5.4l0,0c0,0,0,0-0.1,0c0,0,0,0-0.1,0h-0.1h-0.1l0,0\n\tc0,0.1,0,0.2,0,0.3c-0.2,0-0.3,0-0.5,0c-0.1,0-0.1,0-0.2,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3\n\tc-0.1,0-0.2,0-0.3,0l0,0l0,0c0,0.1,0,0.2,0,0.3c-0.1,0-0.2,0-0.2,0c-0.1,0-0.2,0-0.2,0c-0.1,0-0.1,0-0.2,0v0.1v0.1v0.1\n\tc-0.1,0-0.2,0-0.3,0c0,0.1,0,0.2,0,0.3C18.6-9.2,18.4-9.2,18.3-9.2z M8.2-5.8c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3l0,0l0,0\n\tc0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0\n\tc0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3c0.1,0,0.2,0,0.3,0c0-0.1,0-0.2,0-0.3\n\tc0.1,0,0.2,0,0.3,0l0,0c0-0.1,0-0.2,0-0.3s0-0.2,0-0.4c0,0,0,0,0-0.1c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0l0,0\n\tc0-0.1,0-0.1,0-0.2h-0.1v0.1v0.1c0-0.1,0-0.1,0-0.2c-0.1,0-0.2,0-0.2,0h0.1h0.1v-0.1c-0.1,0-0.2,0-0.3,0s-0.1,0-0.2,0\n\tc0-0.1,0-0.2,0-0.3l0,0c-0.1,0-0.2,0-0.3,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0v-0.1v-0.1v-0.1c-0.1,0-0.2,0-0.2,0\n\tc-0.1,0-0.2,0-0.2,0c-0.1,0-0.1,0-0.2,0c0-0.1,0-0.2,0-0.3c-0.1,0-0.2,0-0.3,0C8.2-9.4,8.2-7.6,8.2-5.8z M10.5-9.9v0.1h0.1\n\tC10.5-9.8,10.5-9.8,10.5-9.9L10.5-9.9z" }, void 0), jsxs$1("g", { children: [jsx$1("path", { d: "M4.8,9.4H2.3C2,9.4,1.8,9.2,1.8,8.8c0-0.3,0.2-0.6,0.5-0.6h2.5c0.3,0,0.5,0.3,0.5,0.6C5.3,9.2,5,9.4,4.8,9.4z" }, void 0), jsx$1("path", { d: "M4.8,12H3.7c-0.3,0-0.5-0.2-0.5-0.5S3.4,11,3.7,11h1.1c0.3,0,0.5,0.2,0.5,0.5S5.1,12,4.8,12z" }, void 0), jsx$1("path", { d: "M4.8,14.6H1.6c-0.3,0-0.5-0.3-0.5-0.6c0-0.3,0.2-0.6,0.5-0.6h3.2c0.3,0,0.5,0.3,0.5,0.6C5.3,14.3,5.1,14.6,4.8,14.6z" }, void 0), jsx$1("path", { d: "M21.3,6.1H8.1c-0.9,0-1.7,0.7-1.7,1.7v8.5c0,0.9,0.7,1.7,1.7,1.7h13.3c0.9,0,1.7-0.7,1.7-1.7V7.8C23,6.9,22.3,6.1,21.3,6.1\n\t\tz M18.4,11.7c1.3-1,2.7-2.1,3.6-2.7v6.4L18.4,11.7z M8.1,7.2h13.3c0.3,0,0.5,0.2,0.6,0.5c-1,0.8-5.4,4.2-7,5.4\n\t\tc-0.2,0.1-0.3,0.1-0.5,0c-1.6-1.2-5.7-4.1-7-5V7.8C7.5,7.4,7.8,7.2,8.1,7.2z M7.5,15.3v-6c0.9,0.6,2.3,1.6,3.6,2.6L7.5,15.3z\n\t\t M8.1,16.8c-0.2,0-0.3-0.1-0.4-0.2l4.3-4.1c0.7,0.5,1.4,1,1.9,1.3c0.3,0.2,0.6,0.3,0.9,0.3s0.6-0.1,0.9-0.3c0.5-0.3,1.2-0.9,2-1.5\n\t\tl4.2,4.3c-0.1,0.1-0.2,0.2-0.4,0.2H8.1z" }, void 0)] }, void 0)] }), void 0));
|
|
354
|
+
};
|
|
355
|
+
|
|
345
356
|
var Messaging = /*#__PURE__*/Object.freeze({
|
|
346
357
|
__proto__: null,
|
|
347
358
|
QuestionCircle: QuestionCircle,
|
|
348
359
|
Messenger: Messenger,
|
|
349
|
-
Comment: Comment
|
|
360
|
+
Comment: Comment,
|
|
361
|
+
Message: Message,
|
|
362
|
+
Mail: Mail
|
|
350
363
|
});
|
|
351
364
|
|
|
352
365
|
var AppleStore = function (_a) {
|
|
@@ -3268,7 +3281,7 @@ var InputValidationType;
|
|
|
3268
3281
|
})(InputValidationType || (InputValidationType = {}));
|
|
3269
3282
|
|
|
3270
3283
|
var Section = newStyled.div(templateObject_1$$ || (templateObject_1$$ = __makeTemplateObject(["\n font-weight: 600;\n display: flex;\n flex-direction: row;\n align-items: center;\n align-text: left;\n width: 100%;\n box-sizing: border-box;\n align-self: flex-start;\n padding: ", ";\n"], ["\n font-weight: 600;\n display: flex;\n flex-direction: row;\n align-items: center;\n align-text: left;\n width: 100%;\n box-sizing: border-box;\n align-self: flex-start;\n padding: ", ";\n"])), function (props) {
|
|
3271
|
-
return props.type === CardSectionType.Header ? '
|
|
3284
|
+
return props.type === CardSectionType.Header ? '1.5rem 1.5rem 0' : '0 1.5rem 1.5rem';
|
|
3272
3285
|
});
|
|
3273
3286
|
var CardHeader = function (_a) {
|
|
3274
3287
|
var children = _a.children;
|
|
@@ -3287,6 +3300,7 @@ var CardBody = function (_a) {
|
|
|
3287
3300
|
};
|
|
3288
3301
|
var templateObject_1$_;
|
|
3289
3302
|
|
|
3303
|
+
var IGNORED_KEYS = ['typography', 'fonts'];
|
|
3290
3304
|
var applyVariablesIntoTheme = function (theme) {
|
|
3291
3305
|
var variables = {};
|
|
3292
3306
|
var pending = {};
|
|
@@ -3299,6 +3313,11 @@ var applyVariablesIntoTheme = function (theme) {
|
|
|
3299
3313
|
}
|
|
3300
3314
|
variables[key] = variables[valueKey];
|
|
3301
3315
|
}
|
|
3316
|
+
for (var _i = 0, IGNORED_KEYS_1 = IGNORED_KEYS; _i < IGNORED_KEYS_1.length; _i++) {
|
|
3317
|
+
var key = IGNORED_KEYS_1[_i];
|
|
3318
|
+
// @ts-ignore
|
|
3319
|
+
variables[key] = theme[key];
|
|
3320
|
+
}
|
|
3302
3321
|
return variablesToObject(variables, {});
|
|
3303
3322
|
};
|
|
3304
3323
|
var variablesToObject = function (variables, theme) {
|
|
@@ -3308,7 +3327,7 @@ var variablesToObject = function (variables, theme) {
|
|
|
3308
3327
|
for (var i = 0; i < path.length; i++) {
|
|
3309
3328
|
var segment = path[i];
|
|
3310
3329
|
var isLast = i === path.length - 1;
|
|
3311
|
-
var isArray = new RegExp("".concat(segment, "-0
|
|
3330
|
+
var isArray = new RegExp("".concat(segment, "-0[-\\w]*$")).test(key);
|
|
3312
3331
|
var segmentValue = isLast ? variables[key] : isArray ? [] : {};
|
|
3313
3332
|
if (segment in target === false) {
|
|
3314
3333
|
// @ts-ignore
|
|
@@ -3326,6 +3345,9 @@ var transformToVariables = function (prefix, variables, theme, pending) {
|
|
|
3326
3345
|
/* istanbul ignore next */
|
|
3327
3346
|
var fullKey = key === '$root' ? prefix : "".concat(prefix, "-").concat(key);
|
|
3328
3347
|
var value = theme[key];
|
|
3348
|
+
if (IGNORED_KEYS.includes(key)) {
|
|
3349
|
+
continue;
|
|
3350
|
+
}
|
|
3329
3351
|
if (value == null) {
|
|
3330
3352
|
continue;
|
|
3331
3353
|
}
|
|
@@ -3460,13 +3482,14 @@ function jsxs(type, props, key) {
|
|
|
3460
3482
|
}
|
|
3461
3483
|
|
|
3462
3484
|
var BaseButton = function (_a) {
|
|
3463
|
-
var children = _a.children, renderLeading = _a.renderLeading, renderTrailing = _a.renderTrailing, disabled = _a.disabled, _b = _a.type, type = _b === void 0 ? 'button' : _b, onClick = _a.onClick, className = _a.className;
|
|
3485
|
+
var children = _a.children, renderLeading = _a.renderLeading, renderTrailing = _a.renderTrailing, disabled = _a.disabled, _b = _a.type, type = _b === void 0 ? 'button' : _b, onClick = _a.onClick, className = _a.className, inline = _a.inline;
|
|
3464
3486
|
return (jsxs("button", __assign({ onClick: onClick, disabled: disabled, className: className, type: type, css: {
|
|
3465
|
-
display: 'flex',
|
|
3487
|
+
display: inline ? 'inherit-flex' : 'flex',
|
|
3466
3488
|
justifyContent: 'center',
|
|
3467
3489
|
alignItems: 'center',
|
|
3468
3490
|
padding: '0.75rem 2rem',
|
|
3469
3491
|
textDecoration: 'none',
|
|
3492
|
+
textTransform: 'uppercase',
|
|
3470
3493
|
boxSizing: 'border-box',
|
|
3471
3494
|
cursor: 'pointer',
|
|
3472
3495
|
} }, { children: [renderLeading, children, renderTrailing] }), void 0));
|
|
@@ -3500,7 +3523,7 @@ var BaseCTA = function (_a) {
|
|
|
3500
3523
|
var text = _a.text, onClick = _a.onClick, _b = _a.disabled, disabled = _b === void 0 ? false : _b, _c = _a.wide, wide = _c === void 0 ? false : _c, _d = _a.size, size = _d === void 0 ? ComponentSize.Medium : _d, type = _a.type, className = _a.className;
|
|
3501
3524
|
var theme = useTheme();
|
|
3502
3525
|
var stylesBySize = getStylesBySize$9(size, theme);
|
|
3503
|
-
return (jsx(BaseButton, __assign({ onClick: onClick, disabled: disabled, className: className, type: type, css: __assign(__assign({ width: wide ? '100%' : '' }, stylesBySize), { fontWeight: theme.component.button.fontWeight, borderRadius: "".concat(theme.component.button.borderRadius), cursor: 'pointer', '&:disabled': {
|
|
3526
|
+
return (jsx(BaseButton, __assign({ onClick: onClick, disabled: disabled, className: className, type: type, css: __assign(__assign({ width: wide ? '100%' : 'fit-content' }, stylesBySize), { fontWeight: theme.component.button.fontWeight, borderRadius: "".concat(theme.component.button.borderRadius), cursor: 'pointer', '&:disabled': {
|
|
3504
3527
|
backgroundColor: theme.colors.background.disabled,
|
|
3505
3528
|
color: theme.colors.text.disabled,
|
|
3506
3529
|
cursor: 'not-allowed',
|
|
@@ -4417,7 +4440,7 @@ function Disclosure(props) {
|
|
|
4417
4440
|
} // ---
|
|
4418
4441
|
|
|
4419
4442
|
var DEFAULT_BUTTON_TAG$1 = 'button';
|
|
4420
|
-
var Button$
|
|
4443
|
+
var Button$7 = /*#__PURE__*/forwardRefWithAs(function Button(props, ref) {
|
|
4421
4444
|
var _useDisclosureContext = useDisclosureContext([Disclosure.name, Button.name].join('.')),
|
|
4422
4445
|
state = _useDisclosureContext[0],
|
|
4423
4446
|
dispatch = _useDisclosureContext[1];
|
|
@@ -4580,7 +4603,7 @@ var Panel = /*#__PURE__*/forwardRefWithAs(function Panel(props, ref) {
|
|
|
4580
4603
|
}));
|
|
4581
4604
|
}); // ---
|
|
4582
4605
|
|
|
4583
|
-
Disclosure.Button = Button$
|
|
4606
|
+
Disclosure.Button = Button$7;
|
|
4584
4607
|
Disclosure.Panel = Panel;
|
|
4585
4608
|
|
|
4586
4609
|
function disposables() {
|
|
@@ -4976,7 +4999,7 @@ function Listbox(props) {
|
|
|
4976
4999
|
} // ---
|
|
4977
5000
|
|
|
4978
5001
|
var DEFAULT_BUTTON_TAG = 'button';
|
|
4979
|
-
var Button$
|
|
5002
|
+
var Button$6 = /*#__PURE__*/forwardRefWithAs(function Button(props, ref) {
|
|
4980
5003
|
var _state$optionsRef$cur;
|
|
4981
5004
|
|
|
4982
5005
|
var _useListboxContext = useListboxContext([Listbox.name, Button.name].join('.')),
|
|
@@ -5435,7 +5458,7 @@ function Option$2(props) {
|
|
|
5435
5458
|
} // ---
|
|
5436
5459
|
|
|
5437
5460
|
|
|
5438
|
-
Listbox.Button = Button$
|
|
5461
|
+
Listbox.Button = Button$6;
|
|
5439
5462
|
Listbox.Label = Label$4;
|
|
5440
5463
|
Listbox.Options = Options;
|
|
5441
5464
|
Listbox.Option = Option$2;
|
|
@@ -6147,7 +6170,7 @@ var CustomCheckbox = newStyled.div(CustomCheckboxStyles.baseStyles, function (pr
|
|
|
6147
6170
|
CustomCheckboxStyles[props.size](props.theme),
|
|
6148
6171
|
CustomCheckboxStyles[props.variant](props.theme, props.isChecked, props.disabled),
|
|
6149
6172
|
]; });
|
|
6150
|
-
var Input$3 = newStyled.input(templateObject_2$
|
|
6173
|
+
var Input$3 = newStyled.input(templateObject_2$C || (templateObject_2$C = __makeTemplateObject(["\n position: absolute;\n height: 100%;\n width: 100%;\n margin: 0;\n opacity: 0;\n cursor: ", ";\n"], ["\n position: absolute;\n height: 100%;\n width: 100%;\n margin: 0;\n opacity: 0;\n cursor: ", ";\n"])), function (_a) {
|
|
6151
6174
|
var disabled = _a.disabled;
|
|
6152
6175
|
return (disabled ? 'not-allowed' : 'pointer');
|
|
6153
6176
|
});
|
|
@@ -6173,7 +6196,7 @@ var Checkbox = function (_a) {
|
|
|
6173
6196
|
}, []);
|
|
6174
6197
|
return (jsxs$1(Container$B, { children: [jsx$1(Input$3, { type: "checkbox", checked: isChecked, disabled: disabled, onChange: handleChange, id: id }, void 0), jsx$1(CustomCheckbox, __assign({ theme: theme, size: size, disabled: disabled, isChecked: isChecked, "data-testid": "checkbox", variant: variant }, { children: isChecked && jsx$1(Icon.Actions.Check, { fill: "#fff" }, void 0) }), void 0), jsx$1(Label$2, __assign({ "data-testid": "checkbox-text", size: size, variant: isChecked ? 'demi' : 'regular', htmlFor: id, disabled: disabled }, { children: text }), void 0)] }, void 0));
|
|
6175
6198
|
};
|
|
6176
|
-
var templateObject_1$X, templateObject_2$
|
|
6199
|
+
var templateObject_1$X, templateObject_2$C;
|
|
6177
6200
|
|
|
6178
6201
|
var CustomOption = newStyled.li(function (_a) {
|
|
6179
6202
|
var theme = _a.theme, selected = _a.selected, active = _a.active;
|
|
@@ -6291,19 +6314,150 @@ var SelectorSecondary = function (_a) {
|
|
|
6291
6314
|
} }) }, void 0));
|
|
6292
6315
|
};
|
|
6293
6316
|
|
|
6294
|
-
|
|
6295
|
-
|
|
6317
|
+
// This defines which HTML tag to render for each `variant`, it also defines
|
|
6318
|
+
// `variants` styles that are consistent through all themes.
|
|
6319
|
+
var TAGS = {
|
|
6320
|
+
hero1: newStyled.h1(templateObject_1$W || (templateObject_1$W = __makeTemplateObject([""], [""]))),
|
|
6321
|
+
hero2: newStyled.h2(templateObject_2$B || (templateObject_2$B = __makeTemplateObject([""], [""]))),
|
|
6322
|
+
hero3: newStyled.h3(templateObject_3$n || (templateObject_3$n = __makeTemplateObject([""], [""]))),
|
|
6323
|
+
display1: newStyled.h1(templateObject_4$c || (templateObject_4$c = __makeTemplateObject([""], [""]))),
|
|
6324
|
+
display2: newStyled.h2(templateObject_5$7 || (templateObject_5$7 = __makeTemplateObject([""], [""]))),
|
|
6325
|
+
heading1: newStyled.h1(templateObject_6$5 || (templateObject_6$5 = __makeTemplateObject([""], [""]))),
|
|
6326
|
+
heading2: newStyled.h2(templateObject_7$3 || (templateObject_7$3 = __makeTemplateObject([""], [""]))),
|
|
6327
|
+
heading3: newStyled.h3(templateObject_8$1 || (templateObject_8$1 = __makeTemplateObject([""], [""]))),
|
|
6328
|
+
heading4: newStyled.h4(templateObject_9 || (templateObject_9 = __makeTemplateObject([""], [""]))),
|
|
6329
|
+
heading5: newStyled.h5(templateObject_10 || (templateObject_10 = __makeTemplateObject([""], [""]))),
|
|
6330
|
+
heading6: newStyled.h6(templateObject_11 || (templateObject_11 = __makeTemplateObject([""], [""]))),
|
|
6331
|
+
body: newStyled.p(templateObject_12 || (templateObject_12 = __makeTemplateObject([""], [""]))),
|
|
6332
|
+
link: newStyled.a(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n cursor: pointer;\n color: inherit;\n text-decoration: ", ";\n "], ["\n cursor: pointer;\n color: inherit;\n text-decoration: ", ";\n "])), function (props) { return (props.underline ? 'underline' : 'none'); }),
|
|
6333
|
+
button: newStyled.span(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n display: inline-block;\n "], ["\n display: inline-block;\n "]))),
|
|
6334
|
+
pricing: newStyled.span(templateObject_15 || (templateObject_15 = __makeTemplateObject(["\n display: inline-block;\n font-weight: ", ";\n text-decoration: ", ";\n "], ["\n display: inline-block;\n font-weight: ", ";\n text-decoration: ", ";\n "])), function (props) { return (props.original ? 'normal' : 'bold'); }, function (props) { return (props.original ? 'line-through' : 'bold'); }),
|
|
6335
|
+
label: newStyled.label(templateObject_16 || (templateObject_16 = __makeTemplateObject([""], [""]))),
|
|
6336
|
+
tag: newStyled.span(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n display: inline-block;\n text-transform: ", ";\n "], ["\n display: inline-block;\n text-transform: ", ";\n "])), function (props) { return (props.allCaps ? 'uppercase' : ''); }),
|
|
6337
|
+
};
|
|
6338
|
+
var Text$3 = function (_a) {
|
|
6339
|
+
var variant = _a.variant, children = _a.children, allProps = __rest(_a, ["variant", "children"]);
|
|
6340
|
+
var theme = useTheme();
|
|
6341
|
+
var Tag = useMemo(function () { return TAGS[variant] || 'p'; }, [variant]);
|
|
6342
|
+
var _b = useMemo(function () {
|
|
6343
|
+
var _a;
|
|
6344
|
+
return (__assign(__assign({}, ((_a = DEFAULTS === null || DEFAULTS === void 0 ? void 0 : DEFAULTS[variant]) !== null && _a !== void 0 ? _a : {})), allProps));
|
|
6345
|
+
}, [variant, allProps]), size = _b.size, weight = _b.weight, props = __rest(_b, ["size", "weight"]);
|
|
6346
|
+
var commonCSS = useMemo(function () {
|
|
6347
|
+
var _a, _b;
|
|
6348
|
+
// These are the common style inside a `variant`.
|
|
6349
|
+
// E.g.: Common styles for all "button".
|
|
6350
|
+
var variantstyle = (_a = theme.typography.variants[variant]) !== null && _a !== void 0 ? _a : {
|
|
6351
|
+
fontSize: 14,
|
|
6352
|
+
lineHeight: 1,
|
|
6353
|
+
};
|
|
6354
|
+
// This allow us to define different styles for different `sizes` inside a `variant`
|
|
6355
|
+
// E.g.: "button-small", "button-regular"
|
|
6356
|
+
//
|
|
6357
|
+
// We use .filter(Boolean) to ignore the `size` on the `variants` that don't have it.
|
|
6358
|
+
// E.g.: "hero1", "display1"
|
|
6359
|
+
var variantName = [variant, size].filter(Boolean).join('-');
|
|
6360
|
+
// These are styles specific to `variation-size`.
|
|
6361
|
+
var variantSizeStyle = (_b = theme.typography.variants[variantName]) !== null && _b !== void 0 ? _b : {};
|
|
6362
|
+
var style = __assign(__assign({ margin: 0, color: theme.colors.text.color }, variantstyle), variantSizeStyle);
|
|
6363
|
+
if (weight) {
|
|
6364
|
+
style.fontWeight = theme.typography.config.weight[weight];
|
|
6365
|
+
}
|
|
6366
|
+
if (props.disabled) {
|
|
6367
|
+
style.opacity = 0.5;
|
|
6368
|
+
style.cursor = 'not-allowed';
|
|
6369
|
+
style.color = theme.colors.text.disabled;
|
|
6370
|
+
}
|
|
6371
|
+
return style;
|
|
6372
|
+
}, [theme, variant, weight, size, props.disabled]);
|
|
6373
|
+
// This is to make TS happy, because `href` doesn't exists on other `variants`
|
|
6374
|
+
var propsHref = props.href;
|
|
6375
|
+
var href = useMemo(function () {
|
|
6376
|
+
// We could use `pointer-events: none` but it prevents us from using
|
|
6377
|
+
// `cursor: not-allowed`, so we're changing the `href` for `disabled` links.
|
|
6378
|
+
if (propsHref != null && props.disabled) {
|
|
6379
|
+
return 'javascript:void(0)';
|
|
6380
|
+
}
|
|
6381
|
+
return propsHref;
|
|
6382
|
+
}, [props.disabled, propsHref]);
|
|
6383
|
+
return (jsx(Tag, __assign({}, props, { css: commonCSS, href: href }, { children: children }), void 0));
|
|
6384
|
+
};
|
|
6385
|
+
var DEFAULTS = {
|
|
6386
|
+
heading1: {
|
|
6387
|
+
weight: 'bold',
|
|
6388
|
+
},
|
|
6389
|
+
heading2: {
|
|
6390
|
+
weight: 'bold',
|
|
6391
|
+
},
|
|
6392
|
+
heading3: {
|
|
6393
|
+
weight: 'bold',
|
|
6394
|
+
},
|
|
6395
|
+
heading4: {
|
|
6396
|
+
weight: 'bold',
|
|
6397
|
+
},
|
|
6398
|
+
heading5: {
|
|
6399
|
+
weight: 'bold',
|
|
6400
|
+
},
|
|
6401
|
+
heading6: {
|
|
6402
|
+
weight: 'bold',
|
|
6403
|
+
},
|
|
6404
|
+
hero1: {
|
|
6405
|
+
weight: 'heavy',
|
|
6406
|
+
},
|
|
6407
|
+
hero2: {
|
|
6408
|
+
weight: 'heavy',
|
|
6409
|
+
},
|
|
6410
|
+
hero3: {
|
|
6411
|
+
weight: 'heavy',
|
|
6412
|
+
},
|
|
6413
|
+
display1: {
|
|
6414
|
+
weight: 'bold',
|
|
6415
|
+
},
|
|
6416
|
+
display2: {
|
|
6417
|
+
weight: 'bold',
|
|
6418
|
+
},
|
|
6419
|
+
body: {
|
|
6420
|
+
size: 'regular',
|
|
6421
|
+
weight: 'regular',
|
|
6422
|
+
},
|
|
6423
|
+
button: {
|
|
6424
|
+
size: 'regular',
|
|
6425
|
+
weight: 'bold',
|
|
6426
|
+
},
|
|
6427
|
+
tag: {
|
|
6428
|
+
size: 'regular',
|
|
6429
|
+
weight: 'regular',
|
|
6430
|
+
},
|
|
6431
|
+
label: {
|
|
6432
|
+
size: 'regular',
|
|
6433
|
+
weight: 'regular',
|
|
6434
|
+
},
|
|
6435
|
+
link: {
|
|
6436
|
+
size: 'regular',
|
|
6437
|
+
weight: 'regular',
|
|
6438
|
+
},
|
|
6439
|
+
pricing: {
|
|
6440
|
+
size: 'regular',
|
|
6441
|
+
},
|
|
6442
|
+
};
|
|
6443
|
+
var templateObject_1$W, templateObject_2$B, templateObject_3$n, templateObject_4$c, templateObject_5$7, templateObject_6$5, templateObject_7$3, templateObject_8$1, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13, templateObject_14, templateObject_15, templateObject_16, templateObject_17;
|
|
6444
|
+
|
|
6445
|
+
var ButtonsContainer = newStyled.div(templateObject_1$V || (templateObject_1$V = __makeTemplateObject(["\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n"], ["\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n"])));
|
|
6296
6446
|
var SizeSelector = function (_a) {
|
|
6297
|
-
var sizes = _a.sizes, selectedValue = _a.selectedValue, onChange = _a.onChange;
|
|
6298
|
-
return (jsxs("div",
|
|
6447
|
+
var label = _a.label, sizes = _a.sizes, selectedValue = _a.selectedValue, onChange = _a.onChange, _b = _a.inline, inline = _b === void 0 ? false : _b;
|
|
6448
|
+
return (jsxs("div", __assign({ css: {
|
|
6449
|
+
display: 'flex',
|
|
6450
|
+
flexDirection: inline ? 'row' : 'column',
|
|
6451
|
+
alignItems: inline ? 'center' : 'start',
|
|
6452
|
+
} }, { children: [jsxs(Text$3, __assign({ variant: "body", weight: "regular", size: "small" }, { children: [label, !inline && (jsx(Text$3, __assign({ variant: "label", weight: "demi", size: "regular" }, { children: selectedValue.description }), void 0))] }), void 0), jsx(ButtonsContainer, { children: sizes.map(function (size) {
|
|
6299
6453
|
var active = !size.disabled && size.label === selectedValue.label;
|
|
6300
6454
|
return (jsx(SelectorSecondary, { css: {
|
|
6301
6455
|
padding: '0.75rem 1rem 0.625rem',
|
|
6302
|
-
margin: '0
|
|
6456
|
+
margin: '0.5rem',
|
|
6303
6457
|
}, size: ComponentSize.Medium, text: size.label, active: active, disabled: size.disabled, onClick: function () { return onChange(size); } }, size.label));
|
|
6304
|
-
}) }, void 0)] }, void 0));
|
|
6458
|
+
}) }, void 0)] }), void 0));
|
|
6305
6459
|
};
|
|
6306
|
-
var templateObject_1$
|
|
6460
|
+
var templateObject_1$V;
|
|
6307
6461
|
|
|
6308
6462
|
var getStylesBySize$7 = function (size) {
|
|
6309
6463
|
switch (size) {
|
|
@@ -6332,7 +6486,7 @@ var textButtonStyles$1 = function (theme, size) {
|
|
|
6332
6486
|
} });
|
|
6333
6487
|
};
|
|
6334
6488
|
var withContainer = function (iconFill, isLeading, Icon) {
|
|
6335
|
-
return Icon && (jsx("span", __assign({ css: css(templateObject_1$
|
|
6489
|
+
return Icon && (jsx("span", __assign({ css: css(templateObject_1$U || (templateObject_1$U = __makeTemplateObject(["\n display: flex;\n align-items: center;\n ", "\n "], ["\n display: flex;\n align-items: center;\n ", "\n "])), isLeading ? 'margin-right: 5px' : 'margin-left: 5px') }, { children: jsx(Icon, { width: 1.25, height: 1.25, fill: iconFill }, void 0) }), void 0));
|
|
6336
6490
|
};
|
|
6337
6491
|
var getIconFill = function (theme, disabled, iconColor) {
|
|
6338
6492
|
if (disabled)
|
|
@@ -6348,16 +6502,16 @@ var TextButton = function (_a) {
|
|
|
6348
6502
|
var iconFill = getIconFill(theme, disabled, iconColor);
|
|
6349
6503
|
return (jsx(BaseButton, __assign({ renderLeading: withContainer(iconFill, true, LeadingIcon), renderTrailing: withContainer(iconFill, false, TrailingIcon), disabled: disabled, type: type, onClick: onClick, css: textButtonStyles$1(theme, size) }, { children: text }), void 0));
|
|
6350
6504
|
};
|
|
6351
|
-
var templateObject_1$
|
|
6505
|
+
var templateObject_1$U;
|
|
6352
6506
|
|
|
6353
|
-
var Container$A = newStyled.div(templateObject_1$
|
|
6354
|
-
var P$2 = newStyled.p(templateObject_2$
|
|
6355
|
-
var PercentageSpan = newStyled.span(templateObject_3$
|
|
6507
|
+
var Container$A = newStyled.div(templateObject_1$T || (templateObject_1$T = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n font-size: 0.88rem;\n"], ["\n display: flex;\n justify-content: space-between;\n font-size: 0.88rem;\n"])));
|
|
6508
|
+
var P$2 = newStyled.p(templateObject_2$A || (templateObject_2$A = __makeTemplateObject(["\n margin: 0;\n"], ["\n margin: 0;\n"])));
|
|
6509
|
+
var PercentageSpan = newStyled.span(templateObject_3$m || (templateObject_3$m = __makeTemplateObject(["\n font-weight: 700;\n text-decoration-line: underline;\n"], ["\n font-weight: 700;\n text-decoration-line: underline;\n"])));
|
|
6356
6510
|
var SizeFitGuide = function (_a) {
|
|
6357
6511
|
var title = _a.title, fitPercentageLabel = _a.fitPercentageLabel, fitPercentage = _a.fitPercentage, onClick = _a.onClick;
|
|
6358
6512
|
return (jsxs$1(Container$A, { children: [jsx$1(TextButton, { LeadingIcon: Icon.PDP.Rule, size: ComponentSize.Small, text: title, onClick: onClick }, void 0), jsxs$1(P$2, { children: [fitPercentageLabel, " ", jsxs$1(PercentageSpan, { children: [fitPercentage, "%"] }, void 0)] }, void 0)] }, void 0));
|
|
6359
6513
|
};
|
|
6360
|
-
var templateObject_1$
|
|
6514
|
+
var templateObject_1$T, templateObject_2$A, templateObject_3$m;
|
|
6361
6515
|
|
|
6362
6516
|
var getStylesBySize$6 = function (size) {
|
|
6363
6517
|
switch (size) {
|
|
@@ -6387,7 +6541,7 @@ var getStylesBySize$6 = function (size) {
|
|
|
6387
6541
|
};
|
|
6388
6542
|
}
|
|
6389
6543
|
};
|
|
6390
|
-
var Container$z = newStyled.div(templateObject_1$
|
|
6544
|
+
var Container$z = newStyled.div(templateObject_1$S || (templateObject_1$S = __makeTemplateObject(["\n background-color: ", ";\n border: 1px solid ", ";\n border-radius: ", ";\n padding: ", ";\n display: inline-flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n width: ", ";\n height: ", ";\n text-align: center;\n cursor: default;\n"], ["\n background-color: ", ";\n border: 1px solid ", ";\n border-radius: ", ";\n padding: ", ";\n display: inline-flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n width: ", ";\n height: ", ";\n text-align: center;\n cursor: default;\n"])), function (_a) {
|
|
6391
6545
|
var backgroundColor = _a.backgroundColor;
|
|
6392
6546
|
return backgroundColor;
|
|
6393
6547
|
}, function (_a) {
|
|
@@ -6409,7 +6563,7 @@ var Container$z = newStyled.div(templateObject_1$T || (templateObject_1$T = __ma
|
|
|
6409
6563
|
var size = _a.size;
|
|
6410
6564
|
return (_b = getStylesBySize$6(size)) === null || _b === void 0 ? void 0 : _b.height;
|
|
6411
6565
|
});
|
|
6412
|
-
var H3$2 = newStyled.h3(templateObject_2$
|
|
6566
|
+
var H3$2 = newStyled.h3(templateObject_2$z || (templateObject_2$z = __makeTemplateObject(["\n color: ", ";\n font-weight: bold;\n margin: 0;\n font-size: ", ";\n line-height: ", ";\n"], ["\n color: ", ";\n font-weight: bold;\n margin: 0;\n font-size: ", ";\n line-height: ", ";\n"])), function (_a) {
|
|
6413
6567
|
var textColor = _a.textColor;
|
|
6414
6568
|
return textColor;
|
|
6415
6569
|
}, function (_a) {
|
|
@@ -6426,7 +6580,7 @@ var DiscountTag = function (_a) {
|
|
|
6426
6580
|
var theme = useTheme();
|
|
6427
6581
|
return (jsx$1(Container$z, __assign({ backgroundColor: disabled ? theme.colors.shades['50'].color : backgroundColor, borderColor: disabled ? theme.colors.shades['50'].color : borderColor, size: size, "data-testid": "discount-container" }, { children: jsxs$1(H3$2, __assign({ textColor: disabled ? theme.colors.shades['250'].color : textColor, size: size }, { children: [discount, "% ", offText] }), void 0) }), void 0));
|
|
6428
6582
|
};
|
|
6429
|
-
var templateObject_1$
|
|
6583
|
+
var templateObject_1$S, templateObject_2$z;
|
|
6430
6584
|
|
|
6431
6585
|
var getStylesBySize$5 = function (size) {
|
|
6432
6586
|
switch (size) {
|
|
@@ -6450,8 +6604,8 @@ var getStylesBySize$5 = function (size) {
|
|
|
6450
6604
|
};
|
|
6451
6605
|
}
|
|
6452
6606
|
};
|
|
6453
|
-
var Container$y = newStyled.div(templateObject_1$
|
|
6454
|
-
var Price = newStyled.h1(templateObject_2$
|
|
6607
|
+
var Container$y = newStyled.div(templateObject_1$R || (templateObject_1$R = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
|
|
6608
|
+
var Price = newStyled.h1(templateObject_2$y || (templateObject_2$y = __makeTemplateObject(["\n font-weight: ", ";\n font-size: ", ";\n line-height: ", ";\n color: ", ";\n text-decoration: ", ";\n margin: ", ";\n"], ["\n font-weight: ", ";\n font-size: ", ";\n line-height: ", ";\n color: ", ";\n text-decoration: ", ";\n margin: ", ";\n"])), function (_a) {
|
|
6455
6609
|
var weight = _a.weight;
|
|
6456
6610
|
return (weight ? weight : '400');
|
|
6457
6611
|
}, function (_a) {
|
|
@@ -6473,7 +6627,7 @@ var Price = newStyled.h1(templateObject_2$z || (templateObject_2$z = __makeTempl
|
|
|
6473
6627
|
var margin = _a.margin, size = _a.size;
|
|
6474
6628
|
return (margin ? (_b = getStylesBySize$5(size)) === null || _b === void 0 ? void 0 : _b.margin : '0');
|
|
6475
6629
|
});
|
|
6476
|
-
var TagContainer = newStyled.h1(templateObject_3$
|
|
6630
|
+
var TagContainer = newStyled.h1(templateObject_3$l || (templateObject_3$l = __makeTemplateObject(["\n margin: ", ";\n display: flex;\n align-items: center;\n"], ["\n margin: ", ";\n display: flex;\n align-items: center;\n"])), function (_a) {
|
|
6477
6631
|
var _b;
|
|
6478
6632
|
var size = _a.size;
|
|
6479
6633
|
return (_b = getStylesBySize$5(size)) === null || _b === void 0 ? void 0 : _b.margin;
|
|
@@ -6483,7 +6637,7 @@ var PriceLabel = function (_a) {
|
|
|
6483
6637
|
var theme = useTheme();
|
|
6484
6638
|
return (jsxs$1(Container$y, { children: [jsx$1(Price, __assign({ size: size, color: color || theme.colors.pallete.secondary.color, weight: 700, "data-testid": "price" }, { children: finalPrice }), void 0), originalPrice && (jsx$1(Price, __assign({ size: size, color: theme.colors.shades['400'].color, margin: true, underlined: true, "data-testid": "discount" }, { children: originalPrice }), void 0)), discount && (jsx$1(TagContainer, __assign({ size: size }, { children: jsx$1(DiscountTag, __assign({}, discount, { size: size }), void 0) }), void 0))] }, void 0));
|
|
6485
6639
|
};
|
|
6486
|
-
var templateObject_1$
|
|
6640
|
+
var templateObject_1$R, templateObject_2$y, templateObject_3$l;
|
|
6487
6641
|
|
|
6488
6642
|
var OneColorSelector = function (_a) {
|
|
6489
6643
|
var color = _a.color, selected = _a.selected, dataTestId = _a.dataTestId;
|
|
@@ -6522,69 +6676,55 @@ var OutOfStock = function (_a) {
|
|
|
6522
6676
|
return (jsxs$1("svg", __assign({ width: "32", height: "33", viewBox: "0 0 32 33", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [jsx$1("title", { children: title }, void 0), jsx$1("mask", __assign({ id: "path-1-inside-1", fill: "white" }, { children: jsx$1("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M8.89435 9.60565C8.40619 10.0938 8.40619 10.8853 8.89435 11.3734L14.0209 16.5L8.89433 21.6266C8.40617 22.1147 8.40617 22.9062 8.89433 23.3943C9.38248 23.8825 10.1739 23.8825 10.6621 23.3943L15.7887 18.2677L21.2687 23.7478C21.7569 24.2359 22.5483 24.2359 23.0365 23.7478C23.5246 23.2596 23.5246 22.4682 23.0365 21.98L17.5564 16.5L23.0365 11.02C23.5246 10.5318 23.5246 9.74035 23.0365 9.25219C22.5483 8.76404 21.7568 8.76404 21.2687 9.25219L15.7887 14.7322L10.6621 9.60565C10.174 9.1175 9.3825 9.1175 8.89435 9.60565Z" }, void 0) }), void 0), jsx$1("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M8.89435 9.60565C8.40619 10.0938 8.40619 10.8853 8.89435 11.3734L14.0209 16.5L8.89433 21.6266C8.40617 22.1147 8.40617 22.9062 8.89433 23.3943C9.38248 23.8825 10.1739 23.8825 10.6621 23.3943L15.7887 18.2677L21.2687 23.7478C21.7569 24.2359 22.5483 24.2359 23.0365 23.7478C23.5246 23.2596 23.5246 22.4682 23.0365 21.98L17.5564 16.5L23.0365 11.02C23.5246 10.5318 23.5246 9.74035 23.0365 9.25219C22.5483 8.76404 21.7568 8.76404 21.2687 9.25219L15.7887 14.7322L10.6621 9.60565C10.174 9.1175 9.3825 9.1175 8.89435 9.60565Z", fill: theme.colors.shades['300'].color }, void 0), jsx$1("path", { d: "M14.0209 16.5L14.5866 17.0657L15.1523 16.5L14.5866 15.9343L14.0209 16.5ZM8.89433 21.6266L9.46001 22.1922L8.89433 21.6266ZM10.6621 23.3943L11.2278 23.96L10.6621 23.3943ZM15.7887 18.2677L16.3544 17.7021L15.7887 17.1364L15.223 17.7021L15.7887 18.2677ZM17.5564 16.5L16.9908 15.9343L16.4251 16.5L16.9908 17.0657L17.5564 16.5ZM23.0365 11.02L23.6021 11.5856L23.0365 11.02ZM21.2687 9.25219L21.8344 9.81788L21.2687 9.25219ZM15.7887 14.7322L15.223 15.2979L15.7887 15.8636L16.3544 15.2979L15.7887 14.7322ZM9.46003 10.8077C9.2843 10.632 9.2843 10.3471 9.46003 10.1713L8.32866 9.03997C7.52809 9.84054 7.52809 11.1385 8.32866 11.9391L9.46003 10.8077ZM14.5866 15.9343L9.46003 10.8077L8.32866 11.9391L13.4552 17.0657L14.5866 15.9343ZM9.46001 22.1922L14.5866 17.0657L13.4552 15.9343L8.32864 21.0609L9.46001 22.1922ZM9.46001 22.8286C9.28428 22.6529 9.28428 22.368 9.46001 22.1922L8.32864 21.0609C7.52807 21.8614 7.52807 23.1594 8.32864 23.96L9.46001 22.8286ZM10.0964 22.8286C9.92067 23.0044 9.63575 23.0044 9.46001 22.8286L8.32864 23.96C9.12922 24.7606 10.4272 24.7606 11.2278 23.96L10.0964 22.8286ZM15.223 17.7021L10.0964 22.8286L11.2278 23.96L16.3544 18.8334L15.223 17.7021ZM21.8344 23.1821L16.3544 17.7021L15.223 18.8334L20.703 24.3135L21.8344 23.1821ZM22.4708 23.1821C22.2951 23.3578 22.0101 23.3578 21.8344 23.1821L20.703 24.3135C21.5036 25.114 22.8016 25.114 23.6022 24.3135L22.4708 23.1821ZM22.4708 22.5457C22.6465 22.7214 22.6465 23.0064 22.4708 23.1821L23.6022 24.3135C24.4027 23.5129 24.4027 22.2149 23.6022 21.4143L22.4708 22.5457ZM16.9908 17.0657L22.4708 22.5457L23.6022 21.4143L18.1221 15.9343L16.9908 17.0657ZM22.4708 10.4543L16.9908 15.9343L18.1221 17.0657L23.6021 11.5856L22.4708 10.4543ZM22.4708 9.81788C22.6465 9.99361 22.6465 10.2785 22.4708 10.4543L23.6021 11.5856C24.4027 10.7851 24.4027 9.48708 23.6021 8.68651L22.4708 9.81788ZM21.8344 9.81788C22.0101 9.64214 22.295 9.64214 22.4708 9.81788L23.6021 8.68651C22.8016 7.88593 21.5036 7.88593 20.703 8.68651L21.8344 9.81788ZM16.3544 15.2979L21.8344 9.81788L20.703 8.68651L15.223 14.1665L16.3544 15.2979ZM10.0964 10.1713L15.223 15.2979L16.3544 14.1665L11.2278 9.03997L10.0964 10.1713ZM9.46003 10.1713C9.63577 9.9956 9.92069 9.9956 10.0964 10.1713L11.2278 9.03997C10.4272 8.23939 9.12924 8.23939 8.32866 9.03997L9.46003 10.1713Z", fill: "white", mask: "url(#path-1-inside-1)" }, void 0), jsx$1("circle", { cx: "16", cy: "16.5", r: "12", stroke: theme.colors.shades['300'].color, strokeWidth: "0.5" }, void 0)] }), void 0));
|
|
6523
6677
|
};
|
|
6524
6678
|
|
|
6525
|
-
var CustomRadioGroup = newStyled(RadioGroup)(templateObject_1$
|
|
6526
|
-
|
|
6527
|
-
var CustomRadioGroupOption = newStyled(RadioGroup.Option)(templateObject_3$
|
|
6528
|
-
var Span = newStyled.span(templateObject_4$
|
|
6529
|
-
var OptionsContainer = newStyled.div(templateObject_5$
|
|
6679
|
+
var CustomRadioGroup = newStyled(RadioGroup)(templateObject_1$Q || (templateObject_1$Q = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n"], ["\n display: flex;\n flex-direction: column;\n"])));
|
|
6680
|
+
newStyled(RadioGroup.Label)(templateObject_2$x || (templateObject_2$x = __makeTemplateObject(["\n font-size: 0.88rem;\n"], ["\n font-size: 0.88rem;\n"])));
|
|
6681
|
+
var CustomRadioGroupOption = newStyled(RadioGroup.Option)(templateObject_3$k || (templateObject_3$k = __makeTemplateObject(["\n margin-right: 1rem;\n\n svg {\n cursor: pointer;\n }\n"], ["\n margin-right: 1rem;\n\n svg {\n cursor: pointer;\n }\n"])));
|
|
6682
|
+
var Span = newStyled.span(templateObject_4$b || (templateObject_4$b = __makeTemplateObject(["\n font-weight: 600;\n"], ["\n font-weight: 600;\n"])));
|
|
6683
|
+
var OptionsContainer = newStyled.div(templateObject_5$6 || (templateObject_5$6 = __makeTemplateObject(["\n display: flex;\n margin-top: 0.63rem;\n flex-wrap: wrap;\n"], ["\n display: flex;\n margin-top: 0.63rem;\n flex-wrap: wrap;\n"])));
|
|
6530
6684
|
var Label$1 = function (_a) {
|
|
6531
6685
|
var label = _a.label, values = _a.values;
|
|
6532
|
-
return (jsxs$1(
|
|
6686
|
+
return (jsxs$1(Text$3, __assign({ variant: "body", weight: "regular", size: "small" }, { children: [label, " ", jsx$1(Span, { children: values }, void 0)] }), void 0));
|
|
6533
6687
|
};
|
|
6534
6688
|
var Option = function (_a) {
|
|
6535
6689
|
var value = _a.value, children = _a.children;
|
|
6536
6690
|
return (jsx$1(CustomRadioGroupOption, __assign({ value: value }, { children: children }), void 0));
|
|
6537
6691
|
};
|
|
6538
6692
|
var ColorRadioGroup = function (_a) {
|
|
6539
|
-
var value = _a.value, onChange = _a.onChange, children = _a.children;
|
|
6540
|
-
return (jsx$1(CustomRadioGroup, __assign({ value: value, onChange: onChange }, { children: children }), void 0));
|
|
6693
|
+
var value = _a.value, onChange = _a.onChange, children = _a.children, className = _a.className;
|
|
6694
|
+
return (jsx$1(CustomRadioGroup, __assign({ value: value, onChange: onChange, className: className }, { children: children }), void 0));
|
|
6541
6695
|
};
|
|
6542
6696
|
var ColorRadioGroup$1 = Object.assign(ColorRadioGroup, {
|
|
6543
6697
|
Label: Label$1,
|
|
6544
6698
|
Option: Option,
|
|
6545
6699
|
OptionsContainer: OptionsContainer,
|
|
6546
6700
|
});
|
|
6547
|
-
var templateObject_1$
|
|
6701
|
+
var templateObject_1$Q, templateObject_2$x, templateObject_3$k, templateObject_4$b, templateObject_5$6;
|
|
6548
6702
|
|
|
6549
|
-
var Container$x = newStyled.div(templateObject_1$
|
|
6703
|
+
var Container$x = newStyled.div(templateObject_1$P || (templateObject_1$P = __makeTemplateObject(["\n width: 2rem;\n height: 2rem;\n border-radius: 50%;\n border: 0.081rem solid ", ";\n box-sizing: border-box;\n padding: 0.156rem;\n cursor: pointer;\n"], ["\n width: 2rem;\n height: 2rem;\n border-radius: 50%;\n border: 0.081rem solid ", ";\n box-sizing: border-box;\n padding: 0.156rem;\n cursor: pointer;\n"])), function (_a) {
|
|
6550
6704
|
var borderColor = _a.borderColor;
|
|
6551
6705
|
return borderColor;
|
|
6552
6706
|
});
|
|
6553
|
-
var Image$
|
|
6707
|
+
var Image$2 = newStyled.img(templateObject_2$w || (templateObject_2$w = __makeTemplateObject(["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n"], ["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n"])));
|
|
6554
6708
|
var PatternSelector = function (_a) {
|
|
6555
6709
|
var url = _a.url, selected = _a.selected, dataTestId = _a.dataTestId;
|
|
6556
6710
|
var theme = useTheme();
|
|
6557
6711
|
var outerBorder = selected ? theme.colors.shades['550'].color : 'transparent';
|
|
6558
|
-
return (jsx$1(Container$x, __assign({ "data-testid": dataTestId, borderColor: outerBorder }, { children: jsx$1(Image$
|
|
6712
|
+
return (jsx$1(Container$x, __assign({ "data-testid": dataTestId, borderColor: outerBorder }, { children: jsx$1(Image$2, { src: url, alt: "pattern" }, void 0) }), void 0));
|
|
6559
6713
|
};
|
|
6560
|
-
var templateObject_1$
|
|
6714
|
+
var templateObject_1$P, templateObject_2$w;
|
|
6561
6715
|
|
|
6562
6716
|
var renderOptions$1 = function (options) {
|
|
6563
6717
|
if (options.length)
|
|
6564
|
-
return options.map(function (option) { return (jsx
|
|
6718
|
+
return options.map(function (option) { return (jsx(ColorRadioGroup$1.Option, __assign({ value: option }, { children: function (_a) {
|
|
6565
6719
|
var checked = _a.checked;
|
|
6566
|
-
return option.color ? (jsx
|
|
6720
|
+
return option.color ? (jsx(ColorSelector, __assign({}, option.color, { selected: checked, dataTestId: "".concat(option.label, "-selector") }), void 0)) : (option.pattern && jsx(PatternSelector, { url: option.pattern.url, selected: checked }, void 0));
|
|
6567
6721
|
} }), option.label)); });
|
|
6568
6722
|
else
|
|
6569
|
-
return jsx
|
|
6570
|
-
};
|
|
6571
|
-
var getInitialValue$1 = function (options, selectedValue) {
|
|
6572
|
-
if (selectedValue && options.includes(selectedValue))
|
|
6573
|
-
return selectedValue;
|
|
6574
|
-
else if (selectedValue)
|
|
6575
|
-
return options[0];
|
|
6576
|
-
else
|
|
6577
|
-
;
|
|
6723
|
+
return jsx(OutOfStock, { title: "out of stock color" }, void 0);
|
|
6578
6724
|
};
|
|
6579
6725
|
var SingleColorPicker = function (_a) {
|
|
6580
|
-
var options = _a.options, selectedValue = _a.selectedValue, label = _a.label, onChange = _a.onChange;
|
|
6581
|
-
|
|
6582
|
-
var _b = useState(initialValue), selectedColor = _b[0], setSelectedColor = _b[1];
|
|
6583
|
-
var onChangeHandler = function (selectedOption) {
|
|
6584
|
-
setSelectedColor(selectedOption);
|
|
6585
|
-
onChange(selectedOption);
|
|
6586
|
-
};
|
|
6587
|
-
return (jsxs$1(ColorRadioGroup$1, __assign({ value: selectedColor, onChange: onChangeHandler }, { children: [jsx$1(ColorRadioGroup$1.Label, { label: label, values: selectedColor && selectedColor.label }, void 0), jsx$1(ColorRadioGroup$1.OptionsContainer, { children: renderOptions$1(options) }, void 0)] }), void 0));
|
|
6726
|
+
var options = _a.options, selectedValue = _a.selectedValue, label = _a.label, onChange = _a.onChange, _b = _a.inline, inline = _b === void 0 ? false : _b;
|
|
6727
|
+
return (jsxs(ColorRadioGroup$1, __assign({ value: selectedValue, onChange: onChange, css: { flexDirection: inline ? 'row' : 'column', alignItems: inline ? 'center' : 'start' } }, { children: [jsx(ColorRadioGroup$1.Label, { label: label, values: selectedValue && !inline ? selectedValue.label : undefined }, void 0), jsx(ColorRadioGroup$1.OptionsContainer, __assign({ css: { marginTop: inline ? '0' : '0.63rem', marginLeft: inline ? '1.5rem' : '0' }, "data-testid": "radio-group-options-container" }, { children: renderOptions$1(options) }), void 0)] }), void 0));
|
|
6588
6728
|
};
|
|
6589
6729
|
|
|
6590
6730
|
var renderOptions = function (selectedColor, options) {
|
|
@@ -6623,38 +6763,44 @@ var MultiColorPicker = function (_a) {
|
|
|
6623
6763
|
return (jsxs$1(ColorRadioGroup$1, __assign({ value: selectedColor, onChange: onChangeHandler }, { children: [jsx$1(ColorRadioGroup$1.Label, { label: label, values: valueLabels }, void 0), jsx$1(ColorRadioGroup$1.OptionsContainer, { children: renderOptions(selectedColor, options) }, void 0)] }), void 0));
|
|
6624
6764
|
};
|
|
6625
6765
|
|
|
6626
|
-
var Image$
|
|
6766
|
+
var Image$1 = newStyled.img(templateObject_1$O || (templateObject_1$O = __makeTemplateObject(["\n width: 4.063rem;\n height: 5.375rem;\n box-sizing: border-box;\n cursor: pointer;\n border: ", ";\n"], ["\n width: 4.063rem;\n height: 5.375rem;\n box-sizing: border-box;\n cursor: pointer;\n border: ", ";\n"])), function (_a) {
|
|
6627
6767
|
var selected = _a.selected, theme = _a.theme;
|
|
6628
6768
|
return selected ? "0.063rem solid ".concat(theme.colors.shades['700'].color) : 'inherit';
|
|
6629
6769
|
});
|
|
6630
6770
|
var ImageSmallPreview = function (_a) {
|
|
6631
6771
|
var imageUrl = _a.imageUrl, alt = _a.alt, _b = _a.selected, selected = _b === void 0 ? false : _b, className = _a.className;
|
|
6632
6772
|
var theme = useTheme();
|
|
6633
|
-
return jsx$1(Image$
|
|
6773
|
+
return jsx$1(Image$1, { className: className, src: imageUrl, alt: alt, selected: selected, theme: theme }, void 0);
|
|
6634
6774
|
};
|
|
6635
|
-
var templateObject_1$
|
|
6775
|
+
var templateObject_1$O;
|
|
6636
6776
|
|
|
6637
|
-
var Container$w = newStyled.div(templateObject_1$
|
|
6638
|
-
var Button$
|
|
6777
|
+
var Container$w = newStyled.div(templateObject_1$N || (templateObject_1$N = __makeTemplateObject(["\n grid-row-gap: 20px;\n display: grid;\n max-height: 45rem;\n height: min-content;\n overflow: auto;\n align-items: flex-start;\n"], ["\n grid-row-gap: 20px;\n display: grid;\n max-height: 45rem;\n height: min-content;\n overflow: auto;\n align-items: flex-start;\n"])));
|
|
6778
|
+
var Button$5 = newStyled.button(templateObject_2$v || (templateObject_2$v = __makeTemplateObject(["\n padding: 0;\n border: none;\n text-decoration: none;\n background: transparent;\n"], ["\n padding: 0;\n border: none;\n text-decoration: none;\n background: transparent;\n"])));
|
|
6639
6779
|
var ImagePreviewList = function (_a) {
|
|
6640
6780
|
var images = _a.images, selectedImage = _a.selectedImage, onClick = _a.onClick, dataTestId = _a.dataTestId;
|
|
6641
|
-
return (jsx(Container$w, __assign({ "data-testid": dataTestId }, { children: images.map(function (item) {
|
|
6642
|
-
return (jsx(Button$
|
|
6781
|
+
return (jsx$1(Container$w, __assign({ "data-testid": dataTestId }, { children: images.map(function (item) {
|
|
6782
|
+
return (jsx$1(Button$5, __assign({ onClick: function () { return onClick(item); } }, { children: jsx$1(ImageSmallPreview, { imageUrl: item.imageUrl, alt: item.alt, selected: item.key === selectedImage.key }, void 0) }), item.key));
|
|
6643
6783
|
}) }), void 0));
|
|
6644
6784
|
};
|
|
6645
|
-
var templateObject_1$
|
|
6785
|
+
var templateObject_1$N, templateObject_2$v;
|
|
6646
6786
|
|
|
6647
|
-
var
|
|
6648
|
-
var Image
|
|
6649
|
-
var
|
|
6650
|
-
|
|
6787
|
+
var Img = newStyled.img(templateObject_1$M || (templateObject_1$M = __makeTemplateObject(["\n height: ", ";\n width: ", ";\n border-radius: ", ";\n object-fit: ", ";\n object-position: ", ";\n"], ["\n height: ", ";\n width: ", ";\n border-radius: ", ";\n object-fit: ", ";\n object-position: ", ";\n"])), function (props) { return props.height; }, function (props) { return props.width; }, function (props) { return props.borderRadius; }, function (props) { return props.objectFit; }, function (props) { return props.objectPosition; });
|
|
6788
|
+
var Image = function (_a) {
|
|
6789
|
+
var src = _a.src, alt = _a.alt, height = _a.height, width = _a.width, borderRadius = _a.borderRadius, objectFit = _a.objectFit, objectPosition = _a.objectPosition, className = _a.className;
|
|
6790
|
+
return (jsx$1(Img, { src: src, alt: alt, height: height, width: width, borderRadius: borderRadius, objectFit: objectFit, objectPosition: objectPosition, className: className }, void 0));
|
|
6791
|
+
};
|
|
6792
|
+
var templateObject_1$M;
|
|
6793
|
+
|
|
6794
|
+
var Container$v = newStyled.div(templateObject_1$L || (templateObject_1$L = __makeTemplateObject(["\n position: relative;\n height: 45rem;\n"], ["\n position: relative;\n height: 45rem;\n"])));
|
|
6795
|
+
var TopTagContainer$1 = newStyled.div(templateObject_2$u || (templateObject_2$u = __makeTemplateObject(["\n position: absolute;\n left: 0;\n top: 0;\n"], ["\n position: absolute;\n left: 0;\n top: 0;\n"])));
|
|
6796
|
+
var BottomTagContainer$1 = newStyled.div(templateObject_3$j || (templateObject_3$j = __makeTemplateObject(["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"], ["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"])));
|
|
6651
6797
|
var ImageProductWithTags$1 = function (_a) {
|
|
6652
6798
|
var image = _a.image, DiscountTagElement = _a.DiscountTagElement, BestSellerTagElement = _a.BestSellerTagElement, dataTestId = _a.dataTestId;
|
|
6653
|
-
return (jsxs$1(Container$v, __assign({ "data-testid": dataTestId }, { children: [jsx$1(Image
|
|
6799
|
+
return (jsxs$1(Container$v, __assign({ "data-testid": dataTestId }, { children: [jsx$1(Image, { src: image.imageUrl, alt: image.alt, objectFit: "cover", objectPosition: "center", width: "530px", height: "720px" }, void 0), jsx$1(TopTagContainer$1, { children: DiscountTagElement }, void 0), jsx$1(BottomTagContainer$1, { children: BestSellerTagElement }, void 0)] }), void 0));
|
|
6654
6800
|
};
|
|
6655
|
-
var templateObject_1$
|
|
6801
|
+
var templateObject_1$L, templateObject_2$u, templateObject_3$j;
|
|
6656
6802
|
|
|
6657
|
-
var Container$u = newStyled.div(templateObject_1$
|
|
6803
|
+
var Container$u = newStyled.div(templateObject_1$K || (templateObject_1$K = __makeTemplateObject(["\n display: grid;\n grid-template-columns: auto auto;\n grid-column-gap: 20px;\n max-height: 45rem;\n width: fit-content;\n"], ["\n display: grid;\n grid-template-columns: auto auto;\n grid-column-gap: 20px;\n max-height: 45rem;\n width: fit-content;\n"])));
|
|
6658
6804
|
var ProductGallery = function (_a) {
|
|
6659
6805
|
var images = _a.images, selectedValue = _a.selectedValue, DiscountTagElement = _a.DiscountTagElement, BestSellerTagElement = _a.BestSellerTagElement, productImageDataTestId = _a.productImageDataTestId, previewListDataTestId = _a.previewListDataTestId;
|
|
6660
6806
|
var initialValue = selectedValue && images.includes(selectedValue) ? selectedValue : images[0];
|
|
@@ -6666,7 +6812,7 @@ var ProductGallery = function (_a) {
|
|
|
6666
6812
|
setSelectedImage(value);
|
|
6667
6813
|
} }, void 0), jsx$1(ImageProductWithTags$1, { image: selectedImage, DiscountTagElement: DiscountTagElement, BestSellerTagElement: BestSellerTagElement, dataTestId: productImageDataTestId }, void 0)] }, void 0));
|
|
6668
6814
|
};
|
|
6669
|
-
var templateObject_1$
|
|
6815
|
+
var templateObject_1$K;
|
|
6670
6816
|
|
|
6671
6817
|
/* base styles & size variants */
|
|
6672
6818
|
var StarStyles = {
|
|
@@ -6704,8 +6850,8 @@ var StarStyles = {
|
|
|
6704
6850
|
});
|
|
6705
6851
|
},
|
|
6706
6852
|
};
|
|
6707
|
-
var Container$t = newStyled.div(templateObject_1$
|
|
6708
|
-
var templateObject_1$
|
|
6853
|
+
var Container$t = newStyled.div(templateObject_1$J || (templateObject_1$J = __makeTemplateObject(["\n display: flex;\n"], ["\n display: flex;\n"])));
|
|
6854
|
+
var templateObject_1$J;
|
|
6709
6855
|
|
|
6710
6856
|
var StarContainer = newStyled.div(function (_a) {
|
|
6711
6857
|
var size = _a.size;
|
|
@@ -6760,8 +6906,8 @@ var LabelStyles = {
|
|
|
6760
6906
|
});
|
|
6761
6907
|
},
|
|
6762
6908
|
};
|
|
6763
|
-
var Container$s = newStyled.div(templateObject_1$
|
|
6764
|
-
var templateObject_1$
|
|
6909
|
+
var Container$s = newStyled.div(templateObject_1$I || (templateObject_1$I = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
|
|
6910
|
+
var templateObject_1$I;
|
|
6765
6911
|
|
|
6766
6912
|
var CustomLabel = newStyled.div(function (_a) {
|
|
6767
6913
|
var theme = _a.theme, size = _a.size;
|
|
@@ -6777,8 +6923,8 @@ var Rating = function (_a) {
|
|
|
6777
6923
|
return (jsxs$1(Container$s, { children: [jsx$1(StarList, { rating: rating, size: size, starsNumber: starsNumber, fill: theme.colors.pallete.primary.color }, void 0), jsxs$1(CustomLabel, __assign({ theme: theme, size: size, "data-testid": "CustomLabel" }, { children: [reviews, " ", reviewsText] }), void 0)] }, void 0));
|
|
6778
6924
|
};
|
|
6779
6925
|
|
|
6780
|
-
var Container$r = newStyled.div(templateObject_1$
|
|
6781
|
-
var P$1 = newStyled.p(templateObject_2$
|
|
6926
|
+
var Container$r = newStyled.div(templateObject_1$H || (templateObject_1$H = __makeTemplateObject(["\n display: flex;\n align-items: center;\n font-size: 0.88rem;\n"], ["\n display: flex;\n align-items: center;\n font-size: 0.88rem;\n"])));
|
|
6927
|
+
var P$1 = newStyled.p(templateObject_2$t || (templateObject_2$t = __makeTemplateObject(["\n margin: 0 0.25rem;\n font-weight: 700;\n color: ", ";\n"], ["\n margin: 0 0.25rem;\n font-weight: 700;\n color: ", ";\n"])), function (props) { return props.theme.colors.shades['550'].color; });
|
|
6782
6928
|
var textButtonStyles = function (theme) { return ({
|
|
6783
6929
|
border: 'none',
|
|
6784
6930
|
background: 'transparent',
|
|
@@ -6793,7 +6939,7 @@ var FitPredictor = function (_a) {
|
|
|
6793
6939
|
var theme = useTheme();
|
|
6794
6940
|
return (jsxs(Container$r, __assign({ theme: theme }, { children: [jsx(Container$r, { children: jsx(Icon.Other.FitPredictor, { width: 1.125, height: 1.125, fill: theme.colors.shades['550'].color }, void 0) }, void 0), jsx(P$1, __assign({ theme: theme }, { children: "FIT PREDICTOR" }), void 0), jsx(BaseButton, __assign({ css: textButtonStyles(theme), onClick: onClick }, { children: "Calculate your size" }), void 0)] }), void 0));
|
|
6795
6941
|
};
|
|
6796
|
-
var templateObject_1$
|
|
6942
|
+
var templateObject_1$H, templateObject_2$t;
|
|
6797
6943
|
|
|
6798
6944
|
var H2$1 = newStyled.h2(function (_a) {
|
|
6799
6945
|
var color = _a.color;
|
|
@@ -6807,7 +6953,7 @@ var H2$1 = newStyled.h2(function (_a) {
|
|
|
6807
6953
|
margin: '0.938rem 4.188rem',
|
|
6808
6954
|
});
|
|
6809
6955
|
});
|
|
6810
|
-
var Bar = newStyled.div(templateObject_1$
|
|
6956
|
+
var Bar = newStyled.div(templateObject_1$G || (templateObject_1$G = __makeTemplateObject(["\n @keyframes loading {\n 0% {\n transform: translateX(0);\n }\n to {\n transform: translateX(400%);\n }\n }\n\n height: 0.5rem;\n background-color: ", ";\n width: ", ";\n border-radius: 0.25rem;\n position: absolute;\n left: ", ";\n animation: ", ";\n"], ["\n @keyframes loading {\n 0% {\n transform: translateX(0);\n }\n to {\n transform: translateX(400%);\n }\n }\n\n height: 0.5rem;\n background-color: ", ";\n width: ", ";\n border-radius: 0.25rem;\n position: absolute;\n left: ", ";\n animation: ", ";\n"])), function (_a) {
|
|
6811
6957
|
var backgroundColor = _a.backgroundColor;
|
|
6812
6958
|
return backgroundColor;
|
|
6813
6959
|
}, function (_a) {
|
|
@@ -6846,7 +6992,7 @@ var ProgressBar = function (_a) {
|
|
|
6846
6992
|
var theme = useTheme();
|
|
6847
6993
|
return (jsxs$1(Container$q, __assign({ "data-testid": "PBContainer", widthAuto: widthAuto }, { children: [jsx$1(Background, __assign({ backgroundColor: theme.colors.shades['100'].color }, { children: jsx$1(Bar, { "data-testid": "PBBar", backgroundColor: fillColor, percent: percent }, void 0) }), void 0), description && jsx$1(H2$1, __assign({ color: theme.colors.pallete.secondary.color }, { children: description }), void 0)] }), void 0));
|
|
6848
6994
|
};
|
|
6849
|
-
var templateObject_1$
|
|
6995
|
+
var templateObject_1$G;
|
|
6850
6996
|
|
|
6851
6997
|
var getStylesBySize$4 = function (size) {
|
|
6852
6998
|
switch (size) {
|
|
@@ -6867,7 +7013,7 @@ var getStylesBySize$4 = function (size) {
|
|
|
6867
7013
|
};
|
|
6868
7014
|
}
|
|
6869
7015
|
};
|
|
6870
|
-
var Container$p = newStyled.div(templateObject_1$
|
|
7016
|
+
var Container$p = newStyled.div(templateObject_1$F || (templateObject_1$F = __makeTemplateObject(["\n background-color: ", ";\n width: ", ";\n height: ", ";\n border-radius: 50%;\n display: flex;\n justify-content: center;\n align-items: center;\n transition: background-color 0.1s ease;\n\n svg {\n margin: ", ";\n }\n\n &:hover {\n background-color: ", ";\n cursor: pointer;\n }\n\n &.disabled {\n background-color: ", ";\n cursor: not-allowed;\n\n svg path {\n fill: ", ";\n }\n }\n"], ["\n background-color: ", ";\n width: ", ";\n height: ", ";\n border-radius: 50%;\n display: flex;\n justify-content: center;\n align-items: center;\n transition: background-color 0.1s ease;\n\n svg {\n margin: ", ";\n }\n\n &:hover {\n background-color: ", ";\n cursor: pointer;\n }\n\n &.disabled {\n background-color: ", ";\n cursor: not-allowed;\n\n svg path {\n fill: ", ";\n }\n }\n"])), function (_a) {
|
|
6871
7017
|
var backgroundColor = _a.backgroundColor;
|
|
6872
7018
|
return backgroundColor;
|
|
6873
7019
|
}, function (_a) {
|
|
@@ -6897,7 +7043,7 @@ var IconButton = function (_a) {
|
|
|
6897
7043
|
var theme = useTheme();
|
|
6898
7044
|
return (jsx$1(Container$p, __assign({ className: disabled ? 'disabled' : '', backgroundColor: theme.component.button.primary.active.backgroundColor, hoverBackgroundColor: theme.component.button.secondary.active.backgroundColor, disabledColor: theme.colors.shades['50'].color, disabledIconColor: theme.colors.shades['200'].color, size: size, "data-testid": "Container", onClick: disabled ? function () { } : onClick }, { children: children }), void 0));
|
|
6899
7045
|
};
|
|
6900
|
-
var templateObject_1$
|
|
7046
|
+
var templateObject_1$F;
|
|
6901
7047
|
|
|
6902
7048
|
var TooltipArrow = function (_a) {
|
|
6903
7049
|
var height = _a.height, width = _a.width, fill = _a.fill, stroke = _a.stroke;
|
|
@@ -6977,7 +7123,7 @@ var getTooltipAlignItems = function (position, align) {
|
|
|
6977
7123
|
}
|
|
6978
7124
|
};
|
|
6979
7125
|
|
|
6980
|
-
var Wrapper$5 = newStyled.div(templateObject_1$
|
|
7126
|
+
var Wrapper$5 = newStyled.div(templateObject_1$E || (templateObject_1$E = __makeTemplateObject(["\n display: flex;\n flex-direction: ", ";\n align-items: center;\n cursor: pointer;\n\n &:hover {\n .tooltip-container {\n visibility: visible;\n opacity: 1;\n }\n }\n"], ["\n display: flex;\n flex-direction: ", ";\n align-items: center;\n cursor: pointer;\n\n &:hover {\n .tooltip-container {\n visibility: visible;\n opacity: 1;\n }\n }\n"])), function (_a) {
|
|
6981
7127
|
var position = _a.position;
|
|
6982
7128
|
return getWrapperFlexDirection(position);
|
|
6983
7129
|
});
|
|
@@ -7001,11 +7147,11 @@ var TooltipContainer = newStyled.div(function (_a) {
|
|
|
7001
7147
|
var getTooltipMargin = function (actual, expected, margin) {
|
|
7002
7148
|
return actual === expected ? margin : '0';
|
|
7003
7149
|
};
|
|
7004
|
-
var ContentWrapper = newStyled.div(templateObject_2$
|
|
7150
|
+
var ContentWrapper = newStyled.div(templateObject_2$s || (templateObject_2$s = __makeTemplateObject(["\n border: 0.063rem solid ", ";\n padding: 0.563rem 0.75rem;\n border-radius: 0.5rem;\n background-color: #fff;\n"], ["\n border: 0.063rem solid ", ";\n padding: 0.563rem 0.75rem;\n border-radius: 0.5rem;\n background-color: #fff;\n"])), function (_a) {
|
|
7005
7151
|
var borderColor = _a.borderColor;
|
|
7006
7152
|
return borderColor;
|
|
7007
7153
|
});
|
|
7008
|
-
var TooltipArrowContainer = newStyled.div(templateObject_3$
|
|
7154
|
+
var TooltipArrowContainer = newStyled.div(templateObject_3$i || (templateObject_3$i = __makeTemplateObject(["\n width: 1.25rem;\n height: 0.75rem;\n display: flex;\n transform: rotate(", ");\n padding: ", ";\n margin: ", ";\n"], ["\n width: 1.25rem;\n height: 0.75rem;\n display: flex;\n transform: rotate(", ");\n padding: ", ";\n margin: ", ";\n"])), function (_a) {
|
|
7009
7155
|
var position = _a.position;
|
|
7010
7156
|
return getArrowRotation(position);
|
|
7011
7157
|
}, function (_a) {
|
|
@@ -7015,17 +7161,17 @@ var TooltipArrowContainer = newStyled.div(templateObject_3$j || (templateObject_
|
|
|
7015
7161
|
var position = _a.position;
|
|
7016
7162
|
return getArrowContainerMargin(position);
|
|
7017
7163
|
});
|
|
7018
|
-
var TooltipText = newStyled.div(templateObject_4$
|
|
7164
|
+
var TooltipText = newStyled.div(templateObject_4$a || (templateObject_4$a = __makeTemplateObject(["\n font-style: normal;\n font-weight: normal;\n font-size: 0.875rem;\n line-height: 1.125rem;\n margin: 0;\n color: ", ";\n"], ["\n font-style: normal;\n font-weight: normal;\n font-size: 0.875rem;\n line-height: 1.125rem;\n margin: 0;\n color: ", ";\n"])), function (_a) {
|
|
7019
7165
|
var color = _a.color;
|
|
7020
7166
|
return color;
|
|
7021
7167
|
});
|
|
7022
|
-
var TopSection = newStyled.div(templateObject_5$
|
|
7023
|
-
var Title$3 = newStyled.h1(templateObject_6$
|
|
7168
|
+
var TopSection = newStyled.div(templateObject_5$5 || (templateObject_5$5 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n margin-bottom: 0.688rem;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n margin-bottom: 0.688rem;\n"])));
|
|
7169
|
+
var Title$3 = newStyled.h1(templateObject_6$4 || (templateObject_6$4 = __makeTemplateObject(["\n font-size: 0.875rem;\n font-weight: 600;\n line-height: 1.375rem;\n margin: 0;\n color: ", ";\n"], ["\n font-size: 0.875rem;\n font-weight: 600;\n line-height: 1.375rem;\n margin: 0;\n color: ", ";\n"])), function (_a) {
|
|
7024
7170
|
var color = _a.color;
|
|
7025
7171
|
return color;
|
|
7026
7172
|
});
|
|
7027
|
-
var IconContainer$4 = newStyled.div(templateObject_7$
|
|
7028
|
-
var templateObject_1$
|
|
7173
|
+
var IconContainer$4 = newStyled.div(templateObject_7$2 || (templateObject_7$2 = __makeTemplateObject(["\n width: 1.375rem;\n height: 1.125rem;\n margin-right: 0.563rem;\n"], ["\n width: 1.375rem;\n height: 1.125rem;\n margin-right: 0.563rem;\n"])));
|
|
7174
|
+
var templateObject_1$E, templateObject_2$s, templateObject_3$i, templateObject_4$a, templateObject_5$5, templateObject_6$4, templateObject_7$2;
|
|
7029
7175
|
|
|
7030
7176
|
var Tooltip = function (_a) {
|
|
7031
7177
|
var children = _a.children, position = _a.position, text = _a.text, _b = _a.align, align = _b === void 0 ? 'center' : _b, onClick = _a.onClick, header = _a.header;
|
|
@@ -7176,9 +7322,9 @@ var ContainerStyles = {
|
|
|
7176
7322
|
},
|
|
7177
7323
|
};
|
|
7178
7324
|
|
|
7179
|
-
var Wrapper$4 = newStyled.div(templateObject_1$
|
|
7325
|
+
var Wrapper$4 = newStyled.div(templateObject_1$D || (templateObject_1$D = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
|
|
7180
7326
|
var Container$o = newStyled.div(__assign({}, ContainerStyles.baseStyles), function (props) { return [ContainerStyles[props.size](props.theme)]; });
|
|
7181
|
-
var Input$2 = newStyled.input(templateObject_2$
|
|
7327
|
+
var Input$2 = newStyled.input(templateObject_2$r || (templateObject_2$r = __makeTemplateObject(["\n position: absolute;\n opacity: 0;\n cursor: ", ";\n height: 100%;\n width: 100%;\n margin: 0;\n"], ["\n position: absolute;\n opacity: 0;\n cursor: ", ";\n height: 100%;\n width: 100%;\n margin: 0;\n"])), function (_a) {
|
|
7182
7328
|
var disabled = _a.disabled;
|
|
7183
7329
|
return (disabled ? 'not-allowed' : 'pointer');
|
|
7184
7330
|
});
|
|
@@ -7195,7 +7341,7 @@ var RadioInput = function (_a) {
|
|
|
7195
7341
|
};
|
|
7196
7342
|
return (jsxs$1(Wrapper$4, { children: [jsxs$1(Container$o, __assign({ theme: theme, size: size, "data-testid": "container" }, { children: [jsx$1(Input$2, { id: "".concat(name, "-").concat(id), type: "radio", name: name, value: value, checked: checked, onChange: function (e) { return (disabled ? null : handleChange(e, label)); }, disabled: disabled }, void 0), jsx$1(CustomRadio, { size: size, isChecked: checked, disabled: disabled, theme: theme, "data-testid": "custom-radio" }, void 0)] }), void 0), jsx$1(Label$2, __assign({ htmlFor: "".concat(name, "-").concat(id), "data-testid": "label", variant: "regular", size: size, disabled: disabled }, { children: label }), void 0)] }, void 0));
|
|
7197
7343
|
};
|
|
7198
|
-
var templateObject_1$
|
|
7344
|
+
var templateObject_1$D, templateObject_2$r;
|
|
7199
7345
|
|
|
7200
7346
|
var RadioGroupInput = function (_a) {
|
|
7201
7347
|
var name = _a.name, _b = _a.options, options = _b === void 0 ? [] : _b, value = _a.value, onChange = _a.onChange, _c = _a.size, size = _c === void 0 ? ComponentSize.Medium : _c, _d = _a.disabled, disabled = _d === void 0 ? false : _d;
|
|
@@ -7209,9 +7355,9 @@ var RadioGroupInput = function (_a) {
|
|
|
7209
7355
|
}) }), void 0));
|
|
7210
7356
|
};
|
|
7211
7357
|
|
|
7212
|
-
var Wrapper$3 = newStyled.div(templateObject_1$
|
|
7213
|
-
var Container$n = newStyled.div(templateObject_2$
|
|
7214
|
-
var Text$
|
|
7358
|
+
var Wrapper$3 = newStyled.div(templateObject_1$C || (templateObject_1$C = __makeTemplateObject(["\n padding: 0.625rem 1.5rem;\n"], ["\n padding: 0.625rem 1.5rem;\n"])));
|
|
7359
|
+
var Container$n = newStyled.div(templateObject_2$q || (templateObject_2$q = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n align-items: center;\n"], ["\n display: flex;\n justify-content: space-between;\n align-items: center;\n"])));
|
|
7360
|
+
var Text$2 = newStyled.h4(templateObject_3$h || (templateObject_3$h = __makeTemplateObject(["\n font-size: 0.875rem;\n line-height: 1.375rem;\n color: ", ";\n font-weight: ", ";\n margin: ", ";\n"], ["\n font-size: 0.875rem;\n line-height: 1.375rem;\n color: ", ";\n font-weight: ", ";\n margin: ", ";\n"])), function (_a) {
|
|
7215
7361
|
var color = _a.color;
|
|
7216
7362
|
return color;
|
|
7217
7363
|
}, function (_a) {
|
|
@@ -7224,32 +7370,32 @@ var Text$3 = newStyled.h4(templateObject_3$i || (templateObject_3$i = __makeTemp
|
|
|
7224
7370
|
var Minimalistic = function (_a) {
|
|
7225
7371
|
var _b = _a.backgroundColor, backgroundColor = _b === void 0 ? '#FCFAF7' : _b, _c = _a.borderColor, borderColor = _c === void 0 ? '#E7C9B2' : _c, originalPrice = _a.originalPrice, price = _a.price, savingPrice = _a.savingPrice, getMorePayLessText = _a.getMorePayLessText, youAreSavingText = _a.youAreSavingText, getQtyForText = _a.getQtyForText, discount = _a.discount, offText = _a.offText, _d = _a.widthAuto, widthAuto = _d === void 0 ? false : _d;
|
|
7226
7372
|
var theme = useTheme();
|
|
7227
|
-
return (jsx$1(Card$1, __assign({ backgroundColor: backgroundColor, widthAuto: widthAuto, border: { borderColor: borderColor, borderWidth: '0.063rem' }, flex: false }, { children: jsxs$1(Wrapper$3, { children: [jsxs$1(Container$n, __assign({ "data-testid": "TopSection" }, { children: [jsx$1(Text$
|
|
7373
|
+
return (jsx$1(Card$1, __assign({ backgroundColor: backgroundColor, widthAuto: widthAuto, border: { borderColor: borderColor, borderWidth: '0.063rem' }, flex: false }, { children: jsxs$1(Wrapper$3, { children: [jsxs$1(Container$n, __assign({ "data-testid": "TopSection" }, { children: [jsx$1(Text$2, __assign({ color: theme.colors.pallete.secondary.color, weight: "600", margin: "0 1.25rem 0 0" }, { children: getMorePayLessText }), void 0), jsx$1(PriceLabel, { finalPrice: price, originalPrice: originalPrice, color: "#3A3A3A", size: ComponentSize.Small }, void 0)] }), void 0), jsxs$1(Container$n, __assign({ "data-testid": "BottomSection" }, { children: [jsxs$1(Text$2, __assign({ color: "#d3373c", weight: "600", margin: "0 1.25rem 0 0" }, { children: [getQtyForText, " ", discount, "% ", offText] }), void 0), jsxs$1(Text$2, __assign({ color: theme.colors.pallete.secondary.color }, { children: [youAreSavingText, ": ", savingPrice] }), void 0)] }), void 0)] }, void 0) }), void 0));
|
|
7228
7374
|
};
|
|
7229
|
-
var templateObject_1$
|
|
7375
|
+
var templateObject_1$C, templateObject_2$q, templateObject_3$h;
|
|
7230
7376
|
|
|
7231
|
-
var Container$m = newStyled.div(templateObject_1$
|
|
7232
|
-
var Title$2 = newStyled.h1(templateObject_2$
|
|
7233
|
-
var Details$1 = newStyled.span(templateObject_3$
|
|
7234
|
-
var PriceContainer$1 = newStyled.span(templateObject_4$
|
|
7377
|
+
var Container$m = newStyled.div(templateObject_1$B || (templateObject_1$B = __makeTemplateObject(["\n padding: 0.625rem 1.5rem;\n"], ["\n padding: 0.625rem 1.5rem;\n"])));
|
|
7378
|
+
var Title$2 = newStyled.h1(templateObject_2$p || (templateObject_2$p = __makeTemplateObject(["\n font-weight: 700;\n font-size: 1rem;\n line-height: 1.25rem;\n color: ", ";\n margin: 0;\n margin-bottom: 0.125rem;\n text-align: center;\n"], ["\n font-weight: 700;\n font-size: 1rem;\n line-height: 1.25rem;\n color: ", ";\n margin: 0;\n margin-bottom: 0.125rem;\n text-align: center;\n"])), function (props) { return props.color; });
|
|
7379
|
+
var Details$1 = newStyled.span(templateObject_3$g || (templateObject_3$g = __makeTemplateObject(["\n display: flex;\n align-items: center;\n font-weight: 400;\n font-size: 1rem;\n margin: 0;\n line-height: 1.5rem;\n justify-content: center;\n color: ", ";\n"], ["\n display: flex;\n align-items: center;\n font-weight: 400;\n font-size: 1rem;\n margin: 0;\n line-height: 1.5rem;\n justify-content: center;\n color: ", ";\n"])), function (props) { return props.color; });
|
|
7380
|
+
var PriceContainer$1 = newStyled.span(templateObject_4$9 || (templateObject_4$9 = __makeTemplateObject(["\n margin: 0 0.313rem;\n display: flex;\n align-items: center;\n"], ["\n margin: 0 0.313rem;\n display: flex;\n align-items: center;\n"])));
|
|
7235
7381
|
var Simple = function (_a) {
|
|
7236
7382
|
var title = _a.title, freeShippingText = _a.freeShippingText, price = _a.price, anyQtyForText = _a.anyQtyForText, backgroundColor = _a.backgroundColor, _b = _a.widthAuto, widthAuto = _b === void 0 ? false : _b;
|
|
7237
7383
|
var theme = useTheme();
|
|
7238
7384
|
return (jsx$1(Card$1, __assign({ backgroundColor: backgroundColor, widthAuto: widthAuto }, { children: jsxs$1(Container$m, { children: [jsx$1(Title$2, __assign({ color: theme.colors.pallete.secondary.color, "data-testid": "Title" }, { children: title }), void 0), jsxs$1(Details$1, __assign({ color: theme.colors.pallete.secondary.color, "data-testid": "Details" }, { children: [anyQtyForText, jsx$1(PriceContainer$1, __assign({ "data-testid": "Price" }, { children: jsx$1(PriceLabel, { finalPrice: price, color: "#d3373c", size: ComponentSize.Small }, void 0) }), void 0), "+ ", freeShippingText] }), void 0)] }, void 0) }), void 0));
|
|
7239
7385
|
};
|
|
7240
|
-
var templateObject_1$
|
|
7386
|
+
var templateObject_1$B, templateObject_2$p, templateObject_3$g, templateObject_4$9;
|
|
7241
7387
|
|
|
7242
7388
|
var Bundle = {
|
|
7243
7389
|
Minimalistic: Minimalistic,
|
|
7244
7390
|
Simple: Simple,
|
|
7245
7391
|
};
|
|
7246
7392
|
|
|
7247
|
-
var Container$l = newStyled.div(templateObject_1$
|
|
7393
|
+
var Container$l = newStyled.div(templateObject_1$A || (templateObject_1$A = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n width: fit-content;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n width: fit-content;\n"])));
|
|
7248
7394
|
var Tag = function (_a) {
|
|
7249
7395
|
var text = _a.text, className = _a.className;
|
|
7250
7396
|
return jsx$1(Container$l, __assign({ className: className }, { children: text }), void 0);
|
|
7251
7397
|
};
|
|
7252
|
-
var templateObject_1$
|
|
7398
|
+
var templateObject_1$A;
|
|
7253
7399
|
|
|
7254
7400
|
var getStylesBySize$3 = function (size) {
|
|
7255
7401
|
switch (size) {
|
|
@@ -7350,11 +7496,11 @@ var Timer = function (_a) {
|
|
|
7350
7496
|
return (jsxs$1("div", __assign({ "data-testid": "Time" }, { children: [hours, "h ", minutes, "m ", seconds, "s"] }), void 0));
|
|
7351
7497
|
};
|
|
7352
7498
|
|
|
7353
|
-
var Label = newStyled.span(templateObject_1$
|
|
7499
|
+
var Label = newStyled.span(templateObject_1$z || (templateObject_1$z = __makeTemplateObject(["\n font-weight: 600;\n color: ", ";\n font-size: 1.125rem;\n line-height: 1.75rem;\n"], ["\n font-weight: 600;\n color: ", ";\n font-size: 1.125rem;\n line-height: 1.75rem;\n"])), function (_a) {
|
|
7354
7500
|
var color = _a.color;
|
|
7355
7501
|
return color;
|
|
7356
7502
|
});
|
|
7357
|
-
var MandatoryIcon = newStyled.span(templateObject_2$
|
|
7503
|
+
var MandatoryIcon = newStyled.span(templateObject_2$o || (templateObject_2$o = __makeTemplateObject(["\n color: ", ";\n margin-left: 0.25rem;\n"], ["\n color: ", ";\n margin-left: 0.25rem;\n"])), function (_a) {
|
|
7358
7504
|
var color = _a.color;
|
|
7359
7505
|
return color;
|
|
7360
7506
|
});
|
|
@@ -7363,7 +7509,7 @@ var InputLabel = function (_a) {
|
|
|
7363
7509
|
var theme = useTheme();
|
|
7364
7510
|
return (jsxs$1(Label, __assign({ color: isDisabled ? theme.colors.shades['250'].color : theme.colors.shades['700'].color }, { children: [label, isRequired && jsx$1(MandatoryIcon, __assign({ color: theme.colors.semantic.urgent.color }, { children: "*" }), void 0)] }), void 0));
|
|
7365
7511
|
};
|
|
7366
|
-
var templateObject_1$
|
|
7512
|
+
var templateObject_1$z, templateObject_2$o;
|
|
7367
7513
|
|
|
7368
7514
|
var isEmpty = function (value) {
|
|
7369
7515
|
return value.length === 0;
|
|
@@ -7373,20 +7519,20 @@ var sliceString = function (str, maxLength) {
|
|
|
7373
7519
|
return str.length > maxLength ? "".concat(str.slice(0, maxLength), "...") : str;
|
|
7374
7520
|
};
|
|
7375
7521
|
|
|
7376
|
-
var ErrorText = newStyled.h3(templateObject_1$
|
|
7377
|
-
var ErrorContainer = newStyled.div(templateObject_2$
|
|
7522
|
+
var ErrorText = newStyled.h3(templateObject_1$y || (templateObject_1$y = __makeTemplateObject(["\n color: ", " !important;\n font-size: 0.75rem;\n font-weight: 600;\n margin: 0;\n font-height: 1rem;\n margin-left: 0.313rem;\n"], ["\n color: ", " !important;\n font-size: 0.75rem;\n font-weight: 600;\n margin: 0;\n font-height: 1rem;\n margin-left: 0.313rem;\n"])), function (props) { return props.color; });
|
|
7523
|
+
var ErrorContainer = newStyled.div(templateObject_2$n || (templateObject_2$n = __makeTemplateObject(["\n display: flex;\n align-items: center;\n margin-top: 0.25rem;\n"], ["\n display: flex;\n align-items: center;\n margin-top: 0.25rem;\n"])));
|
|
7378
7524
|
var Error$1 = function (_a) {
|
|
7379
7525
|
var error = _a.error;
|
|
7380
7526
|
var theme = useTheme();
|
|
7381
7527
|
return (jsxs$1(ErrorContainer, { children: [jsx$1(Icon.Actions.LightExclamation, { fill: theme.colors.semantic.urgent.color, width: 0.875, height: 0.875 }, void 0), jsx$1(ErrorText, __assign({ color: theme.colors.semantic.urgent.color }, { children: error }), void 0)] }, void 0));
|
|
7382
7528
|
};
|
|
7383
|
-
var templateObject_1$
|
|
7529
|
+
var templateObject_1$y, templateObject_2$n;
|
|
7384
7530
|
|
|
7385
|
-
var Container$k = newStyled.div(templateObject_1$
|
|
7531
|
+
var Container$k = newStyled.div(templateObject_1$x || (templateObject_1$x = __makeTemplateObject(["\n input {\n border-color: ", ";\n }\n"], ["\n input {\n border-color: ", ";\n }\n"])), function (_a) {
|
|
7386
7532
|
var color = _a.color;
|
|
7387
7533
|
return color;
|
|
7388
7534
|
});
|
|
7389
|
-
var StyledInput = newStyled.input(templateObject_2$
|
|
7535
|
+
var StyledInput = newStyled.input(templateObject_2$m || (templateObject_2$m = __makeTemplateObject(["\n padding: ", ";\n font-size: ", ";\n border-radius: ", ";\n border: ", ";\n line-height: ", ";\n color: ", ";\n font-weight: ", ";\n flex: 1 1 50%;\n height: 100%;\n box-sizing: border-box;\n\n &::placeholder {\n color: ", ";\n }\n\n &:focus {\n outline: none;\n border-color: ", ";\n box-shadow: ", ";\n }\n\n &:disabled {\n background-color: ", ";\n border: 0.063rem solid ", ";\n color: ", ";\n\n &::placeholder {\n color: ", ";\n }\n }\n"], ["\n padding: ", ";\n font-size: ", ";\n border-radius: ", ";\n border: ", ";\n line-height: ", ";\n color: ", ";\n font-weight: ", ";\n flex: 1 1 50%;\n height: 100%;\n box-sizing: border-box;\n\n &::placeholder {\n color: ", ";\n }\n\n &:focus {\n outline: none;\n border-color: ", ";\n box-shadow: ", ";\n }\n\n &:disabled {\n background-color: ", ";\n border: 0.063rem solid ", ";\n color: ", ";\n\n &::placeholder {\n color: ", ";\n }\n }\n"])), function (_a) {
|
|
7390
7536
|
var padding = _a.padding;
|
|
7391
7537
|
return padding;
|
|
7392
7538
|
}, function (_a) {
|
|
@@ -7429,34 +7575,49 @@ var StyledInput = newStyled.input(templateObject_2$n || (templateObject_2$n = __
|
|
|
7429
7575
|
var disabledColor = _a.disabledColor;
|
|
7430
7576
|
return disabledColor;
|
|
7431
7577
|
});
|
|
7432
|
-
var InputWrapper = newStyled.div(templateObject_3$
|
|
7433
|
-
var
|
|
7578
|
+
var InputWrapper = newStyled.div(templateObject_3$f || (templateObject_3$f = __makeTemplateObject(["\n position: relative;\n display: flex;\n height: ", ";\n"], ["\n position: relative;\n display: flex;\n height: ", ";\n"])), function (_a) {
|
|
7579
|
+
var size = _a.size;
|
|
7580
|
+
return (size === 'small' ? '36px' : '44px');
|
|
7581
|
+
});
|
|
7582
|
+
var templateObject_1$x, templateObject_2$m, templateObject_3$f;
|
|
7434
7583
|
|
|
7435
7584
|
var BaseInput = function (_a) {
|
|
7436
|
-
var
|
|
7585
|
+
var _b;
|
|
7586
|
+
var value = _a.value, onChange = _a.onChange, _c = _a.defaultValue, defaultValue = _c === void 0 ? '' : _c, label = _a.label, children = _a.children, required = _a.required, onValidation = _a.onValidation, size = _a.size, rest = __rest(_a, ["value", "onChange", "defaultValue", "label", "children", "required", "onValidation", "size"]);
|
|
7437
7587
|
var theme = useTheme();
|
|
7438
|
-
var
|
|
7439
|
-
var
|
|
7588
|
+
var _d = useState((_b = value !== null && value !== void 0 ? value : defaultValue) !== null && _b !== void 0 ? _b : ''), internalValue = _d[0], setInternalValue = _d[1];
|
|
7589
|
+
var _e = useState(InputValidationType.Empty), status = _e[0], setStatus = _e[1];
|
|
7440
7590
|
var handleChange = function (_a) {
|
|
7441
|
-
var
|
|
7442
|
-
|
|
7443
|
-
|
|
7591
|
+
var target = _a.target;
|
|
7592
|
+
if (onChange) {
|
|
7593
|
+
onChange(target.value);
|
|
7594
|
+
}
|
|
7595
|
+
if (value == null) {
|
|
7596
|
+
setInternalValue(target.value);
|
|
7597
|
+
}
|
|
7444
7598
|
};
|
|
7445
7599
|
var validate = function (_a) {
|
|
7446
7600
|
var value = _a.target.value;
|
|
7447
|
-
var
|
|
7448
|
-
setStatus(newStatus);
|
|
7449
|
-
onValidation && onValidation(newStatus);
|
|
7450
|
-
};
|
|
7451
|
-
var handleValidations = function (value) {
|
|
7601
|
+
var status = InputValidationType.Valid;
|
|
7452
7602
|
if (required && isEmpty(value)) {
|
|
7453
|
-
|
|
7603
|
+
status = InputValidationType.Error;
|
|
7454
7604
|
}
|
|
7455
7605
|
if (!required && isEmpty(value)) {
|
|
7456
|
-
|
|
7606
|
+
status = InputValidationType.Empty;
|
|
7457
7607
|
}
|
|
7458
|
-
|
|
7608
|
+
setStatus(status);
|
|
7459
7609
|
};
|
|
7610
|
+
useEffect(function () {
|
|
7611
|
+
if (value == null) {
|
|
7612
|
+
return;
|
|
7613
|
+
}
|
|
7614
|
+
setInternalValue(value);
|
|
7615
|
+
}, [value]);
|
|
7616
|
+
useEffect(function () {
|
|
7617
|
+
if (onValidation != null) {
|
|
7618
|
+
onValidation(status);
|
|
7619
|
+
}
|
|
7620
|
+
}, [onValidation, status]);
|
|
7460
7621
|
var styling = {
|
|
7461
7622
|
border: theme.component.input.border,
|
|
7462
7623
|
borderRadius: theme.component.input.borderRadius,
|
|
@@ -7475,39 +7636,57 @@ var BaseInput = function (_a) {
|
|
|
7475
7636
|
? theme.colors.shades['700'].color
|
|
7476
7637
|
: status === InputValidationType.Error
|
|
7477
7638
|
? theme.colors.semantic.urgent.color
|
|
7478
|
-
: '' }, { children: [label && (jsx$1(InputLabel, { label: label, isDisabled: rest.disabled, isRequired: Boolean(required) }, void 0)), jsxs$1(InputWrapper, __assign({ className: "inputWrapper" }, { children: [jsx$1(StyledInput, __assign({ "data-testid": "base-input", type: "text", onChange: handleChange, onBlur: validate, required: Boolean(required), value:
|
|
7639
|
+
: '' }, { children: [label && (jsx$1(InputLabel, { label: label, isDisabled: rest.disabled, isRequired: Boolean(required) }, void 0)), jsxs$1(InputWrapper, __assign({ className: "inputWrapper", size: size }, { children: [jsx$1(StyledInput, __assign({ "data-testid": "base-input", type: "text", onChange: handleChange, onBlur: validate, required: Boolean(required), value: internalValue }, rest, styling), void 0), children] }), void 0), required && status === InputValidationType.Error && jsx$1(Error$1, { error: required }, void 0)] }), void 0));
|
|
7640
|
+
};
|
|
7641
|
+
|
|
7642
|
+
var Button$4 = function (_a) {
|
|
7643
|
+
var variant = _a.variant, props = __rest(_a, ["variant"]);
|
|
7644
|
+
if (variant === 'primary') {
|
|
7645
|
+
return jsx$1(ButtonPrimary, __assign({}, props), void 0);
|
|
7646
|
+
}
|
|
7647
|
+
if (variant === 'secondary') {
|
|
7648
|
+
return jsx$1(ButtonSecondary, __assign({}, props), void 0);
|
|
7649
|
+
}
|
|
7650
|
+
if (variant === 'secondary-outline') {
|
|
7651
|
+
return jsx$1(ButtonSecondary, __assign({}, props), void 0);
|
|
7652
|
+
}
|
|
7653
|
+
throw new Error("Invalid button variant ".concat(variant));
|
|
7479
7654
|
};
|
|
7480
7655
|
|
|
7481
|
-
var Container$j = newStyled.div(templateObject_1$
|
|
7656
|
+
var Container$j = newStyled.div(templateObject_1$w || (templateObject_1$w = __makeTemplateObject(["\n overflow: hidden;\n\n input {\n border-radius: ", ";\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n border-right: none;\n }\n"], ["\n overflow: hidden;\n\n input {\n border-radius: ", ";\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n border-right: none;\n }\n"])), function (_a) {
|
|
7482
7657
|
var theme = _a.theme;
|
|
7483
7658
|
return theme.component.inputCustom.input.borderRadius;
|
|
7484
7659
|
});
|
|
7485
|
-
var ButtonContainer$1 = newStyled.div(templateObject_2$
|
|
7660
|
+
var ButtonContainer$1 = newStyled.div(templateObject_2$l || (templateObject_2$l = __makeTemplateObject(["\n max-width: 50%;\n\n button {\n width: 100%;\n height: 100%;\n border-radius: ", ";\n }\n"], ["\n max-width: 50%;\n\n button {\n width: 100%;\n height: 100%;\n border-radius: ", ";\n }\n"])), function (_a) {
|
|
7486
7661
|
var theme = _a.theme;
|
|
7487
7662
|
return theme.component.inputCustom.button.borderRadius;
|
|
7488
7663
|
});
|
|
7489
7664
|
var Custom = function (_a) {
|
|
7490
|
-
var onClick = _a.onClick, text = _a.text,
|
|
7665
|
+
var onClick = _a.onClick, text = _a.text, variant = _a.variant, rest = __rest(_a, ["onClick", "text", "variant"]);
|
|
7491
7666
|
var theme = useTheme();
|
|
7492
|
-
var props = {
|
|
7667
|
+
var props = useMemo(function () { return ({
|
|
7668
|
+
variant: variant,
|
|
7493
7669
|
onClick: onClick,
|
|
7494
7670
|
text: text,
|
|
7495
7671
|
disabled: rest.disabled,
|
|
7496
|
-
};
|
|
7497
|
-
return (jsx$1(Container$j, __assign({ theme: theme }, { children: jsx$1(BaseInput, __assign({}, rest, { children: jsx$1(ButtonContainer$1, __assign({ theme: theme }, { children:
|
|
7672
|
+
}); }, [variant, onClick, text, rest.disabled]);
|
|
7673
|
+
return (jsx$1(Container$j, __assign({ theme: theme }, { children: jsx$1(BaseInput, __assign({}, rest, { children: jsx$1(ButtonContainer$1, __assign({ theme: theme }, { children: jsx$1(Button$4, __assign({}, props), void 0) }), void 0) }), void 0) }), void 0));
|
|
7498
7674
|
};
|
|
7499
|
-
var templateObject_1$
|
|
7675
|
+
var templateObject_1$w, templateObject_2$l;
|
|
7500
7676
|
|
|
7501
|
-
var SuccessContainer = newStyled.div(templateObject_1$
|
|
7502
|
-
var
|
|
7503
|
-
|
|
7677
|
+
var SuccessContainer = newStyled.div(templateObject_1$v || (templateObject_1$v = __makeTemplateObject(["\n height: ", ";\n display: flex;\n"], ["\n height: ", ";\n display: flex;\n"])), function (_a) {
|
|
7678
|
+
var size = _a.size;
|
|
7679
|
+
return (size === 'small' ? '36px' : '');
|
|
7680
|
+
});
|
|
7681
|
+
var SuccessMessage = newStyled.div(templateObject_2$k || (templateObject_2$k = __makeTemplateObject(["\n background-color: #dfefe0;\n border: 0.063rem solid #5ead63;\n border-radius: 0.5rem;\n width: 100%;\n flex: 1;\n display: flex;\n align-items: center;\n padding: 0 1rem;\n box-sizing: border-box;\n"], ["\n background-color: #dfefe0;\n border: 0.063rem solid #5ead63;\n border-radius: 0.5rem;\n width: 100%;\n flex: 1;\n display: flex;\n align-items: center;\n padding: 0 1rem;\n box-sizing: border-box;\n"])));
|
|
7682
|
+
var SuccessText = newStyled.span(templateObject_3$e || (templateObject_3$e = __makeTemplateObject(["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n margin-left: 0.313rem;\n"], ["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n margin-left: 0.313rem;\n"])));
|
|
7504
7683
|
var Success = function (_a) {
|
|
7505
|
-
var children = _a.children, successText = _a.successText;
|
|
7506
|
-
return (jsxs$1(SuccessContainer, { children: [jsxs$1(SuccessMessage, { children: [jsx$1(Icon.Actions.Check, { fill: "#5EAD63", width: 1.375, height: 1.063 }, void 0), jsx$1(SuccessText, { children: successText }, void 0)] }, void 0), children] }, void 0));
|
|
7684
|
+
var children = _a.children, successText = _a.successText, size = _a.size;
|
|
7685
|
+
return (jsxs$1(SuccessContainer, __assign({ size: size }, { children: [jsxs$1(SuccessMessage, { children: [jsx$1(Icon.Actions.Check, { fill: "#5EAD63", width: 1.375, height: 1.063 }, void 0), jsx$1(SuccessText, { children: successText }, void 0)] }, void 0), children] }), void 0));
|
|
7507
7686
|
};
|
|
7508
|
-
var templateObject_1$
|
|
7687
|
+
var templateObject_1$v, templateObject_2$k, templateObject_3$e;
|
|
7509
7688
|
|
|
7510
|
-
var ButtonContainer = newStyled.div(templateObject_1$
|
|
7689
|
+
var ButtonContainer = newStyled.div(templateObject_1$u || (templateObject_1$u = __makeTemplateObject(["\n margin-left: 0.625rem;\n\n button {\n width: 100%;\n height: 100%;\n background-color: ", ";\n }\n"], ["\n margin-left: 0.625rem;\n\n button {\n width: 100%;\n height: 100%;\n background-color: ", ";\n }\n"])), function (_a) {
|
|
7511
7690
|
var status = _a.status, type = _a.type, theme = _a.theme;
|
|
7512
7691
|
return status === InputValidationType.Empty &&
|
|
7513
7692
|
type === 'primary' &&
|
|
@@ -7516,15 +7695,18 @@ var ButtonContainer = newStyled.div(templateObject_1$w || (templateObject_1$w =
|
|
|
7516
7695
|
var BasePlusButton = function (_a) {
|
|
7517
7696
|
var onClick = _a.onClick, onClickEdit = _a.onClickEdit, text = _a.text, success = _a.success, editText = _a.editText, successText = _a.successText, rest = __rest(_a, ["onClick", "onClickEdit", "text", "success", "editText", "successText"]);
|
|
7518
7697
|
var _b = useState(InputValidationType.Empty), status = _b[0], setStatus = _b[1];
|
|
7698
|
+
var _c = useState(''), inputValue = _c[0], setInputValue = _c[1];
|
|
7519
7699
|
var theme = useTheme();
|
|
7520
|
-
var
|
|
7521
|
-
|
|
7522
|
-
|
|
7700
|
+
var onChangeInput = useCallback(function (value) { return setInputValue(value); }, []);
|
|
7701
|
+
if (success) {
|
|
7702
|
+
return (jsx$1(Success, __assign({ successText: successText, size: rest.size }, { children: jsx$1(ButtonContainer, __assign({ status: status, type: "secondary", theme: theme }, { children: jsx$1(ButtonSecondaryOutline, { text: editText, onClick: onClickEdit, disabled: rest.disabled }, void 0) }), void 0) }), void 0));
|
|
7703
|
+
}
|
|
7704
|
+
return (jsx$1(BaseInput, __assign({}, rest, { onValidation: setStatus, onChange: onChangeInput }, { children: jsx$1(ButtonContainer, __assign({ status: status, type: "primary", theme: theme }, { children: jsx$1(ButtonSecondary, { text: text, onClick: function () { return onClick(inputValue); }, disabled: rest.disabled || status === InputValidationType.Error }, void 0) }), void 0) }), void 0));
|
|
7523
7705
|
};
|
|
7524
|
-
var templateObject_1$
|
|
7706
|
+
var templateObject_1$u;
|
|
7525
7707
|
|
|
7526
|
-
var Container$i = newStyled.div(templateObject_1$
|
|
7527
|
-
var IconContainer$3 = newStyled.div(templateObject_2$
|
|
7708
|
+
var Container$i = newStyled.div(templateObject_1$t || (templateObject_1$t = __makeTemplateObject(["\n input {\n padding-right: 2.688rem;\n }\n"], ["\n input {\n padding-right: 2.688rem;\n }\n"])));
|
|
7709
|
+
var IconContainer$3 = newStyled.div(templateObject_2$j || (templateObject_2$j = __makeTemplateObject(["\n position: absolute;\n right: 0.875rem;\n width: 1.125rem;\n height: 100%;\n display: flex;\n align-items: center;\n\n svg path {\n fill: ", ";\n }\n"], ["\n position: absolute;\n right: 0.875rem;\n width: 1.125rem;\n height: 100%;\n display: flex;\n align-items: center;\n\n svg path {\n fill: ", ";\n }\n"])), function (props) { return props.color; });
|
|
7528
7710
|
var BasePlusIcon = function (_a) {
|
|
7529
7711
|
var Icon = _a.Icon, rest = __rest(_a, ["Icon"]);
|
|
7530
7712
|
var theme = useTheme();
|
|
@@ -7535,7 +7717,7 @@ var BasePlusIcon = function (_a) {
|
|
|
7535
7717
|
? theme.colors.semantic.urgent.color
|
|
7536
7718
|
: '' }, { children: createElement(Icon, { fill: theme.colors.shades['250'].color }) }), void 0) }), void 0) }, void 0));
|
|
7537
7719
|
};
|
|
7538
|
-
var templateObject_1$
|
|
7720
|
+
var templateObject_1$t, templateObject_2$j;
|
|
7539
7721
|
|
|
7540
7722
|
var Input$1 = {
|
|
7541
7723
|
Simple: BaseInput,
|
|
@@ -7544,7 +7726,7 @@ var Input$1 = {
|
|
|
7544
7726
|
SimplePlusIcon: BasePlusIcon,
|
|
7545
7727
|
};
|
|
7546
7728
|
|
|
7547
|
-
var Container$h = newStyled.div(templateObject_1$
|
|
7729
|
+
var Container$h = newStyled.div(templateObject_1$s || (templateObject_1$s = __makeTemplateObject(["\n width: ", ";\n height: ", ";\n border: 0.063rem solid ", ";\n border-radius: 0.25rem;\n padding: 0.375rem;\n cursor: ", ";\n"], ["\n width: ", ";\n height: ", ";\n border: 0.063rem solid ", ";\n border-radius: 0.25rem;\n padding: 0.375rem;\n cursor: ", ";\n"])), function (_a) {
|
|
7548
7730
|
var width = _a.width;
|
|
7549
7731
|
return width;
|
|
7550
7732
|
}, function (_a) {
|
|
@@ -7562,9 +7744,9 @@ var PaymentMethod = function (_a) {
|
|
|
7562
7744
|
var theme = useTheme();
|
|
7563
7745
|
return (jsx$1(Container$h, __assign({ width: width, height: height, borderColor: theme.colors.shades['100'].color, isClickable: Boolean(onClick), onClick: onClick, "data-testid": "payment-method-container" }, { children: createElement(Icon) }), void 0));
|
|
7564
7746
|
};
|
|
7565
|
-
var templateObject_1$
|
|
7747
|
+
var templateObject_1$s;
|
|
7566
7748
|
|
|
7567
|
-
var Text$
|
|
7749
|
+
var Text$1 = newStyled.h3(templateObject_1$r || (templateObject_1$r = __makeTemplateObject(["\n background-color: ", ";\n margin: 0;\n padding: 0.25rem 0.5rem;\n font-size: 0.625rem;\n font-weight: 700;\n line-height: 0.875rem;\n border-radius: 0.125rem;\n display: initial;\n color: ", ";\n"], ["\n background-color: ", ";\n margin: 0;\n padding: 0.25rem 0.5rem;\n font-size: 0.625rem;\n font-weight: 700;\n line-height: 0.875rem;\n border-radius: 0.125rem;\n display: initial;\n color: ", ";\n"])), function (_a) {
|
|
7568
7750
|
var backgroundColor = _a.backgroundColor;
|
|
7569
7751
|
return backgroundColor;
|
|
7570
7752
|
}, function (_a) {
|
|
@@ -7574,29 +7756,29 @@ var Text$2 = newStyled.h3(templateObject_1$t || (templateObject_1$t = __makeTemp
|
|
|
7574
7756
|
var OfferBanner = function (_a) {
|
|
7575
7757
|
var discountAppliedText = _a.discountAppliedText, backgroundColor = _a.backgroundColor;
|
|
7576
7758
|
var theme = useTheme();
|
|
7577
|
-
return (jsx$1(Text$
|
|
7759
|
+
return (jsx$1(Text$1, __assign({ backgroundColor: backgroundColor, color: theme.colors.shades['700'].color, "data-testid": "OfferBanner" }, { children: discountAppliedText }), void 0));
|
|
7578
7760
|
};
|
|
7579
|
-
var templateObject_1$
|
|
7761
|
+
var templateObject_1$r;
|
|
7580
7762
|
|
|
7581
|
-
var Wrapper$2 = newStyled.div(templateObject_1$
|
|
7582
|
-
var GrandTotal = newStyled.h1(templateObject_2$
|
|
7583
|
-
var Currency = newStyled.span(templateObject_3$
|
|
7584
|
-
var Container$g = newStyled.div(templateObject_4$
|
|
7585
|
-
var Discount = newStyled.h3(templateObject_5$
|
|
7763
|
+
var Wrapper$2 = newStyled.div(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n"], ["\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n"])));
|
|
7764
|
+
var GrandTotal = newStyled.h1(templateObject_2$i || (templateObject_2$i = __makeTemplateObject(["\n margin: 0;\n font-size: 1.5rem;\n line-height: 2rem;\n font-weight: 700;\n color: ", ";\n display: flex;\n align-items: center;\n"], ["\n margin: 0;\n font-size: 1.5rem;\n line-height: 2rem;\n font-weight: 700;\n color: ", ";\n display: flex;\n align-items: center;\n"])), function (props) { return props.color; });
|
|
7765
|
+
var Currency = newStyled.span(templateObject_3$d || (templateObject_3$d = __makeTemplateObject(["\n margin: 0;\n margin-right: 0.625rem;\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 600;\n"], ["\n margin: 0;\n margin-right: 0.625rem;\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 600;\n"])));
|
|
7766
|
+
var Container$g = newStyled.div(templateObject_4$8 || (templateObject_4$8 = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n width: 100%;\n margin-top: 0.625rem;\n color: ", ";\n"], ["\n display: flex;\n justify-content: space-between;\n width: 100%;\n margin-top: 0.625rem;\n color: ", ";\n"])), function (props) { return props.highlightColor; });
|
|
7767
|
+
var Discount = newStyled.h3(templateObject_5$4 || (templateObject_5$4 = __makeTemplateObject(["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n"], ["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n"])));
|
|
7586
7768
|
var Total = function (_a) {
|
|
7587
7769
|
var total = _a.total, currency = _a.currency, saving = _a.saving, _b = _a.highlightColor, highlightColor = _b === void 0 ? '#2f806a' : _b;
|
|
7588
7770
|
var theme = useTheme();
|
|
7589
7771
|
return (jsxs$1(Wrapper$2, __assign({ "data-testid": "total-wrapper" }, { children: [jsxs$1(GrandTotal, __assign({ color: theme.colors.shades['550'].color }, { children: [jsx$1(Currency, { children: currency }, void 0), total] }), void 0), saving && (jsxs$1(Container$g, __assign({ "data-testid": "subtotal-container", highlightColor: highlightColor }, { children: [jsx$1(Discount, { children: saving.savingText }, void 0), jsx$1(Discount, { children: saving.amount }, void 0)] }), void 0))] }), void 0));
|
|
7590
7772
|
};
|
|
7591
|
-
var templateObject_1$
|
|
7773
|
+
var templateObject_1$q, templateObject_2$i, templateObject_3$d, templateObject_4$8, templateObject_5$4;
|
|
7592
7774
|
|
|
7593
|
-
var Wrapper$1 = newStyled.div(templateObject_1$
|
|
7775
|
+
var Wrapper$1 = newStyled.div(templateObject_1$p || (templateObject_1$p = __makeTemplateObject(["\n color: ", ";\n"], ["\n color: ", ";\n"])), function (_a) {
|
|
7594
7776
|
var color = _a.color;
|
|
7595
7777
|
return color;
|
|
7596
7778
|
});
|
|
7597
|
-
var ItemContainer = newStyled.div(templateObject_2$
|
|
7598
|
-
var Item$1 = newStyled.h4(templateObject_3$
|
|
7599
|
-
var CouponItem = newStyled(Item$1)(templateObject_4$
|
|
7779
|
+
var ItemContainer = newStyled.div(templateObject_2$h || (templateObject_2$h = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n margin-bottom: 0.625rem;\n\n &:last-child {\n margin-bottom: 0;\n }\n"], ["\n display: flex;\n justify-content: space-between;\n margin-bottom: 0.625rem;\n\n &:last-child {\n margin-bottom: 0;\n }\n"])));
|
|
7780
|
+
var Item$1 = newStyled.h4(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n margin: 0;\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 600;\n"], ["\n margin: 0;\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 600;\n"])));
|
|
7781
|
+
var CouponItem = newStyled(Item$1)(templateObject_4$7 || (templateObject_4$7 = __makeTemplateObject(["\n color: ", ";\n"], ["\n color: ", ";\n"])), function (_a) {
|
|
7600
7782
|
var color = _a.color;
|
|
7601
7783
|
return color;
|
|
7602
7784
|
});
|
|
@@ -7608,22 +7790,22 @@ var Subtotal = function (_a) {
|
|
|
7608
7790
|
return (jsxs$1(ItemContainer, { children: [jsxs$1(CouponItem, __assign({ color: highlightColor }, { children: [coupon.couponText, " ", c.code, " ", coupon.appliedText] }), void 0), jsx$1(CouponItem, __assign({ color: highlightColor }, { children: c.amount }), void 0)] }, i));
|
|
7609
7791
|
})] }), void 0));
|
|
7610
7792
|
};
|
|
7611
|
-
var templateObject_1$
|
|
7793
|
+
var templateObject_1$p, templateObject_2$h, templateObject_3$c, templateObject_4$7;
|
|
7612
7794
|
|
|
7613
7795
|
var Totals = {
|
|
7614
7796
|
Total: Total,
|
|
7615
7797
|
Subtotal: Subtotal,
|
|
7616
7798
|
};
|
|
7617
7799
|
|
|
7618
|
-
var Container$f = newStyled.div(templateObject_1$
|
|
7619
|
-
var IconContainer$2 = newStyled.div(templateObject_2$
|
|
7620
|
-
var Text
|
|
7621
|
-
var Details = newStyled.span(templateObject_4$
|
|
7800
|
+
var Container$f = newStyled.div(templateObject_1$o || (templateObject_1$o = __makeTemplateObject(["\n padding: 0.625rem 1.25rem;\n background-color: ", ";\n border-radius: 0.313rem;\n display: flex;\n margin-bottom: 0.938rem;\n"], ["\n padding: 0.625rem 1.25rem;\n background-color: ", ";\n border-radius: 0.313rem;\n display: flex;\n margin-bottom: 0.938rem;\n"])), function (props) { return props.color; });
|
|
7801
|
+
var IconContainer$2 = newStyled.div(templateObject_2$g || (templateObject_2$g = __makeTemplateObject(["\n width: 1rem;\n height: 0.875rem;\n margin-right: 0.5rem;\n margin-top: 0.125rem;\n"], ["\n width: 1rem;\n height: 0.875rem;\n margin-right: 0.5rem;\n margin-top: 0.125rem;\n"])));
|
|
7802
|
+
var Text = newStyled.p(templateObject_3$b || (templateObject_3$b = __makeTemplateObject(["\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 400;\n margin: 0;\n color: ", ";\n"], ["\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 400;\n margin: 0;\n color: ", ";\n"])), function (props) { return props.color; });
|
|
7803
|
+
var Details = newStyled.span(templateObject_4$6 || (templateObject_4$6 = __makeTemplateObject(["\n color: ", ";\n font-weight: 700;\n"], ["\n color: ", ";\n font-weight: 700;\n"])), function (props) { return props.color; });
|
|
7622
7804
|
var Note = function (_a) {
|
|
7623
7805
|
var accentColor = _a.accentColor, color = _a.color, backgroundColor = _a.backgroundColor, importantNoteText = _a.importantNoteText, text = _a.text;
|
|
7624
|
-
return (jsxs$1(Container$f, __assign({ color: backgroundColor, "data-testid": "Container" }, { children: [jsx$1(IconContainer$2, { children: jsx$1(Icon.Actions.LightExclamation, { fill: accentColor }, void 0) }, void 0), jsx$1("div", { children: jsxs$1(Text
|
|
7806
|
+
return (jsxs$1(Container$f, __assign({ color: backgroundColor, "data-testid": "Container" }, { children: [jsx$1(IconContainer$2, { children: jsx$1(Icon.Actions.LightExclamation, { fill: accentColor }, void 0) }, void 0), jsx$1("div", { children: jsxs$1(Text, __assign({ color: color }, { children: [jsxs$1(Details, __assign({ color: accentColor }, { children: [importantNoteText, ":"] }), void 0), " ", text] }), void 0) }, void 0)] }), void 0));
|
|
7625
7807
|
};
|
|
7626
|
-
var templateObject_1$
|
|
7808
|
+
var templateObject_1$o, templateObject_2$g, templateObject_3$b, templateObject_4$6;
|
|
7627
7809
|
|
|
7628
7810
|
/* eslint-disable no-param-reassign */
|
|
7629
7811
|
var index$2 = function (breakpoints) {
|
|
@@ -7713,14 +7895,14 @@ var mediaQueries = function (_a) {
|
|
|
7713
7895
|
], { literal: true });
|
|
7714
7896
|
};
|
|
7715
7897
|
|
|
7716
|
-
var Title$1 = newStyled.h1(templateObject_1$
|
|
7717
|
-
var Line = newStyled.div(templateObject_2$
|
|
7718
|
-
var Row$1 = newStyled.div(templateObject_3$
|
|
7898
|
+
var Title$1 = newStyled.h1(templateObject_1$n || (templateObject_1$n = __makeTemplateObject(["\n color: ", ";\n font-size: 1.25rem;\n line-height: 1.75rem;\n font-weight: 600;\n margin: 0;\n text-align: center;\n"], ["\n color: ", ";\n font-size: 1.25rem;\n line-height: 1.75rem;\n font-weight: 600;\n margin: 0;\n text-align: center;\n"])), function (props) { return props.color; });
|
|
7899
|
+
var Line = newStyled.div(templateObject_2$f || (templateObject_2$f = __makeTemplateObject(["\n width: 100%;\n height: 0.063rem;\n background-color: ", ";\n margin: 0.938rem 0;\n"], ["\n width: 100%;\n height: 0.063rem;\n background-color: ", ";\n margin: 0.938rem 0;\n"])), function (props) { return props.backgroundColor; });
|
|
7900
|
+
var Row$1 = newStyled.div(templateObject_3$a || (templateObject_3$a = __makeTemplateObject(["\n display: flex;\n ", "\n justify-content: space-between;\n align-items: flex-start;\n"], ["\n display: flex;\n ", "\n justify-content: space-between;\n align-items: flex-start;\n"])), function (props) {
|
|
7719
7901
|
return mediaQueries(props)({
|
|
7720
7902
|
flexDirection: ['column', 'row'],
|
|
7721
7903
|
});
|
|
7722
7904
|
});
|
|
7723
|
-
var Col$1 = newStyled.div(templateObject_4$
|
|
7905
|
+
var Col$1 = newStyled.div(templateObject_4$5 || (templateObject_4$5 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n justify-content: center;\n flex: 1;\n ", "\n"], ["\n display: flex;\n flex-direction: column;\n justify-content: center;\n flex: 1;\n ", "\n"])), function (props) {
|
|
7724
7906
|
return mediaQueries(props)({
|
|
7725
7907
|
margin: ['0', '0 1.25rem'],
|
|
7726
7908
|
marginBottom: ['1.875rem', '0'],
|
|
@@ -7729,13 +7911,13 @@ var Col$1 = newStyled.div(templateObject_4$7 || (templateObject_4$7 = __makeTemp
|
|
|
7729
7911
|
width: ['100%', 'inherit'],
|
|
7730
7912
|
});
|
|
7731
7913
|
});
|
|
7732
|
-
var IconContainer$1 = newStyled.div(templateObject_5$
|
|
7914
|
+
var IconContainer$1 = newStyled.div(templateObject_5$3 || (templateObject_5$3 = __makeTemplateObject(["\n width: 1.375rem;\n height: 1.375rem;\n margin-right: 0.438rem;\n ", "\n"], ["\n width: 1.375rem;\n height: 1.375rem;\n margin-right: 0.438rem;\n ", "\n"])), function (props) {
|
|
7733
7915
|
return mediaQueries(props)({
|
|
7734
7916
|
marginBottom: ['1.875rem', '0'],
|
|
7735
7917
|
width: ['auto', '1.375rem'],
|
|
7736
7918
|
});
|
|
7737
7919
|
});
|
|
7738
|
-
var SectionTitle = newStyled.h1(templateObject_6$
|
|
7920
|
+
var SectionTitle = newStyled.h1(templateObject_6$3 || (templateObject_6$3 = __makeTemplateObject(["\n ", "\n color: ", ";\n font-size: 1rem;\n line-height: 1.25rem;\n font-weight: 600;\n margin: 0;\n"], ["\n ", "\n color: ", ";\n font-size: 1rem;\n line-height: 1.25rem;\n font-weight: 600;\n margin: 0;\n"])), function (props) {
|
|
7739
7921
|
return mediaQueries(props)({
|
|
7740
7922
|
display: ['block', 'flex'],
|
|
7741
7923
|
});
|
|
@@ -7743,53 +7925,46 @@ var SectionTitle = newStyled.h1(templateObject_6$4 || (templateObject_6$4 = __ma
|
|
|
7743
7925
|
var theme = _a.theme;
|
|
7744
7926
|
return theme.colors.shades['700'].color;
|
|
7745
7927
|
});
|
|
7746
|
-
var SectionDetails = newStyled.p(templateObject_7$
|
|
7747
|
-
var KeepMeUpdated = newStyled.h1(templateObject_8
|
|
7928
|
+
var SectionDetails = newStyled.p(templateObject_7$1 || (templateObject_7$1 = __makeTemplateObject(["\n color: ", ";\n font-size: 1rem;\n line-height: 1.25rem;\n font-weight: 400;\n margin: 0;\n margin-top: 0.625rem;\n"], ["\n color: ", ";\n font-size: 1rem;\n line-height: 1.25rem;\n font-weight: 400;\n margin: 0;\n margin-top: 0.625rem;\n"])), function (props) { return props.color; });
|
|
7929
|
+
var KeepMeUpdated = newStyled.h1(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n border: 0.063rem solid ", ";\n color: #0078ff;\n border-radius: 0.313rem;\n padding: 0.625rem;\n font-size: 0.875rem;\n line-height: 1.125rem;\n font-weight: 600;\n margin: 0;\n margin-top: 0.625rem;\n display: flex;\n align-items: center;\n background-color: #fff;\n user-select: none;\n\n svg {\n margin-right: 0.375rem;\n }\n\n &:hover {\n cursor: pointer;\n }\n"], ["\n border: 0.063rem solid ", ";\n color: #0078ff;\n border-radius: 0.313rem;\n padding: 0.625rem;\n font-size: 0.875rem;\n line-height: 1.125rem;\n font-weight: 600;\n margin: 0;\n margin-top: 0.625rem;\n display: flex;\n align-items: center;\n background-color: #fff;\n user-select: none;\n\n svg {\n margin-right: 0.375rem;\n }\n\n &:hover {\n cursor: pointer;\n }\n"])), function (props) { return props.borderColor; });
|
|
7748
7930
|
var DeliveryDetails = function (_a) {
|
|
7749
7931
|
var deliveryDetailsText = _a.deliveryDetailsText, arrivingBy = _a.arrivingBy, shippingTo = _a.shippingTo, instantOrderUpdate = _a.instantOrderUpdate, note = _a.note;
|
|
7750
7932
|
var theme = useTheme();
|
|
7751
7933
|
return (jsxs$1("div", __assign({ "data-testid": "DeliveryDetails" }, { children: [jsx$1(Title$1, __assign({ color: theme.colors.pallete.secondary.color }, { children: deliveryDetailsText }), void 0), jsx$1(Line, { backgroundColor: theme.colors.shades['100'].color }, void 0), note && jsx$1(Note, __assign({}, note), void 0), jsxs$1(Row$1, __assign({ "data-testid": "DD-row", theme: theme }, { children: [jsxs$1(Col$1, __assign({ theme: theme }, { children: [jsxs$1(SectionTitle, __assign({ theme: theme }, { children: [jsx$1(IconContainer$1, __assign({ theme: theme }, { children: jsx$1(Icon.PDP.Clock, {}, void 0) }), void 0), arrivingBy.title] }), void 0), jsx$1(SectionDetails, __assign({ color: theme.colors.shades['700'].color }, { children: arrivingBy.details }), void 0)] }), void 0), jsxs$1(Col$1, __assign({ theme: theme }, { children: [jsxs$1(SectionTitle, __assign({ theme: theme }, { children: [jsx$1(IconContainer$1, __assign({ theme: theme }, { children: jsx$1(Icon.Navigation.MapMarker, {}, void 0) }), void 0), shippingTo.title] }), void 0), jsx$1(SectionDetails, __assign({ color: theme.colors.shades['700'].color }, { children: shippingTo.details }), void 0)] }), void 0), jsxs$1(Col$1, __assign({ theme: theme }, { children: [jsxs$1(SectionTitle, __assign({ theme: theme }, { children: [jsx$1(IconContainer$1, __assign({ theme: theme }, { children: jsx$1(Icon.Messaging.Messenger, {}, void 0) }), void 0), instantOrderUpdate.title] }), void 0), jsx$1(SectionDetails, __assign({ color: theme.colors.shades['700'].color }, { children: instantOrderUpdate.details }), void 0), jsxs$1(KeepMeUpdated, __assign({ onClick: instantOrderUpdate.keepMeUpdated.onClick, borderColor: theme.colors.shades['150'].color }, { children: [jsx$1(Icon.Messaging.Messenger, { width: 1, height: 1, fill: "#0078FF" }, void 0), instantOrderUpdate.keepMeUpdated.title] }), void 0)] }), void 0)] }), void 0)] }), void 0));
|
|
7752
7934
|
};
|
|
7753
|
-
var templateObject_1$
|
|
7935
|
+
var templateObject_1$n, templateObject_2$f, templateObject_3$a, templateObject_4$5, templateObject_5$3, templateObject_6$3, templateObject_7$1, templateObject_8;
|
|
7754
7936
|
|
|
7755
|
-
var Container$e = newStyled.div(templateObject_1$
|
|
7756
|
-
var H1$2 = newStyled.h1(templateObject_2$
|
|
7937
|
+
var Container$e = newStyled.div(templateObject_1$m || (templateObject_1$m = __makeTemplateObject(["\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n user-select: none;\n"], ["\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n user-select: none;\n"])));
|
|
7938
|
+
var H1$2 = newStyled.h1(templateObject_2$e || (templateObject_2$e = __makeTemplateObject(["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 700;\n color: ", ";\n margin-right: 0.313rem;\n"], ["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 700;\n color: ", ";\n margin-right: 0.313rem;\n"])), function (props) { return props.color; });
|
|
7757
7939
|
var ScrollToTop = function (_a) {
|
|
7758
7940
|
var scrollToTopText = _a.scrollToTopText, onClick = _a.onClick;
|
|
7759
7941
|
var theme = useTheme();
|
|
7760
7942
|
return (jsxs$1(Container$e, __assign({ onClick: onClick, "data-testid": "Container" }, { children: [jsx$1(H1$2, __assign({ color: theme.colors.shades['700'].color }, { children: scrollToTopText }), void 0), jsx$1(Icon.Arrows.ChevronUpSolid, { width: 1.375, height: 1.375, fill: theme.colors.pallete.primary.color }, void 0)] }), void 0));
|
|
7761
7943
|
};
|
|
7762
|
-
var templateObject_1$
|
|
7944
|
+
var templateObject_1$m, templateObject_2$e;
|
|
7763
7945
|
|
|
7764
|
-
var Container$d = newStyled.div(templateObject_1$
|
|
7765
|
-
var H1$1 = newStyled.h1(templateObject_2$
|
|
7946
|
+
var Container$d = newStyled.div(templateObject_1$l || (templateObject_1$l = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #dfefeb;\n padding: 0.75rem 0;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #dfefeb;\n padding: 0.75rem 0;\n"])));
|
|
7947
|
+
var H1$1 = newStyled.h1(templateObject_2$d || (templateObject_2$d = __makeTemplateObject(["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n color: ", ";\n margin-left: 0.625rem;\n"], ["\n margin: 0;\n font-size: 1rem;\n line-height: 1.5rem;\n font-weight: 600;\n color: ", ";\n margin-left: 0.625rem;\n"])), function (props) { return props.color; });
|
|
7766
7948
|
var OrderBar = function (_a) {
|
|
7767
7949
|
var message = _a.message;
|
|
7768
7950
|
var theme = useTheme();
|
|
7769
7951
|
return (jsxs$1(Container$d, { children: [jsx$1(Icon.Actions.Check, { width: 1.25, height: 0.875, fill: "#2F806A" }, void 0), jsx$1(H1$1, __assign({ color: theme.colors.shades['700'].color }, { children: message }), void 0)] }, void 0));
|
|
7770
7952
|
};
|
|
7771
|
-
var templateObject_1$
|
|
7953
|
+
var templateObject_1$l, templateObject_2$d;
|
|
7772
7954
|
|
|
7773
|
-
var TableElement = newStyled.table(templateObject_1$
|
|
7774
|
-
var TableCell = newStyled.td(templateObject_2$
|
|
7775
|
-
var TableHead = newStyled.th(templateObject_3$
|
|
7776
|
-
var TableRow = newStyled.tr(templateObject_4$
|
|
7955
|
+
var TableElement = newStyled.table(templateObject_1$k || (templateObject_1$k = __makeTemplateObject(["\n box-sizing: border-box;\n border-radius: 0.5rem;\n border: 0.063rem solid ", ";\n border-spacing: 0;\n font-size: 0.875rem;\n line-height: 3.125rem;\n width: 100%;\n color: ", ";\n"], ["\n box-sizing: border-box;\n border-radius: 0.5rem;\n border: 0.063rem solid ", ";\n border-spacing: 0;\n font-size: 0.875rem;\n line-height: 3.125rem;\n width: 100%;\n color: ", ";\n"])), function (props) { return props.borderColor; }, function (props) { return props.color; });
|
|
7956
|
+
var TableCell = newStyled.td(templateObject_2$c || (templateObject_2$c = __makeTemplateObject(["\n border-bottom: 0.063rem solid ", ";\n border-right: 0.063rem solid ", ";\n padding: 0 1.25rem;\n text-align: center;\n\n &:last-child {\n border-right: none;\n }\n\n &:first-of-type {\n font-weight: 700;\n }\n"], ["\n border-bottom: 0.063rem solid ", ";\n border-right: 0.063rem solid ", ";\n padding: 0 1.25rem;\n text-align: center;\n\n &:last-child {\n border-right: none;\n }\n\n &:first-of-type {\n font-weight: 700;\n }\n"])), function (props) { return props.borderColor; }, function (props) { return props.borderColor; });
|
|
7957
|
+
var TableHead = newStyled.th(templateObject_3$9 || (templateObject_3$9 = __makeTemplateObject(["\n border-bottom: 0.063rem solid ", ";\n border-right: 0.063rem solid ", ";\n font-weight: 700;\n\n &:last-child {\n border-right: none;\n }\n"], ["\n border-bottom: 0.063rem solid ", ";\n border-right: 0.063rem solid ", ";\n font-weight: 700;\n\n &:last-child {\n border-right: none;\n }\n"])), function (props) { return props.borderColor; }, function (props) { return props.borderColor; });
|
|
7958
|
+
var TableRow = newStyled.tr(templateObject_4$4 || (templateObject_4$4 = __makeTemplateObject(["\n &:last-child {\n td {\n border-bottom: none;\n }\n }\n\n &.background {\n background-color: ", ";\n }\n"], ["\n &:last-child {\n td {\n border-bottom: none;\n }\n }\n\n &.background {\n background-color: ", ";\n }\n"])), function (props) { return props.backgroundColor; });
|
|
7777
7959
|
var SizeTable = function (_a) {
|
|
7778
7960
|
var headers = _a.headers, data = _a.data;
|
|
7779
7961
|
var theme = useTheme();
|
|
7780
7962
|
return (jsxs$1(TableElement, __assign({ color: theme.colors.shades['700'].color, borderColor: theme.colors.shades['100'].color }, { children: [jsx$1("thead", { children: jsx$1(TableRow, __assign({ backgroundColor: theme.colors.shades['10'].color }, { children: headers.map(function (header, index) { return (jsx$1(TableHead, __assign({ borderColor: theme.colors.shades['100'].color }, { children: header }), index)); }) }), void 0) }, void 0), jsx$1("tbody", { children: data.map(function (row, index) { return (jsx$1(TableRow, __assign({ className: index % 2 !== 0 ? '' : 'background', backgroundColor: theme.colors.shades['10'].color }, { children: row.map(function (cell, index) { return (jsx$1(TableCell, __assign({ borderColor: theme.colors.shades['100'].color }, { children: cell }), index)); }) }), index)); }) }, void 0)] }), void 0));
|
|
7781
7963
|
};
|
|
7782
|
-
var templateObject_1$
|
|
7964
|
+
var templateObject_1$k, templateObject_2$c, templateObject_3$9, templateObject_4$4;
|
|
7783
7965
|
|
|
7784
|
-
var
|
|
7785
|
-
var
|
|
7786
|
-
var src = _a.src, alt = _a.alt, height = _a.height, width = _a.width, borderRadius = _a.borderRadius, objectFit = _a.objectFit, objectPosition = _a.objectPosition;
|
|
7787
|
-
return (jsx$1(Img, { src: src, alt: alt, height: height, width: width, borderRadius: borderRadius, objectFit: objectFit, objectPosition: objectPosition }, void 0));
|
|
7788
|
-
};
|
|
7789
|
-
var templateObject_1$l;
|
|
7790
|
-
|
|
7791
|
-
var Container$c = newStyled.div(templateObject_1$k || (templateObject_1$k = __makeTemplateObject(["\n display: flex;\n flex-direction: row;\n width: auto;\n"], ["\n display: flex;\n flex-direction: row;\n width: auto;\n"])));
|
|
7792
|
-
var DescriptionContainer = newStyled.div(templateObject_2$c || (templateObject_2$c = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n ", ";\n width: 100%;\n"], ["\n display: flex;\n flex-direction: column;\n ", ";\n width: 100%;\n"])), function (_a) {
|
|
7966
|
+
var Container$c = newStyled.div(templateObject_1$j || (templateObject_1$j = __makeTemplateObject(["\n display: flex;\n flex-direction: row;\n width: auto;\n"], ["\n display: flex;\n flex-direction: row;\n width: auto;\n"])));
|
|
7967
|
+
var DescriptionContainer = newStyled.div(templateObject_2$b || (templateObject_2$b = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n ", ";\n width: 100%;\n"], ["\n display: flex;\n flex-direction: column;\n ", ";\n width: 100%;\n"])), function (_a) {
|
|
7793
7968
|
var theme = _a.theme;
|
|
7794
7969
|
return mediaQueries({ theme: theme })({
|
|
7795
7970
|
marginLeft: ['0.938rem', '1.875rem'],
|
|
@@ -7815,7 +7990,7 @@ var Subtitle = newStyled.h3(function (_a) {
|
|
|
7815
7990
|
margin: '0.063rem 0',
|
|
7816
7991
|
});
|
|
7817
7992
|
});
|
|
7818
|
-
var PriceContainer = newStyled.div(templateObject_3$
|
|
7993
|
+
var PriceContainer = newStyled.div(templateObject_3$8 || (templateObject_3$8 = __makeTemplateObject(["\n display: flex;\n ", ";\n height: 100%;\n align-items: end;\n margin-top: 0.219rem;\n"], ["\n display: flex;\n ", ";\n height: 100%;\n align-items: end;\n margin-top: 0.219rem;\n"])), function (_a) {
|
|
7819
7994
|
var withTag = _a.withTag, theme = _a.theme;
|
|
7820
7995
|
return withTag
|
|
7821
7996
|
? mediaQueries({ theme: theme })({
|
|
@@ -7827,9 +8002,9 @@ var PriceContainer = newStyled.div(templateObject_3$9 || (templateObject_3$9 = _
|
|
|
7827
8002
|
var SimpleOrderItem = function (_a) {
|
|
7828
8003
|
var title = _a.title, subtitle = _a.subtitle, image = _a.image, price = _a.price, tag = _a.tag;
|
|
7829
8004
|
var theme = useTheme();
|
|
7830
|
-
return (jsxs$1(Container$c, { children: [jsx$1(Image
|
|
8005
|
+
return (jsxs$1(Container$c, { children: [jsx$1(Image, { src: image.src, alt: image.alt, width: "4.063rem", height: "5.375rem", objectFit: "cover", objectPosition: "center" }, void 0), jsxs$1(DescriptionContainer, __assign({ "data-testid": "order-item-description-container", theme: theme }, { children: [jsx$1(Title, __assign({ color: theme.colors.shades['700'].color }, { children: title }), void 0), jsx$1(Subtitle, __assign({ color: theme.colors.shades['700'].color }, { children: subtitle }), void 0), jsxs$1(PriceContainer, __assign({ "data-testid": "order-item-price-container", withTag: !!tag, theme: theme }, { children: [tag && (jsx$1(OfferBanner, { discountAppliedText: tag === null || tag === void 0 ? void 0 : tag.text, backgroundColor: tag === null || tag === void 0 ? void 0 : tag.backgroundColor }, void 0)), jsx$1(PriceLabel, { finalPrice: price.finalPrice, originalPrice: price.originalPrice, color: price.color || theme.colors.shades['700'].color, size: ComponentSize.Small }, void 0)] }), void 0)] }), void 0)] }, void 0));
|
|
7831
8006
|
};
|
|
7832
|
-
var templateObject_1$
|
|
8007
|
+
var templateObject_1$j, templateObject_2$b, templateObject_3$8;
|
|
7833
8008
|
|
|
7834
8009
|
function formatDate(date) {
|
|
7835
8010
|
var day = date.getDate();
|
|
@@ -7838,47 +8013,47 @@ function formatDate(date) {
|
|
|
7838
8013
|
return month < 10 ? "".concat(day, "/0").concat(month, "/").concat(year) : "".concat(day, "/").concat(month, "/").concat(year);
|
|
7839
8014
|
}
|
|
7840
8015
|
|
|
7841
|
-
var Container$b = newStyled.div(templateObject_1$
|
|
7842
|
-
var Heading = newStyled.div(templateObject_2$
|
|
8016
|
+
var Container$b = newStyled.div(templateObject_1$i || (templateObject_1$i = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n width: auto;\n color: #292929;\n"], ["\n display: flex;\n flex-direction: column;\n width: auto;\n color: #292929;\n"])));
|
|
8017
|
+
var Heading = newStyled.div(templateObject_2$a || (templateObject_2$a = __makeTemplateObject(["\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n width: 100%;\n ", ";\n text-align: right;\n margin-bottom: 10px;\n"], ["\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n width: 100%;\n ", ";\n text-align: right;\n margin-bottom: 10px;\n"])), function (_a) {
|
|
7843
8018
|
var theme = _a.theme;
|
|
7844
8019
|
return mediaQueries({ theme: theme })({
|
|
7845
8020
|
fontSize: ['14px', '16px'],
|
|
7846
8021
|
lineHeight: ['22px', '24px'],
|
|
7847
8022
|
});
|
|
7848
8023
|
});
|
|
7849
|
-
var Content = newStyled.div(templateObject_3$
|
|
8024
|
+
var Content = newStyled.div(templateObject_3$7 || (templateObject_3$7 = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n ", ";\n"], ["\n display: flex;\n justify-content: space-between;\n ", ";\n"])), function (_a) {
|
|
7850
8025
|
var theme = _a.theme;
|
|
7851
8026
|
return mediaQueries({ theme: theme })({
|
|
7852
8027
|
flexDirection: ['column', 'row'],
|
|
7853
8028
|
});
|
|
7854
8029
|
});
|
|
7855
|
-
var ReviewContainer = newStyled.div(templateObject_4$
|
|
8030
|
+
var ReviewContainer = newStyled.div(templateObject_4$3 || (templateObject_4$3 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n ", ";\n"], ["\n display: flex;\n flex-direction: column;\n ", ";\n"])), function (_a) {
|
|
7856
8031
|
var theme = _a.theme;
|
|
7857
8032
|
return mediaQueries({ theme: theme })({
|
|
7858
8033
|
margin: ['0 0 8px 0', '0 50px 0 0'],
|
|
7859
8034
|
});
|
|
7860
8035
|
});
|
|
7861
|
-
var H2 = newStyled.h2(templateObject_5$
|
|
8036
|
+
var H2 = newStyled.h2(templateObject_5$2 || (templateObject_5$2 = __makeTemplateObject(["\n font-weight: 600;\n ", ";\n margin: 0;\n"], ["\n font-weight: 600;\n ", ";\n margin: 0;\n"])), function (_a) {
|
|
7862
8037
|
var theme = _a.theme;
|
|
7863
8038
|
return mediaQueries({ theme: theme })({
|
|
7864
8039
|
fontSize: ['16px', '18px'],
|
|
7865
8040
|
lineHeight: ['24px', '28px'],
|
|
7866
8041
|
});
|
|
7867
8042
|
});
|
|
7868
|
-
var H3$1 = newStyled.h3(templateObject_6$
|
|
8043
|
+
var H3$1 = newStyled.h3(templateObject_6$2 || (templateObject_6$2 = __makeTemplateObject(["\n font-size: 16px;\n line-height: 24px;\n ", ";\n margin: 10px 0 8px;\n"], ["\n font-size: 16px;\n line-height: 24px;\n ", ";\n margin: 10px 0 8px;\n"])), function (_a) {
|
|
7869
8044
|
var theme = _a.theme;
|
|
7870
8045
|
return mediaQueries({ theme: theme })({
|
|
7871
8046
|
fontSize: ['14px', '16px'],
|
|
7872
8047
|
lineHeight: ['22px', '24px'],
|
|
7873
8048
|
});
|
|
7874
8049
|
});
|
|
7875
|
-
var P = newStyled.p(templateObject_7
|
|
8050
|
+
var P = newStyled.p(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n font-weight: normal;\n font-size: 16px;\n line-height: 24px;\n margin: 0;\n"], ["\n font-weight: normal;\n font-size: 16px;\n line-height: 24px;\n margin: 0;\n"])));
|
|
7876
8051
|
var Review = function (_a) {
|
|
7877
8052
|
var reviewerName = _a.reviewerName, date = _a.date, rating = _a.rating, stars = _a.stars, title = _a.title, description = _a.description, image = _a.image;
|
|
7878
8053
|
var theme = useTheme();
|
|
7879
|
-
return (jsxs$1(Container$b, { children: [jsxs$1(Heading, __assign({ theme: theme }, { children: [jsx$1(H2, __assign({ theme: theme }, { children: reviewerName }), void 0), formatDate(date)] }), void 0), jsx$1(StarList, { starsNumber: 5, rating: rating, fill: stars.color, size: stars.size }, void 0), jsxs$1(Content, __assign({ "data-testid": "review-content", theme: theme }, { children: [jsxs$1(ReviewContainer, __assign({ theme: theme }, { children: [jsx$1(H3$1, __assign({ theme: theme }, { children: title }), void 0), jsx$1(P, { children: description }, void 0)] }), void 0), jsx$1(Image
|
|
8054
|
+
return (jsxs$1(Container$b, { children: [jsxs$1(Heading, __assign({ theme: theme }, { children: [jsx$1(H2, __assign({ theme: theme }, { children: reviewerName }), void 0), formatDate(date)] }), void 0), jsx$1(StarList, { starsNumber: 5, rating: rating, fill: stars.color, size: stars.size }, void 0), jsxs$1(Content, __assign({ "data-testid": "review-content", theme: theme }, { children: [jsxs$1(ReviewContainer, __assign({ theme: theme }, { children: [jsx$1(H3$1, __assign({ theme: theme }, { children: title }), void 0), jsx$1(P, { children: description }, void 0)] }), void 0), jsx$1(Image, { src: image.src, alt: image.alt, width: "7.5rem", height: "10rem" }, void 0)] }), void 0)] }, void 0));
|
|
7880
8055
|
};
|
|
7881
|
-
var templateObject_1$
|
|
8056
|
+
var templateObject_1$i, templateObject_2$a, templateObject_3$7, templateObject_4$3, templateObject_5$2, templateObject_6$2, templateObject_7;
|
|
7882
8057
|
|
|
7883
8058
|
var Button$3 = newStyled.button(function () { return ({
|
|
7884
8059
|
background: 'transparent',
|
|
@@ -12121,14 +12296,14 @@ var Slider = /*#__PURE__*/function (_React$Component) {
|
|
|
12121
12296
|
return Slider;
|
|
12122
12297
|
}(React.Component);
|
|
12123
12298
|
|
|
12124
|
-
var StyledSlider = newStyled(Slider)(templateObject_1$
|
|
12299
|
+
var StyledSlider = newStyled(Slider)(templateObject_1$h || (templateObject_1$h = __makeTemplateObject(["\n .slick-dots {\n position: static;\n display: flex !important;\n justify-content: center;\n column-gap: ", ";\n margin-top: ", ";\n }\n .slick-prev {\n left: ", ";\n }\n .slick-next {\n right: ", ";\n }\n .slick-prev,\n .slick-next {\n width: fit-content;\n height: fit-content;\n }\n .slick-prev:before,\n .slick-next:before {\n content: none;\n }\n .slick-dots li {\n margin: 0;\n width: auto;\n line-height: 0;\n height: auto;\n }\n"], ["\n .slick-dots {\n position: static;\n display: flex !important;\n justify-content: center;\n column-gap: ", ";\n margin-top: ", ";\n }\n .slick-prev {\n left: ", ";\n }\n .slick-next {\n right: ", ";\n }\n .slick-prev,\n .slick-next {\n width: fit-content;\n height: fit-content;\n }\n .slick-prev:before,\n .slick-next:before {\n content: none;\n }\n .slick-dots li {\n margin: 0;\n width: auto;\n line-height: 0;\n height: auto;\n }\n"])), function (props) { return "".concat(props.dotsSpacing, "rem"); }, function (props) { return "".concat(props.dotListMarginTop, "rem"); }, function (_a) {
|
|
12125
12300
|
var arrowPaddingOffset = _a.arrowPaddingOffset, _b = _a.arrowPadding, arrowPadding = _b === void 0 ? 0 : _b;
|
|
12126
12301
|
return "-".concat(arrowPaddingOffset + arrowPadding, "rem");
|
|
12127
12302
|
}, function (_a) {
|
|
12128
12303
|
var arrowPaddingOffset = _a.arrowPaddingOffset, _b = _a.arrowPadding, arrowPadding = _b === void 0 ? 0 : _b;
|
|
12129
12304
|
return "-".concat(arrowPaddingOffset + arrowPadding, "rem");
|
|
12130
12305
|
});
|
|
12131
|
-
var templateObject_1$
|
|
12306
|
+
var templateObject_1$h;
|
|
12132
12307
|
|
|
12133
12308
|
var getStylesBySize$1 = function (size) {
|
|
12134
12309
|
// rem units
|
|
@@ -12187,13 +12362,13 @@ var SliderNavigation = function (_a) {
|
|
|
12187
12362
|
} }, { children: jsx(StyledSlider, __assign({}, settings, { arrowPadding: arrows && arrows.arrowPadding, dotListMarginTop: dotListMarginTop, arrowPaddingOffset: arrows ? arrows.arrowWidth : 0, dotsSpacing: styles.dotsSpacing }, { children: children }), void 0) }), void 0));
|
|
12188
12363
|
};
|
|
12189
12364
|
|
|
12190
|
-
var List = newStyled.ul(templateObject_1$
|
|
12191
|
-
var Item = newStyled.li(templateObject_2$
|
|
12192
|
-
var DropdownWrapper = newStyled.div(templateObject_3$
|
|
12193
|
-
var ArrowContainer = newStyled.div(templateObject_4$
|
|
12194
|
-
var StyledDropdown = newStyled.ul(templateObject_5$
|
|
12195
|
-
var DropdownItem = newStyled.li(templateObject_6$
|
|
12196
|
-
var templateObject_1$
|
|
12365
|
+
var List = newStyled.ul(templateObject_1$g || (templateObject_1$g = __makeTemplateObject(["\n display: flex;\n margin: 0;\n padding: 0;\n"], ["\n display: flex;\n margin: 0;\n padding: 0;\n"])));
|
|
12366
|
+
var Item = newStyled.li(templateObject_2$9 || (templateObject_2$9 = __makeTemplateObject(["\n width: 1.25rem;\n list-style: none;\n margin-right: 1.5rem;\n position: relative;\n line-height: 0;\n\n &:last-child {\n margin-right: 0;\n }\n\n &:hover {\n .dropdownWrapper {\n visibility: visible;\n }\n }\n"], ["\n width: 1.25rem;\n list-style: none;\n margin-right: 1.5rem;\n position: relative;\n line-height: 0;\n\n &:last-child {\n margin-right: 0;\n }\n\n &:hover {\n .dropdownWrapper {\n visibility: visible;\n }\n }\n"])));
|
|
12367
|
+
var DropdownWrapper = newStyled.div(templateObject_3$6 || (templateObject_3$6 = __makeTemplateObject(["\n right: -0.938rem;\n min-width: 9.375rem;\n position: absolute;\n padding-top: 0.625rem;\n margin-top: -0.188rem;\n width: max-content;\n visibility: hidden;\n"], ["\n right: -0.938rem;\n min-width: 9.375rem;\n position: absolute;\n padding-top: 0.625rem;\n margin-top: -0.188rem;\n width: max-content;\n visibility: hidden;\n"])));
|
|
12368
|
+
var ArrowContainer = newStyled.div(templateObject_4$2 || (templateObject_4$2 = __makeTemplateObject(["\n transform: rotate(180deg);\n display: flex;\n justify-content: flex-start;\n margin-bottom: -0.063rem;\n padding-left: 0.938rem;\n"], ["\n transform: rotate(180deg);\n display: flex;\n justify-content: flex-start;\n margin-bottom: -0.063rem;\n padding-left: 0.938rem;\n"])));
|
|
12369
|
+
var StyledDropdown = newStyled.ul(templateObject_5$1 || (templateObject_5$1 = __makeTemplateObject(["\n margin: 0;\n padding: 0;\n border: 0.063rem solid ", ";\n border-radius: 0.5rem;\n display: flex;\n flex-direction: column;\n background-color: #ffffff;\n"], ["\n margin: 0;\n padding: 0;\n border: 0.063rem solid ", ";\n border-radius: 0.5rem;\n display: flex;\n flex-direction: column;\n background-color: #ffffff;\n"])), function (props) { return props.borderColor; });
|
|
12370
|
+
var DropdownItem = newStyled.li(templateObject_6$1 || (templateObject_6$1 = __makeTemplateObject(["\n list-style: none;\n padding: 0.813rem;\n border-bottom: 0.063rem solid ", ";\n font-size: 0.875rem;\n line-height: 1.125rem;\n font-weight: 400;\n color: ", ";\n cursor: pointer;\n user-select: none;\n\n &:hover {\n background-color: ", ";\n }\n\n &:last-child {\n border-bottom: none;\n border-radius: 0 0 0.5rem 0.5rem;\n }\n\n &:first-of-type {\n border-radius: 0.5rem 0.5rem 0 0;\n }\n\n &:only-child {\n border-radius: 0.5rem;\n }\n"], ["\n list-style: none;\n padding: 0.813rem;\n border-bottom: 0.063rem solid ", ";\n font-size: 0.875rem;\n line-height: 1.125rem;\n font-weight: 400;\n color: ", ";\n cursor: pointer;\n user-select: none;\n\n &:hover {\n background-color: ", ";\n }\n\n &:last-child {\n border-bottom: none;\n border-radius: 0 0 0.5rem 0.5rem;\n }\n\n &:first-of-type {\n border-radius: 0.5rem 0.5rem 0 0;\n }\n\n &:only-child {\n border-radius: 0.5rem;\n }\n"])), function (props) { return props.borderColor; }, function (props) { return props.color; }, function (props) { return props.hoverColor; });
|
|
12371
|
+
var templateObject_1$g, templateObject_2$9, templateObject_3$6, templateObject_4$2, templateObject_5$1, templateObject_6$1;
|
|
12197
12372
|
|
|
12198
12373
|
var DropdownListIcons = function (_a) {
|
|
12199
12374
|
var items = _a.items;
|
|
@@ -12206,7 +12381,7 @@ var Dropdown = function (_a) {
|
|
|
12206
12381
|
return (jsxs$1(DropdownWrapper, __assign({ className: "dropdownWrapper", "data-testid": "Dropdown-wrapper" }, { children: [jsx$1(ArrowContainer, { children: jsx$1(TooltipArrow, { stroke: theme.colors.shades['200'].color, fill: "#fff", width: 1.25, height: 0.75 }, void 0) }, void 0), jsx$1(StyledDropdown, __assign({ borderColor: theme.colors.shades['200'].color }, { children: items.map(function (item, index) { return (jsx$1(DropdownItem, __assign({ onClick: item.callback, borderColor: theme.colors.shades['200'].color, color: theme.colors.shades['550'].color, hoverColor: theme.colors.shades['10'].color }, { children: item.description }), index)); }) }), void 0)] }), void 0));
|
|
12207
12382
|
};
|
|
12208
12383
|
|
|
12209
|
-
var StyledButton = newStyled(BaseButton)(templateObject_1$
|
|
12384
|
+
var StyledButton = newStyled(BaseButton)(templateObject_1$f || (templateObject_1$f = __makeTemplateObject(["\n width: 12.5rem;\n height: 2.5rem;\n background-color: ", ";\n cursor: pointer;\n border: none;\n\n &:hover {\n background-color: ", ";\n }\n"], ["\n width: 12.5rem;\n height: 2.5rem;\n background-color: ", ";\n cursor: pointer;\n border: none;\n\n &:hover {\n background-color: ", ";\n }\n"])), function (props) { return props.backgroundColor; }, function (props) { return props.hoverBackgroundColor; });
|
|
12210
12385
|
var AmazonButton = function (_a) {
|
|
12211
12386
|
var onClick = _a.onClick;
|
|
12212
12387
|
return (jsx$1(StyledButton, __assign({ backgroundColor: "#FED865", hoverBackgroundColor: "#F1CB58", onClick: onClick }, { children: jsx$1(Icon.Payment.Amazon, { width: 5.375, height: 1.25 }, void 0) }), void 0));
|
|
@@ -12215,23 +12390,23 @@ var PaypalButton = function (_a) {
|
|
|
12215
12390
|
var onClick = _a.onClick;
|
|
12216
12391
|
return (jsx$1(StyledButton, __assign({ backgroundColor: "#ffc439", hoverBackgroundColor: "#F4BF41", onClick: onClick }, { children: jsx$1(Icon.Payment.Paypal, { width: 4.938, height: 1.25 }, void 0) }), void 0));
|
|
12217
12392
|
};
|
|
12218
|
-
var templateObject_1$
|
|
12393
|
+
var templateObject_1$f;
|
|
12219
12394
|
|
|
12220
|
-
var Wrapper = newStyled.div(templateObject_1$
|
|
12221
|
-
var Col = newStyled.div(templateObject_2$
|
|
12222
|
-
var Row = newStyled.div(templateObject_3$
|
|
12395
|
+
var Wrapper = newStyled.div(templateObject_1$e || (templateObject_1$e = __makeTemplateObject(["\n display: flex;\n align-items: center;\n padding: 0.625rem 1.25rem;\n background-color: ", ";\n width: 36.875rem;\n max-width: 100%;\n border-radius: 0.5rem;\n\n img {\n margin-right: ", ";\n }\n"], ["\n display: flex;\n align-items: center;\n padding: 0.625rem 1.25rem;\n background-color: ", ";\n width: 36.875rem;\n max-width: 100%;\n border-radius: 0.5rem;\n\n img {\n margin-right: ", ";\n }\n"])), function (props) { return props.backgroundColor; }, function (props) { return (props.rightToLeft ? '0' : '1.25rem'); });
|
|
12396
|
+
var Col = newStyled.div(templateObject_2$8 || (templateObject_2$8 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n"], ["\n display: flex;\n flex-direction: column;\n"])));
|
|
12397
|
+
var Row = newStyled.div(templateObject_3$5 || (templateObject_3$5 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n width: 100%;\n margin-left: 10px;\n\n ", "};\n"], ["\n display: flex;\n align-items: center;\n width: 100%;\n margin-left: 10px;\n\n ", "};\n"])), function (props) {
|
|
12223
12398
|
return props.rightToLeft &&
|
|
12224
12399
|
"\n flex-direction: row-reverse;\n justify-content: space-between;\n ";
|
|
12225
12400
|
});
|
|
12226
|
-
var H5 = newStyled.h5(templateObject_4$
|
|
12227
|
-
var H3 = newStyled.h3(templateObject_5
|
|
12228
|
-
var FreeShipping = newStyled.span(templateObject_6
|
|
12401
|
+
var H5 = newStyled.h5(templateObject_4$1 || (templateObject_4$1 = __makeTemplateObject(["\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 500;\n margin-bottom: 0.125rem;\n margin: 0;\n color: ", ";\n"], ["\n font-size: 0.875rem;\n line-height: 1.375rem;\n font-weight: 500;\n margin-bottom: 0.125rem;\n margin: 0;\n color: ", ";\n"])), function (props) { return props.color; });
|
|
12402
|
+
var H3 = newStyled.h3(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n font-size: 1.125rem;\n line-height: 1.75rem;\n font-weight: 700;\n margin: 0;\n color: ", ";\n"], ["\n font-size: 1.125rem;\n line-height: 1.75rem;\n font-weight: 700;\n margin: 0;\n color: ", ";\n"])), function (props) { return props.color; });
|
|
12403
|
+
var FreeShipping = newStyled.span(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n font-weight: 600;\n color: ", ";\n"], ["\n font-weight: 600;\n color: ", ";\n"])), function (props) { return props.color; });
|
|
12229
12404
|
var CrossSellCheckbox = function (_a) {
|
|
12230
12405
|
var imageURL = _a.imageURL, title = _a.title, description = _a.description, freeShippingText = _a.freeShippingText, rightToLeft = _a.rightToLeft, onChange = _a.onChange;
|
|
12231
12406
|
var theme = useTheme();
|
|
12232
|
-
return (jsxs$1(Wrapper, __assign({ backgroundColor: theme.colors.shades['10'].color, rightToLeft: Boolean(rightToLeft) }, { children: [jsx$1(Checkbox, { text: "", id: "checkbox", onChange: onChange, size: ComponentSize.Small, variant: "secondary" }, void 0), jsxs$1(Row, __assign({ rightToLeft: Boolean(rightToLeft) }, { children: [jsx$1(Image
|
|
12407
|
+
return (jsxs$1(Wrapper, __assign({ backgroundColor: theme.colors.shades['10'].color, rightToLeft: Boolean(rightToLeft) }, { children: [jsx$1(Checkbox, { text: "", id: "checkbox", onChange: onChange, size: ComponentSize.Small, variant: "secondary" }, void 0), jsxs$1(Row, __assign({ rightToLeft: Boolean(rightToLeft) }, { children: [jsx$1(Image, { src: imageURL, alt: "Cross sell image", borderRadius: "0.5rem" }, void 0), jsxs$1(Col, { children: [jsx$1(H5, __assign({ color: theme.colors.shades['700'].color }, { children: title }), void 0), jsxs$1(H3, __assign({ color: theme.colors.semantic.urgent.color }, { children: [description, jsxs$1(FreeShipping, __assign({ color: theme.colors.shades['700'].color }, { children: [' ', "+ ", freeShippingText] }), void 0)] }), void 0)] }, void 0)] }), void 0)] }), void 0));
|
|
12233
12408
|
};
|
|
12234
|
-
var templateObject_1$
|
|
12409
|
+
var templateObject_1$e, templateObject_2$8, templateObject_3$5, templateObject_4$1, templateObject_5, templateObject_6;
|
|
12235
12410
|
|
|
12236
12411
|
var index = /*#__PURE__*/Object.freeze({
|
|
12237
12412
|
__proto__: null,
|
|
@@ -12246,8 +12421,8 @@ var ImageContainer = newStyled.div(function (_a) {
|
|
|
12246
12421
|
height: height,
|
|
12247
12422
|
});
|
|
12248
12423
|
});
|
|
12249
|
-
var Container$a = newStyled.div(templateObject_1$
|
|
12250
|
-
var H1 = newStyled.h1(templateObject_2$
|
|
12424
|
+
var Container$a = newStyled.div(templateObject_1$d || (templateObject_1$d = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n align-items: center;\n width: min-content;\n"], ["\n display: flex;\n flex-direction: column;\n align-items: center;\n width: min-content;\n"])));
|
|
12425
|
+
var H1 = newStyled.h1(templateObject_2$7 || (templateObject_2$7 = __makeTemplateObject(["\n font-size: 0.875rem;\n font-weight: normal;\n line-height: 1.375rem;\n text-align: center;\n color: ", ";\n margin: 0.25rem 0;\n text-align: ", ";\n"], ["\n font-size: 0.875rem;\n font-weight: normal;\n line-height: 1.375rem;\n text-align: center;\n color: ", ";\n margin: 0.25rem 0;\n text-align: ", ";\n"])), function (props) { return props.theme.colors.pallete.secondary.color; }, function (props) { return props.align; });
|
|
12251
12426
|
var getStylesBySize = function (size) {
|
|
12252
12427
|
switch (size) {
|
|
12253
12428
|
case ComponentSize.Medium:
|
|
@@ -12272,11 +12447,11 @@ var ProductItemMobile = function (_a) {
|
|
|
12272
12447
|
var title = _a.title, image = _a.image, price = _a.price, rating = _a.rating, size = _a.size, tags = _a.tags, _b = _a.alignName, alignName = _b === void 0 ? 'center' : _b;
|
|
12273
12448
|
var theme = useTheme();
|
|
12274
12449
|
var styles = getStylesBySize(size);
|
|
12275
|
-
return (jsxs(Container$a, { children: [tags ? (jsxs(ImageContainer, __assign({ width: styles === null || styles === void 0 ? void 0 : styles.width, height: styles === null || styles === void 0 ? void 0 : styles.height, "data-testid": "tags-image-container" }, { children: [jsx(Image
|
|
12450
|
+
return (jsxs(Container$a, { children: [tags ? (jsxs(ImageContainer, __assign({ width: styles === null || styles === void 0 ? void 0 : styles.width, height: styles === null || styles === void 0 ? void 0 : styles.height, "data-testid": "tags-image-container" }, { children: [jsx(Image, { src: image.src, alt: image.alt, width: "100%", height: "100%" }, void 0), jsx(SeasonOfferTag, { text: tags.seasonOfferTagText, size: ComponentSize.Small, css: { position: 'absolute', top: 0, left: 0 } }, void 0), jsx(CategoryTag, { text: tags.categoryTagText, size: ComponentSize.Small, css: { position: 'absolute', bottom: '1rem', left: 0 } }, void 0)] }), void 0)) : (jsx(Image, { src: image.src, alt: image.alt, width: styles === null || styles === void 0 ? void 0 : styles.width, height: styles === null || styles === void 0 ? void 0 : styles.height }, void 0)), jsx(H1, __assign({ theme: theme, align: alignName }, { children: title }), void 0), jsx(PriceLabel, { finalPrice: price.finalPrice, originalPrice: price.originalPrice, color: price.color, size: ComponentSize.Small }, void 0), jsx(Rating, { size: ComponentSize.XSmall, rating: rating.rating, reviews: rating.reviews, reviewsText: "" }, void 0)] }, void 0));
|
|
12276
12451
|
};
|
|
12277
|
-
var templateObject_1$
|
|
12452
|
+
var templateObject_1$d, templateObject_2$7;
|
|
12278
12453
|
|
|
12279
|
-
var Container$9 = newStyled.div(templateObject_1$
|
|
12454
|
+
var Container$9 = newStyled.div(templateObject_1$c || (templateObject_1$c = __makeTemplateObject(["\n display: flex;\n row-gap: 1.875rem;\n column-gap: 1.875rem;\n flex-wrap: wrap;\n"], ["\n display: flex;\n row-gap: 1.875rem;\n column-gap: 1.875rem;\n flex-wrap: wrap;\n"])));
|
|
12280
12455
|
function withProductGrid(ProductItemComponent, data) {
|
|
12281
12456
|
function WithProductGrid(props) {
|
|
12282
12457
|
return (jsx$1(Container$9, __assign({ "data-testid": "product-grid-container" }, { children: data.map(function (product, index) { return (jsx$1(ProductItemComponent, __assign({}, product, props), index)); }) }), void 0));
|
|
@@ -12286,18 +12461,18 @@ function withProductGrid(ProductItemComponent, data) {
|
|
|
12286
12461
|
WithProductGrid.displayName = "withGrid(".concat(wrappedComponentName, ")");
|
|
12287
12462
|
return WithProductGrid;
|
|
12288
12463
|
}
|
|
12289
|
-
var templateObject_1$
|
|
12464
|
+
var templateObject_1$c;
|
|
12290
12465
|
|
|
12291
12466
|
var Collection = {
|
|
12292
12467
|
ProductItemMobile: ProductItemMobile,
|
|
12293
12468
|
withProductGrid: withProductGrid,
|
|
12294
12469
|
};
|
|
12295
12470
|
|
|
12296
|
-
var Backdrop = newStyled.div(templateObject_1$
|
|
12471
|
+
var Backdrop = newStyled.div(templateObject_1$b || (templateObject_1$b = __makeTemplateObject(["\n position: fixed;\n z-index: 2;\n left: 0;\n top: 0;\n width: 100%;\n height: 100%;\n overflow: auto;\n transition: background-color 0.3s ease-out;\n\n ", "\n"], ["\n position: fixed;\n z-index: 2;\n left: 0;\n top: 0;\n width: 100%;\n height: 100%;\n overflow: auto;\n transition: background-color 0.3s ease-out;\n\n ", "\n"])), function (_a) {
|
|
12297
12472
|
var isOpen = _a.isOpen, backgroundColor = _a.backgroundColor;
|
|
12298
12473
|
return isOpen ? "background-color: ".concat(backgroundColor, ";") : 'transparent';
|
|
12299
12474
|
});
|
|
12300
|
-
var Sidebar = newStyled.div(templateObject_2$
|
|
12475
|
+
var Sidebar = newStyled.div(templateObject_2$6 || (templateObject_2$6 = __makeTemplateObject(["\n height: 100%;\n width: ", ";\n position: fixed;\n z-index: 3;\n ", ": 0;\n top: 0;\n background-color: ", ";\n overflow-x: hidden;\n transition: transform 0.3s ease-in-out;\n\n ", "\n"], ["\n height: 100%;\n width: ", ";\n position: fixed;\n z-index: 3;\n ", ": 0;\n top: 0;\n background-color: ", ";\n overflow-x: hidden;\n transition: transform 0.3s ease-in-out;\n\n ", "\n"])), function (_a) {
|
|
12301
12476
|
var width = _a.width;
|
|
12302
12477
|
return width;
|
|
12303
12478
|
}, function (_a) {
|
|
@@ -12338,16 +12513,16 @@ var Drawer = function (_a) {
|
|
|
12338
12513
|
}, [isOpen, onClose, onOpen]);
|
|
12339
12514
|
return isMounted ? (jsxs$1("div", { children: [jsx$1(Backdrop, { backgroundColor: backdropColor, isOpen: isOpenState, "data-testid": "Drawer-Backdrop", onClick: onClickOutside && onClickOutside }, void 0), jsx$1(Sidebar, __assign({ position: position, width: width, backgroundColor: backgroundColor, isOpen: isOpenState, "data-testid": "Drawer-Sidebar" }, { children: children }), void 0)] }, void 0)) : null;
|
|
12340
12515
|
};
|
|
12341
|
-
var templateObject_1$
|
|
12516
|
+
var templateObject_1$b, templateObject_2$6;
|
|
12342
12517
|
|
|
12343
|
-
var Container$8 = newStyled.div(templateObject_1$
|
|
12518
|
+
var Container$8 = newStyled.div(templateObject_1$a || (templateObject_1$a = __makeTemplateObject(["\n width: ", ";\n height: ", ";\n"], ["\n width: ", ";\n height: ", ";\n"])), function (_a) {
|
|
12344
12519
|
var size = _a.size;
|
|
12345
12520
|
return (size ? size : '100%');
|
|
12346
12521
|
}, function (_a) {
|
|
12347
12522
|
var size = _a.size;
|
|
12348
12523
|
return (size ? size : '100%');
|
|
12349
12524
|
});
|
|
12350
|
-
var Animation = newStyled.div(templateObject_2$
|
|
12525
|
+
var Animation = newStyled.div(templateObject_2$5 || (templateObject_2$5 = __makeTemplateObject(["\n @keyframes svg--animation {\n 0% {\n transform: rotateZ(0deg);\n }\n 100% {\n transform: rotateZ(360deg);\n }\n }\n width: 100%;\n height: 100%;\n animation: linear infinite svg--animation;\n animation-duration: ", "s;\n"], ["\n @keyframes svg--animation {\n 0% {\n transform: rotateZ(0deg);\n }\n 100% {\n transform: rotateZ(360deg);\n }\n }\n width: 100%;\n height: 100%;\n animation: linear infinite svg--animation;\n animation-duration: ", "s;\n"])), function (_a) {
|
|
12351
12526
|
var animationDuration = _a.animationDuration;
|
|
12352
12527
|
return animationDuration;
|
|
12353
12528
|
});
|
|
@@ -12355,11 +12530,11 @@ var Spinner = function (_a) {
|
|
|
12355
12530
|
var fill = _a.fill, background = _a.background, _b = _a.animationDuration, animationDuration = _b === void 0 ? 1 : _b, _c = _a.complete, complete = _c === void 0 ? false : _c, completeIconStroke = _a.completeIconStroke, size = _a.size;
|
|
12356
12531
|
return (jsx$1(Container$8, __assign({ size: size, "data-testid": "Container" }, { children: complete ? (jsx$1(Icon.Actions.LightCheck, { fill: fill, strokeWidth: completeIconStroke }, void 0)) : (jsx$1(Animation, __assign({ animationDuration: animationDuration, "data-testid": "Animation" }, { children: jsx$1(Icon.Other.Loading, { fill: fill, backgroundColor: background }, void 0) }), void 0)) }), void 0));
|
|
12357
12532
|
};
|
|
12358
|
-
var templateObject_1$
|
|
12533
|
+
var templateObject_1$a, templateObject_2$5;
|
|
12359
12534
|
|
|
12360
|
-
var UL = newStyled.ul(templateObject_1$
|
|
12361
|
-
var LI = newStyled.li(templateObject_2$
|
|
12362
|
-
var CloseIconContainer = newStyled.div(templateObject_3$
|
|
12535
|
+
var UL = newStyled.ul(templateObject_1$9 || (templateObject_1$9 = __makeTemplateObject(["\n margin: 0;\n padding: 0;\n flex-wrap: wrap;\n display: flex;\n max-width: 100%;\n"], ["\n margin: 0;\n padding: 0;\n flex-wrap: wrap;\n display: flex;\n max-width: 100%;\n"])));
|
|
12536
|
+
var LI = newStyled.li(templateObject_2$4 || (templateObject_2$4 = __makeTemplateObject(["\n list-style: none;\n background-color: ", ";\n padding: 0.375rem 0.625rem;\n border-radius: 0.5rem;\n font-size: 0.875rem;\n line-height: 1.125rem;\n color: ", ";\n font-weight: 400;\n margin-right: 0.5rem;\n margin-bottom: 0.5rem;\n display: flex;\n align-items: center;\n"], ["\n list-style: none;\n background-color: ", ";\n padding: 0.375rem 0.625rem;\n border-radius: 0.5rem;\n font-size: 0.875rem;\n line-height: 1.125rem;\n color: ", ";\n font-weight: 400;\n margin-right: 0.5rem;\n margin-bottom: 0.5rem;\n display: flex;\n align-items: center;\n"])), function (props) { return props.backgroundColor; }, function (props) { return props.color; });
|
|
12537
|
+
var CloseIconContainer = newStyled.div(templateObject_3$4 || (templateObject_3$4 = __makeTemplateObject(["\n width: 0.656rem;\n height: 0.656rem;\n display: flex;\n align-items: center;\n margin-left: 0.5rem;\n cursor: pointer;\n"], ["\n width: 0.656rem;\n height: 0.656rem;\n display: flex;\n align-items: center;\n margin-left: 0.5rem;\n cursor: pointer;\n"])));
|
|
12363
12538
|
var Tags = function (_a) {
|
|
12364
12539
|
var _b = _a.color, color = _b === void 0 ? '#fff6ef' : _b, items = _a.items, onCloseClick = _a.onCloseClick;
|
|
12365
12540
|
var theme = useTheme();
|
|
@@ -12367,7 +12542,7 @@ var Tags = function (_a) {
|
|
|
12367
12542
|
return (jsxs$1(LI, __assign({ color: theme.colors.shades['700'].color, backgroundColor: color }, { children: [item, jsx$1(CloseIconContainer, __assign({ "data-testid": "li-close-icon", onClick: function () { return onCloseClick(index); } }, { children: jsx$1(Icon.Actions.Close, { fill: theme.colors.shades['700'].color }, void 0) }), void 0)] }), index));
|
|
12368
12543
|
}) }), void 0));
|
|
12369
12544
|
};
|
|
12370
|
-
var templateObject_1$
|
|
12545
|
+
var templateObject_1$9, templateObject_2$4, templateObject_3$4;
|
|
12371
12546
|
|
|
12372
12547
|
function FilteringDropdown(_a) {
|
|
12373
12548
|
var options = _a.options, _b = _a.disabled, disabled = _b === void 0 ? false : _b, placeHolder = _a.placeHolder, _c = _a.wide, wide = _c === void 0 ? false : _c, _d = _a.sliceAfter, sliceAfter = _d === void 0 ? 100 : _d, _e = _a.filter, filter = _e === void 0 ? false : _e, onChange = _a.onChange;
|
|
@@ -12400,15 +12575,15 @@ function FilteringDropdown(_a) {
|
|
|
12400
12575
|
}) }, void 0)] }), void 0));
|
|
12401
12576
|
}
|
|
12402
12577
|
|
|
12403
|
-
var Container$7 = newStyled.div(templateObject_1$
|
|
12404
|
-
var IconContainer = newStyled.div(templateObject_2$
|
|
12405
|
-
var PageNumbersContainer = newStyled.div(templateObject_3$
|
|
12578
|
+
var Container$7 = newStyled.div(templateObject_1$8 || (templateObject_1$8 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n user-select: none;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n user-select: none;\n"])));
|
|
12579
|
+
var IconContainer = newStyled.div(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n width: 0.531rem;\n height: 0.875rem;\n display: flex;\n align-items: center;\n cursor: pointer;\n"], ["\n width: 0.531rem;\n height: 0.875rem;\n display: flex;\n align-items: center;\n cursor: pointer;\n"])));
|
|
12580
|
+
var PageNumbersContainer = newStyled.div(templateObject_3$3 || (templateObject_3$3 = __makeTemplateObject(["\n display: flex;\n ", ";\n"], ["\n display: flex;\n ", ";\n"])), function (_a) {
|
|
12406
12581
|
var theme = _a.theme;
|
|
12407
12582
|
return mediaQueries({ theme: theme })({
|
|
12408
12583
|
margin: ['0 0.75rem', '0 1.25rem'],
|
|
12409
12584
|
});
|
|
12410
12585
|
});
|
|
12411
|
-
var PageNumber = newStyled.span(templateObject_4
|
|
12586
|
+
var PageNumber = newStyled.span(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n font-weight: ", ";\n color: ", ";\n text-align: center;\n cursor: pointer;\n border-bottom: ", ";\n ", ";\n"], ["\n font-weight: ", ";\n color: ", ";\n text-align: center;\n cursor: pointer;\n border-bottom: ", ";\n ", ";\n"])), function (_a) {
|
|
12412
12587
|
var bold = _a.bold;
|
|
12413
12588
|
return (bold ? '700' : '500');
|
|
12414
12589
|
}, function (_a) {
|
|
@@ -12425,7 +12600,7 @@ var PageNumber = newStyled.span(templateObject_4$2 || (templateObject_4$2 = __ma
|
|
|
12425
12600
|
width: ['1.25rem', '1.875rem'],
|
|
12426
12601
|
});
|
|
12427
12602
|
});
|
|
12428
|
-
var templateObject_1$
|
|
12603
|
+
var templateObject_1$8, templateObject_2$3, templateObject_3$3, templateObject_4;
|
|
12429
12604
|
|
|
12430
12605
|
var Pagination = function (_a) {
|
|
12431
12606
|
var from = _a.from, to = _a.to, _b = _a.currentPage, currentPage = _b === void 0 ? from : _b, onChange = _a.onChange, _c = _a.underlineActive, underlineActive = _c === void 0 ? true : _c, _d = _a.boldActive, boldActive = _d === void 0 ? true : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e;
|
|
@@ -12441,101 +12616,6 @@ var Pagination = function (_a) {
|
|
|
12441
12616
|
return (jsxs$1(Container$7, __assign({ "data-testid": "PaginationContainer" }, { children: [jsx$1(IconContainer, __assign({ onClick: function () { return handlePageChange(page - 1); }, "data-testid": "LeftChevron" }, { children: jsx$1(Icon.Arrows.ChevronLeft, { fill: disabled ? theme.colors.shades['250'].color : theme.colors.shades['700'].color }, void 0) }), void 0), jsx$1(PageNumbersContainer, __assign({ "data-testid": "PageNumbersContainer", theme: theme }, { children: new Array(to - from + 1).fill(0).map(function (_, i) { return (jsx$1(PageNumber, __assign({ onClick: function () { return handlePageChange(i + from); }, bold: boldActive && page === i + from, underline: underlineActive && page === i + from, role: 'button', color: disabled ? theme.colors.shades['250'].color : theme.colors.shades['700'].color, borderColor: disabled ? theme.colors.shades['250'].color : theme.colors.shades['700'].color, theme: theme }, { children: i + from }), i)); }) }), void 0), jsx$1(IconContainer, __assign({ onClick: function () { return handlePageChange(page + 1); }, "data-testid": "RightChevron" }, { children: jsx$1(Icon.Arrows.ChevronRight, { fill: disabled ? theme.colors.shades['250'].color : theme.colors.shades['700'].color }, void 0) }), void 0)] }), void 0));
|
|
12442
12617
|
};
|
|
12443
12618
|
|
|
12444
|
-
// This defines which HTML tag to render for each `variant`, it also defines
|
|
12445
|
-
// `variants` styles that are consistent through all themes.
|
|
12446
|
-
var TAGS = {
|
|
12447
|
-
hero1: newStyled.h1(templateObject_1$8 || (templateObject_1$8 = __makeTemplateObject([""], [""]))),
|
|
12448
|
-
hero2: newStyled.h2(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject([""], [""]))),
|
|
12449
|
-
hero3: newStyled.h3(templateObject_3$3 || (templateObject_3$3 = __makeTemplateObject([""], [""]))),
|
|
12450
|
-
display1: newStyled.h1(templateObject_4$1 || (templateObject_4$1 = __makeTemplateObject([""], [""]))),
|
|
12451
|
-
display2: newStyled.h2(templateObject_5 || (templateObject_5 = __makeTemplateObject([""], [""]))),
|
|
12452
|
-
heading1: newStyled.h1(templateObject_6 || (templateObject_6 = __makeTemplateObject([""], [""]))),
|
|
12453
|
-
heading2: newStyled.h2(templateObject_7 || (templateObject_7 = __makeTemplateObject([""], [""]))),
|
|
12454
|
-
heading3: newStyled.h3(templateObject_8 || (templateObject_8 = __makeTemplateObject([""], [""]))),
|
|
12455
|
-
heading4: newStyled.h4(templateObject_9 || (templateObject_9 = __makeTemplateObject([""], [""]))),
|
|
12456
|
-
heading5: newStyled.h5(templateObject_10 || (templateObject_10 = __makeTemplateObject([""], [""]))),
|
|
12457
|
-
heading6: newStyled.h6(templateObject_11 || (templateObject_11 = __makeTemplateObject([""], [""]))),
|
|
12458
|
-
body: newStyled.p(templateObject_12 || (templateObject_12 = __makeTemplateObject([""], [""]))),
|
|
12459
|
-
link: newStyled.a(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n cursor: pointer;\n color: inherit;\n text-decoration: ", ";\n "], ["\n cursor: pointer;\n color: inherit;\n text-decoration: ", ";\n "])), function (props) { return (props.underline ? 'underline' : 'none'); }),
|
|
12460
|
-
button: newStyled.span(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n display: inline-block;\n "], ["\n display: inline-block;\n "]))),
|
|
12461
|
-
pricing: newStyled.span(templateObject_15 || (templateObject_15 = __makeTemplateObject(["\n display: inline-block;\n font-weight: ", ";\n text-decoration: ", ";\n "], ["\n display: inline-block;\n font-weight: ", ";\n text-decoration: ", ";\n "])), function (props) { return (props.original ? 'normal' : 'bold'); }, function (props) { return (props.original ? 'line-through' : 'bold'); }),
|
|
12462
|
-
label: newStyled.label(templateObject_16 || (templateObject_16 = __makeTemplateObject([""], [""]))),
|
|
12463
|
-
tag: newStyled.span(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n display: inline-block;\n text-transform: ", ";\n "], ["\n display: inline-block;\n text-transform: ", ";\n "])), function (props) { return (props.allCaps ? 'uppercase' : ''); }),
|
|
12464
|
-
};
|
|
12465
|
-
var Text = function (_a) {
|
|
12466
|
-
var variant = _a.variant, children = _a.children, size = _a.size, weight = _a.weight, allProps = __rest(_a, ["variant", "children", "size", "weight"]);
|
|
12467
|
-
var theme = useTheme();
|
|
12468
|
-
var Tag = useMemo(function () { return TAGS[variant] || 'p'; }, [variant]);
|
|
12469
|
-
var props = useMemo(function () {
|
|
12470
|
-
var _a;
|
|
12471
|
-
return (__assign(__assign({}, ((_a = DEFAULTS === null || DEFAULTS === void 0 ? void 0 : DEFAULTS[variant]) !== null && _a !== void 0 ? _a : {})), allProps));
|
|
12472
|
-
}, [variant, allProps]);
|
|
12473
|
-
var commonCSS = useMemo(function () {
|
|
12474
|
-
var _a, _b;
|
|
12475
|
-
// These are the common style inside a `variant`.
|
|
12476
|
-
// E.g.: Common styles for all "button".
|
|
12477
|
-
var variantstyle = (_a = theme.typography.variants[variant]) !== null && _a !== void 0 ? _a : {
|
|
12478
|
-
fontSize: 14,
|
|
12479
|
-
lineHeight: 1,
|
|
12480
|
-
};
|
|
12481
|
-
// This allow us to define different styles for different `sizes` inside a `variant`
|
|
12482
|
-
// E.g.: "button-small", "button-regular"
|
|
12483
|
-
//
|
|
12484
|
-
// We use .filter(Boolean) to ignore the `size` on the `variants` that don't have it.
|
|
12485
|
-
// E.g.: "hero1", "display1"
|
|
12486
|
-
var variantName = [variant, size].filter(Boolean).join('-');
|
|
12487
|
-
// These are styles specific to `variation-size`.
|
|
12488
|
-
var variantSizeStyle = (_b = theme.typography.variants[variantName]) !== null && _b !== void 0 ? _b : {};
|
|
12489
|
-
var style = __assign(__assign({ margin: 0, color: theme.colors.text.color }, variantstyle), variantSizeStyle);
|
|
12490
|
-
if (weight) {
|
|
12491
|
-
style.fontWeight = theme.typography.config.weight[weight];
|
|
12492
|
-
}
|
|
12493
|
-
if (props.disabled) {
|
|
12494
|
-
style.opacity = 0.5;
|
|
12495
|
-
style.cursor = 'not-allowed';
|
|
12496
|
-
style.color = theme.colors.text.disabled;
|
|
12497
|
-
}
|
|
12498
|
-
return style;
|
|
12499
|
-
}, [theme, variant, weight, size, props.disabled]);
|
|
12500
|
-
// This is to make TS happy, because `href` doesn't exists on other `variants`
|
|
12501
|
-
var propsHref = props.href;
|
|
12502
|
-
var href = useMemo(function () {
|
|
12503
|
-
// We could use `pointer-events: none` but it prevents us from using
|
|
12504
|
-
// `cursor: not-allowed`, so we're changing the `href` for `disabled` links.
|
|
12505
|
-
if (propsHref != null && props.disabled) {
|
|
12506
|
-
return 'javascript:void(0)';
|
|
12507
|
-
}
|
|
12508
|
-
return propsHref;
|
|
12509
|
-
}, [props.disabled, propsHref]);
|
|
12510
|
-
return (jsx(Tag, __assign({}, props, { css: commonCSS, href: href }, { children: children }), void 0));
|
|
12511
|
-
};
|
|
12512
|
-
var DEFAULTS = {
|
|
12513
|
-
hero1: {
|
|
12514
|
-
weight: 'heavy',
|
|
12515
|
-
},
|
|
12516
|
-
hero2: {
|
|
12517
|
-
weight: 'heavy',
|
|
12518
|
-
},
|
|
12519
|
-
hero3: {
|
|
12520
|
-
weight: 'heavy',
|
|
12521
|
-
},
|
|
12522
|
-
display1: {
|
|
12523
|
-
weight: 'bold',
|
|
12524
|
-
},
|
|
12525
|
-
display2: {
|
|
12526
|
-
weight: 'bold',
|
|
12527
|
-
},
|
|
12528
|
-
body: {
|
|
12529
|
-
size: 'regular',
|
|
12530
|
-
weight: 'regular',
|
|
12531
|
-
},
|
|
12532
|
-
button: {
|
|
12533
|
-
size: 'regular',
|
|
12534
|
-
weight: 'bold',
|
|
12535
|
-
},
|
|
12536
|
-
};
|
|
12537
|
-
var templateObject_1$8, templateObject_2$3, templateObject_3$3, templateObject_4$1, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11, templateObject_12, templateObject_13, templateObject_14, templateObject_15, templateObject_16, templateObject_17;
|
|
12538
|
-
|
|
12539
12619
|
var Container$6 = newStyled.div(templateObject_1$7 || (templateObject_1$7 = __makeTemplateObject(["\n display: flex;\n flex-direction: row;\n width: auto;\n padding: 0.688rem 0rem;\n ", ",\n"], ["\n display: flex;\n flex-direction: row;\n width: auto;\n padding: 0.688rem 0rem;\n ", ",\n"])), function (props) {
|
|
12540
12620
|
return mediaQueries(props)({
|
|
12541
12621
|
borderTop: ["0.063rem solid ".concat(props.theme.colors.shades['100'].color), 'none'],
|
|
@@ -12555,7 +12635,7 @@ var Description = newStyled.div({
|
|
|
12555
12635
|
var ProductItem = function (_a) {
|
|
12556
12636
|
var src = _a.src, title = _a.title, price = _a.price;
|
|
12557
12637
|
var theme = useTheme();
|
|
12558
|
-
return (jsxs$1(Container$6, __assign({ theme: theme }, { children: [jsx$1(Image
|
|
12638
|
+
return (jsxs$1(Container$6, __assign({ theme: theme }, { children: [jsx$1(Image, { src: src, alt: "", width: "4.063rem", height: "5.375rem" }, void 0), jsxs$1(Description, { children: [jsx$1(Text$3, __assign({ variant: "body", weight: "regular", size: "regular" }, { children: title }), void 0), jsx$1(PriceLabel, { finalPrice: price, color: "#C64844", size: ComponentSize.Small }, void 0)] }, void 0)] }), void 0));
|
|
12559
12639
|
};
|
|
12560
12640
|
var templateObject_1$7;
|
|
12561
12641
|
|
|
@@ -12566,7 +12646,7 @@ var Container$5 = newStyled.div({
|
|
|
12566
12646
|
});
|
|
12567
12647
|
var Footer = function (_a) {
|
|
12568
12648
|
var text = _a.text, onClick = _a.onClick;
|
|
12569
|
-
return (jsx$1(Container$5, { children: jsx$1(Text, __assign({ variant: "link", size: "regular", underline: true, onClick: onClick }, { children: text }), void 0) }, void 0));
|
|
12649
|
+
return (jsx$1(Container$5, { children: jsx$1(Text$3, __assign({ variant: "link", size: "regular", underline: true, onClick: onClick }, { children: text }), void 0) }, void 0));
|
|
12570
12650
|
};
|
|
12571
12651
|
|
|
12572
12652
|
var Ul = newStyled.ul({
|
|
@@ -12600,7 +12680,7 @@ var Header = newStyled.div(templateObject_3$2 || (templateObject_3$2 = __makeTem
|
|
|
12600
12680
|
var ResultsPanel = function (_a) {
|
|
12601
12681
|
var options = _a.options, header = _a.header, footer = _a.footer, onClick = _a.onClick, onViewAll = _a.onViewAll, dataTestId = _a.dataTestId;
|
|
12602
12682
|
var theme = useTheme();
|
|
12603
|
-
return (jsxs$1(Container$4, __assign({ "data-testid": dataTestId, theme: theme }, { children: [header && (jsx$1(Header, __assign({ theme: theme }, { children: jsx$1(Text, __assign({ variant: "heading6", weight: "demi" }, { children: header }), void 0) }), void 0)), jsx$1(Ul, { children: options.map(function (item, index) { return (jsx$1(Li, __assign({ theme: theme }, { children: jsx$1(Button$2, __assign({ onClick: function () { return onClick(item); } }, { children: jsx$1(ProductItem, { src: item.src, title: item.title, price: item.price }, void 0) }), void 0) }), index)); }) }, void 0), footer && jsx$1(Footer, { text: footer, onClick: onViewAll }, void 0)] }), void 0));
|
|
12683
|
+
return (jsxs$1(Container$4, __assign({ "data-testid": dataTestId, theme: theme }, { children: [header && (jsx$1(Header, __assign({ theme: theme }, { children: jsx$1(Text$3, __assign({ variant: "heading6", weight: "demi" }, { children: header }), void 0) }), void 0)), jsx$1(Ul, { children: options.map(function (item, index) { return (jsx$1(Li, __assign({ theme: theme }, { children: jsx$1(Button$2, __assign({ onClick: function () { return onClick(item); } }, { children: jsx$1(ProductItem, { src: item.src, title: item.title, price: item.price }, void 0) }), void 0) }), index)); }) }, void 0), footer && jsx$1(Footer, { text: footer, onClick: onViewAll }, void 0)] }), void 0));
|
|
12604
12684
|
};
|
|
12605
12685
|
var templateObject_1$6, templateObject_2$2, templateObject_3$2;
|
|
12606
12686
|
|
|
@@ -12754,15 +12834,14 @@ var SearchBar = function (_a) {
|
|
|
12754
12834
|
}, onViewAll: function () { return onSearch(state.term); } }, void 0))] }), void 0));
|
|
12755
12835
|
};
|
|
12756
12836
|
|
|
12757
|
-
var Container$2 = newStyled.div(templateObject_1$4 || (templateObject_1$4 = __makeTemplateObject(["\n position: relative;\n max-height: 31.875rem;\n
|
|
12758
|
-
var
|
|
12759
|
-
var
|
|
12760
|
-
var BottomTagContainer = newStyled.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"], ["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"])));
|
|
12837
|
+
var Container$2 = newStyled.div(templateObject_1$4 || (templateObject_1$4 = __makeTemplateObject(["\n position: relative;\n max-height: 31.875rem;\n"], ["\n position: relative;\n max-height: 31.875rem;\n"])));
|
|
12838
|
+
var TopTagContainer = newStyled.div(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n position: absolute;\n left: 0;\n top: 0;\n"], ["\n position: absolute;\n left: 0;\n top: 0;\n"])));
|
|
12839
|
+
var BottomTagContainer = newStyled.div(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"], ["\n position: absolute;\n bottom: 3.75rem;\n left: 0;\n"])));
|
|
12761
12840
|
var ImageProductWithTags = function (_a) {
|
|
12762
12841
|
var image = _a.image, DiscountTagElement = _a.DiscountTagElement, BestSellerTagElement = _a.BestSellerTagElement, dataTestId = _a.dataTestId;
|
|
12763
|
-
return (jsxs$1(Container$2, __assign({ "data-testid": dataTestId }, { children: [jsx$1(Image, { src: image.imageUrl, alt: image.alt }, void 0), jsx$1(TopTagContainer, { children: DiscountTagElement }, void 0), jsx$1(BottomTagContainer, { children: BestSellerTagElement }, void 0)] }), void 0));
|
|
12842
|
+
return (jsxs$1(Container$2, __assign({ "data-testid": dataTestId }, { children: [jsx$1(Image, { src: image.imageUrl, alt: image.alt, objectFit: "cover", objectPosition: "center top", width: "100%", height: "510px" }, void 0), jsx$1(TopTagContainer, { children: DiscountTagElement }, void 0), jsx$1(BottomTagContainer, { children: BestSellerTagElement }, void 0)] }), void 0));
|
|
12764
12843
|
};
|
|
12765
|
-
var templateObject_1$4, templateObject_2$1, templateObject_3$1
|
|
12844
|
+
var templateObject_1$4, templateObject_2$1, templateObject_3$1;
|
|
12766
12845
|
|
|
12767
12846
|
var Button = newStyled.button(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n"], ["\n background: transparent;\n border: none;\n padding: 0.188rem 0.625rem;\n"])));
|
|
12768
12847
|
var ArrowButton = function (_a) {
|
|
@@ -12786,29 +12865,19 @@ var NavigationButton = newStyled(ArrowButton)(templateObject_1$1 || (templateObj
|
|
|
12786
12865
|
var RightButton = newStyled(NavigationButton)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n right: 0;\n"], ["\n right: 0;\n"])));
|
|
12787
12866
|
var LeftButton = newStyled(NavigationButton)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n left: 0;\n"], ["\n left: 0;\n"])));
|
|
12788
12867
|
var SlideNavigation = function (_a) {
|
|
12789
|
-
var quantity = _a.quantity,
|
|
12868
|
+
var quantity = _a.quantity, selectedIndex = _a.selectedIndex, onNavigate = _a.onNavigate, dataTestId = _a.dataTestId;
|
|
12869
|
+
var theme = useTheme();
|
|
12790
12870
|
var upperLimit = quantity - 1;
|
|
12791
12871
|
var lowerLimit = 0;
|
|
12792
|
-
|
|
12793
|
-
|
|
12794
|
-
|
|
12795
|
-
|
|
12796
|
-
|
|
12797
|
-
var getNextIndex = function () { return currentIndex + 1; };
|
|
12798
|
-
var getPreviousIndex = function () { return currentIndex - 1; };
|
|
12799
|
-
return (jsxs$1(Fragment$1, { children: [currentIndex > lowerLimit && (jsx$1(LeftButton, { Icon: jsx$1(Icon.Arrows.ChevronLeft, { height: 2.125, width: 1.25, fill: theme.colors.shades['700'].color, opacity: 0.5 }, void 0), onClick: function () {
|
|
12800
|
-
var index = getPreviousIndex();
|
|
12801
|
-
setCurrentIndex(index);
|
|
12802
|
-
onNavigate(index);
|
|
12803
|
-
} }, void 0)), currentIndex < upperLimit && (jsx$1(RightButton, { Icon: jsx$1(Icon.Arrows.ChevronRight, { height: 2.125, width: 1.25, fill: theme.colors.shades['700'].color, opacity: 0.5 }, void 0), onClick: function () {
|
|
12804
|
-
var index = getNextIndex();
|
|
12805
|
-
setCurrentIndex(index);
|
|
12806
|
-
onNavigate(index);
|
|
12807
|
-
} }, void 0)), jsx$1(SlideDots, { quantity: quantity, selectedIndex: currentIndex, containerDataTestId: dataTestId }, void 0)] }, void 0));
|
|
12872
|
+
return (jsxs$1(Fragment$1, { children: [selectedIndex > lowerLimit && (jsx$1(LeftButton, { Icon: jsx$1(Icon.Arrows.ChevronLeft, { height: 2.125, width: 1.25, fill: theme.colors.shades['700'].color, opacity: 0.5 }, void 0), onClick: function () {
|
|
12873
|
+
onNavigate(selectedIndex - 1);
|
|
12874
|
+
} }, void 0)), selectedIndex < upperLimit && (jsx$1(RightButton, { Icon: jsx$1(Icon.Arrows.ChevronRight, { height: 2.125, width: 1.25, fill: theme.colors.shades['700'].color, opacity: 0.5 }, void 0), onClick: function () {
|
|
12875
|
+
onNavigate(selectedIndex + 1);
|
|
12876
|
+
} }, void 0)), jsx$1(SlideDots, { quantity: quantity, selectedIndex: selectedIndex, containerDataTestId: dataTestId }, void 0)] }, void 0));
|
|
12808
12877
|
};
|
|
12809
12878
|
var templateObject_1$1, templateObject_2, templateObject_3;
|
|
12810
12879
|
|
|
12811
|
-
var Container = newStyled.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n height: fit-content;\n
|
|
12880
|
+
var Container = newStyled.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n height: fit-content;\n position: relative;\n max-width: 450px;\n"], ["\n display: flex;\n flex-direction: column;\n height: fit-content;\n position: relative;\n max-width: 450px;\n"])));
|
|
12812
12881
|
var ProductGalleryMobile = function (_a) {
|
|
12813
12882
|
var images = _a.images, selectedValue = _a.selectedValue, DiscountTagElement = _a.DiscountTagElement, BestSellerTagElement = _a.BestSellerTagElement, productImageDataTestId = _a.productImageDataTestId, slideDotsDataTestId = _a.slideDotsDataTestId;
|
|
12814
12883
|
var initialValue = selectedValue && images.includes(selectedValue) ? selectedValue : images[0];
|
|
@@ -12816,9 +12885,38 @@ var ProductGalleryMobile = function (_a) {
|
|
|
12816
12885
|
useEffect(function () {
|
|
12817
12886
|
setSelectedImage(initialValue);
|
|
12818
12887
|
}, [initialValue]);
|
|
12819
|
-
return (jsxs$1(Container, { children: [jsx$1(ImageProductWithTags, { image: selectedImage, DiscountTagElement: DiscountTagElement, BestSellerTagElement: BestSellerTagElement, dataTestId: productImageDataTestId }, void 0), jsx$1(SlideNavigation, { quantity: images.length,
|
|
12888
|
+
return (jsxs$1(Container, { children: [jsx$1(ImageProductWithTags, { image: selectedImage, DiscountTagElement: DiscountTagElement, BestSellerTagElement: BestSellerTagElement, dataTestId: productImageDataTestId }, void 0), jsx$1(SlideNavigation, { quantity: images.length, selectedIndex: images.indexOf(selectedImage), onNavigate: function (index) { return setSelectedImage(images[index]); }, dataTestId: slideDotsDataTestId }, void 0)] }, void 0));
|
|
12820
12889
|
};
|
|
12821
12890
|
var templateObject_1;
|
|
12822
12891
|
|
|
12823
|
-
|
|
12892
|
+
var Portal = function (_a) {
|
|
12893
|
+
var id = _a.id, className = _a.className, children = _a.children;
|
|
12894
|
+
var _b = useState(false), mounted = _b[0], setMounted = _b[1];
|
|
12895
|
+
var container = useRef(null);
|
|
12896
|
+
useEffect(function () {
|
|
12897
|
+
var element = document.getElementById(id);
|
|
12898
|
+
if (element == null) {
|
|
12899
|
+
element = document.createElement('div');
|
|
12900
|
+
element.id = id;
|
|
12901
|
+
document.body.appendChild(element);
|
|
12902
|
+
}
|
|
12903
|
+
if (element == null) {
|
|
12904
|
+
throw new Error("Unable to find/create container (".concat(id, ")"));
|
|
12905
|
+
}
|
|
12906
|
+
element.dataset.testId = id;
|
|
12907
|
+
setMounted(true);
|
|
12908
|
+
container.current = element;
|
|
12909
|
+
}, [id]);
|
|
12910
|
+
useEffect(function () {
|
|
12911
|
+
if (mounted) {
|
|
12912
|
+
container.current.className = className !== null && className !== void 0 ? className : '';
|
|
12913
|
+
}
|
|
12914
|
+
}, [className, mounted]);
|
|
12915
|
+
if (mounted === false) {
|
|
12916
|
+
return null;
|
|
12917
|
+
}
|
|
12918
|
+
return createPortal(children, container.current, id);
|
|
12919
|
+
};
|
|
12920
|
+
|
|
12921
|
+
export { Accordion, AmazonButton, AssetsProvider, Bundle, ButtonPrimary, ButtonSecondary, ButtonSecondaryOutline, Card$1 as Card, CardSectionType, CategoryTag, Checkbox, Collection, ComponentPosition, ComponentSize, index as CrossSell, DeliveryDetails, DiscountTag, Drawer, DropdownListIcons, FilteringDropdown, Tags as FilteringTags, FitPredictor, Icon, IconButton, Image, Input$1 as Input, InputValidationType, MultiColorPicker, OfferBanner, OrderBar, Pagination, PaymentMethod, PaypalButton, Portal, PriceLabel, ProductGallery, ProductGalleryMobile, ProgressBar, RadioGroupInput, RadioInput, Rating, Review, ScrollToTop, SearchBar, SeasonOfferTag, SimpleDropdown, SimpleOrderItem, SingleColorPicker, SizeFitGuide, SizeSelector, SizeTable, SliderNavigation, Spinner, StarList, Text$3 as Text, TextButton, ThemeProvider, ThemeVariables, Timer, Tooltip, Totals, useOnClickOutside, useTheme, useThemeAssets, useWindowDimensions };
|
|
12824
12922
|
//# sourceMappingURL=index.esm.js.map
|