@lookiero/checkout 11.1.0 → 11.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/Expo.js +2 -8
- package/dist/src/ExpoRoot.d.ts +1 -5
- package/dist/src/ExpoRoot.js +7 -6
- package/dist/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.js +3 -2
- package/dist/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.style.js +8 -6
- package/dist/src/infrastructure/ui/components/atoms/price/Price.js +3 -2
- package/dist/src/infrastructure/ui/components/atoms/price/Price.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/atoms/price/Price.style.js +18 -16
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/buttonCheckoutQuestionItem/ButtonCheckoutQuestionItem.js +7 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/buttonCheckoutQuestionItem/ButtonCheckoutQuestionItem.style.d.ts +4 -1
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/buttonCheckoutQuestionItem/ButtonCheckoutQuestionItem.style.js +26 -22
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostDefaultCheckoutQuestionItem/HostDefaultCheckoutQuestionItem.js +3 -2
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostDefaultCheckoutQuestionItem/HostDefaultCheckoutQuestionItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostDefaultCheckoutQuestionItem/HostDefaultCheckoutQuestionItem.style.js +11 -9
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostSelectCheckoutQuestionItem/HostSelectCheckoutQuestionItem.js +3 -2
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostSelectCheckoutQuestionItem/HostSelectCheckoutQuestionItem.style.d.ts +3 -3
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostSelectCheckoutQuestionItem/HostSelectCheckoutQuestionItem.style.js +18 -13
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/IconCheckoutQuestionItem.js +4 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/IconCheckoutQuestionItem.style.d.ts +3 -1
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/IconCheckoutQuestionItem.style.js +14 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Happy.js +5 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Normal.js +5 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Sad.js +5 -5
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.js +2 -1
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.js +25 -23
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.js +5 -3
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.style.js +11 -9
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.d.ts +1 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.js +3 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.style.js +13 -11
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.js +5 -5
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.d.ts +3 -3
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.js +23 -18
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.js +4 -3
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.style.d.ts +4 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.style.js +11 -6
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.d.ts +2 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.js +5 -4
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.style.d.ts +2 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.style.js +15 -12
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.js +4 -3
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.style.d.ts +3 -3
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.style.js +18 -13
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.js +10 -5
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.style.d.ts +10 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.style.js +16 -4
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.js +3 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.style.js +12 -10
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.js +3 -2
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.js +30 -28
- package/dist/src/infrastructure/ui/components/templates/header/Header.js +6 -3
- package/dist/src/infrastructure/ui/components/templates/header/Header.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/templates/header/Header.style.js +17 -15
- package/dist/src/infrastructure/ui/components/templates/header/buttonIconPlaceholder/ButtonIconPlaceholder.js +6 -3
- package/dist/src/infrastructure/ui/components/templates/header/buttonIconPlaceholder/ButtonIconPlaceholder.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/templates/header/buttonIconPlaceholder/ButtonIconPlaceholder.style.js +10 -8
- package/dist/src/infrastructure/ui/components/templates/header/checkoutHeader/CheckoutHeader.js +6 -4
- package/dist/src/infrastructure/ui/components/templates/header/checkoutHeader/CheckoutHeader.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/templates/header/checkoutHeader/CheckoutHeader.style.js +10 -8
- package/dist/src/infrastructure/ui/components/templates/header/itemDetailHeader/ItemDetailHeader.js +6 -4
- package/dist/src/infrastructure/ui/components/templates/header/itemDetailHeader/ItemDetailHeader.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/components/templates/header/itemDetailHeader/ItemDetailHeader.style.js +10 -8
- package/dist/src/infrastructure/ui/components/templates/header/itemHeader/ItemHeader.js +7 -5
- package/dist/src/infrastructure/ui/components/templates/header/itemHeader/ItemHeader.style.d.ts +2 -2
- package/dist/src/infrastructure/ui/components/templates/header/itemHeader/ItemHeader.style.js +11 -9
- package/dist/src/infrastructure/ui/views/App.js +8 -6
- package/dist/src/infrastructure/ui/views/checkout/Checkout.js +12 -10
- package/dist/src/infrastructure/ui/views/checkout/Checkout.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/checkout/Checkout.style.js +63 -61
- package/dist/src/infrastructure/ui/views/checkout/components/deliveryBanner/DeliveryBanner.js +4 -3
- package/dist/src/infrastructure/ui/views/feedback/Feedback.js +3 -2
- package/dist/src/infrastructure/ui/views/feedback/Feedback.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/feedback/Feedback.style.js +13 -11
- package/dist/src/infrastructure/ui/views/item/Item.js +4 -2
- package/dist/src/infrastructure/ui/views/item/Item.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/Item.style.js +21 -19
- package/dist/src/infrastructure/ui/views/item/components/banner/CustomerDecissionBanner.js +3 -2
- package/dist/src/infrastructure/ui/views/item/components/banner/CustomerDecissionBanner.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/components/banner/CustomerDecissionBanner.style.js +11 -9
- package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.js +7 -6
- package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.d.ts +3 -1
- package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.js +26 -22
- package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.js +2 -1
- package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.style.js +28 -26
- package/dist/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.js +7 -6
- package/dist/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.d.ts +6 -3
- package/dist/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.js +23 -18
- package/dist/src/infrastructure/ui/views/item/components/productVariantSlider/ProductVariantSlider.js +13 -6
- package/dist/src/infrastructure/ui/views/item/components/productVariantSlider/ProductVariantSlider.style.d.ts +2 -1
- package/dist/src/infrastructure/ui/views/item/components/productVariantSlider/ProductVariantSlider.style.js +34 -28
- package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.js +5 -3
- package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.style.js +11 -9
- package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.js +7 -7
- package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.d.ts +5 -1
- package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.js +27 -18
- package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.js +3 -2
- package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.style.js +17 -15
- package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.js +3 -2
- package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.style.js +19 -17
- package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.js +6 -5
- package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.style.d.ts +2 -1
- package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.style.js +13 -7
- package/dist/src/infrastructure/ui/views/item/views/productVariant/ProductVariant.js +3 -2
- package/dist/src/infrastructure/ui/views/item/views/productVariant/ProductVariant.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/item/views/productVariant/ProductVariant.style.js +17 -15
- package/dist/src/infrastructure/ui/views/return/components/price/Price.js +3 -2
- package/dist/src/infrastructure/ui/views/return/components/price/Price.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/return/components/price/Price.style.js +18 -16
- package/dist/src/infrastructure/ui/views/return/components/productVariantPreview/ProductVariantPreview.js +10 -9
- package/dist/src/infrastructure/ui/views/return/components/productVariantPreview/ProductVariantPreview.style.d.ts +4 -1
- package/dist/src/infrastructure/ui/views/return/components/productVariantPreview/ProductVariantPreview.style.js +35 -30
- package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.js +12 -8
- package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.js +50 -48
- package/dist/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.js +7 -6
- package/dist/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.style.d.ts +4 -1
- package/dist/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.style.js +43 -38
- package/dist/src/infrastructure/ui/views/summary/Summary.js +12 -10
- package/dist/src/infrastructure/ui/views/summary/Summary.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/summary/Summary.style.js +72 -70
- package/dist/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.js +5 -3
- package/dist/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.style.js +20 -18
- package/dist/src/infrastructure/ui/views/summary/components/pricing/Pricing.js +9 -5
- package/dist/src/infrastructure/ui/views/summary/components/pricing/Pricing.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/summary/components/pricing/Pricing.style.js +15 -13
- package/dist/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/CheckoutItemsTabs.js +19 -7
- package/dist/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/CheckoutItemsTabs.style.d.ts +1 -1
- package/dist/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/CheckoutItemsTabs.style.js +29 -27
- package/dist/src/version.d.ts +1 -1
- package/dist/src/version.js +1 -1
- package/package.json +3 -3
- package/src/Expo.tsx +2 -10
- package/src/ExpoRoot.tsx +8 -10
- package/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.style.ts +8 -6
- package/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.tsx +4 -2
- package/src/infrastructure/ui/components/atoms/price/Price.style.ts +18 -16
- package/src/infrastructure/ui/components/atoms/price/Price.tsx +4 -2
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/buttonCheckoutQuestionItem/ButtonCheckoutQuestionItem.style.ts +34 -31
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/buttonCheckoutQuestionItem/ButtonCheckoutQuestionItem.tsx +9 -5
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostDefaultCheckoutQuestionItem/HostDefaultCheckoutQuestionItem.style.ts +11 -9
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostDefaultCheckoutQuestionItem/HostDefaultCheckoutQuestionItem.tsx +4 -2
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostSelectCheckoutQuestionItem/HostSelectCheckoutQuestionItem.style.ts +19 -13
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/hostSelectCheckoutQuestionItem/HostSelectCheckoutQuestionItem.tsx +4 -2
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/IconCheckoutQuestionItem.style.ts +16 -5
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/IconCheckoutQuestionItem.tsx +6 -6
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Happy.tsx +5 -5
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Normal.tsx +5 -5
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/iconCheckoutQuestionItem/icons/Sad.tsx +5 -5
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.ts +26 -24
- package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.tsx +3 -1
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.style.ts +11 -9
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.tsx +6 -3
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.style.ts +13 -11
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.tsx +4 -2
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.ts +24 -18
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.tsx +6 -5
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.style.ts +11 -6
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.tsx +5 -3
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.style.ts +15 -12
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.tsx +8 -6
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.style.ts +19 -13
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.tsx +5 -3
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.style.ts +16 -4
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.tsx +24 -14
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.style.ts +12 -10
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.tsx +4 -2
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.ts +31 -29
- package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.tsx +4 -2
- package/src/infrastructure/ui/components/templates/header/Header.style.ts +18 -16
- package/src/infrastructure/ui/components/templates/header/Header.tsx +11 -7
- package/src/infrastructure/ui/components/templates/header/buttonIconPlaceholder/ButtonIconPlaceholder.style.ts +10 -8
- package/src/infrastructure/ui/components/templates/header/buttonIconPlaceholder/ButtonIconPlaceholder.tsx +7 -3
- package/src/infrastructure/ui/components/templates/header/checkoutHeader/CheckoutHeader.style.ts +10 -8
- package/src/infrastructure/ui/components/templates/header/checkoutHeader/CheckoutHeader.tsx +7 -4
- package/src/infrastructure/ui/components/templates/header/checkoutHeader/__snapshots__/CheckoutHeader.test.tsx.snap +31 -80
- package/src/infrastructure/ui/components/templates/header/itemDetailHeader/ItemDetailHeader.style.ts +10 -8
- package/src/infrastructure/ui/components/templates/header/itemDetailHeader/ItemDetailHeader.tsx +7 -4
- package/src/infrastructure/ui/components/templates/header/itemDetailHeader/__snapshots__/ItemDetailHeader.test.tsx.snap +31 -80
- package/src/infrastructure/ui/components/templates/header/itemHeader/ItemHeader.style.ts +11 -9
- package/src/infrastructure/ui/components/templates/header/itemHeader/ItemHeader.tsx +8 -5
- package/src/infrastructure/ui/components/templates/header/itemHeader/__snapshots__/ItemHeader.test.tsx.snap +62 -160
- package/src/infrastructure/ui/views/App.tsx +12 -10
- package/src/infrastructure/ui/views/checkout/Checkout.style.ts +63 -61
- package/src/infrastructure/ui/views/checkout/Checkout.tsx +16 -12
- package/src/infrastructure/ui/views/checkout/components/deliveryBanner/DeliveryBanner.tsx +4 -3
- package/src/infrastructure/ui/views/feedback/Feedback.style.ts +13 -11
- package/src/infrastructure/ui/views/feedback/Feedback.tsx +5 -2
- package/src/infrastructure/ui/views/item/Item.style.ts +21 -19
- package/src/infrastructure/ui/views/item/Item.tsx +6 -2
- package/src/infrastructure/ui/views/item/components/banner/CustomerDecissionBanner.style.ts +11 -9
- package/src/infrastructure/ui/views/item/components/banner/CustomerDecissionBanner.tsx +5 -2
- package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.ts +26 -22
- package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.tsx +8 -6
- package/src/infrastructure/ui/views/item/components/itemActions/ItemActions.style.ts +28 -26
- package/src/infrastructure/ui/views/item/components/itemActions/ItemActions.tsx +3 -1
- package/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.ts +23 -18
- package/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.tsx +9 -6
- package/src/infrastructure/ui/views/item/components/productVariantSlider/ProductVariantSlider.style.ts +37 -29
- package/src/infrastructure/ui/views/item/components/productVariantSlider/ProductVariantSlider.tsx +13 -6
- package/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.style.ts +11 -9
- package/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.tsx +6 -3
- package/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.ts +29 -18
- package/src/infrastructure/ui/views/item/components/selectModal/SelectModal.tsx +8 -9
- package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.style.ts +18 -15
- package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.tsx +4 -2
- package/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.style.ts +19 -17
- package/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.tsx +4 -2
- package/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.style.ts +15 -8
- package/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.tsx +7 -6
- package/src/infrastructure/ui/views/item/views/productVariant/ProductVariant.style.ts +17 -15
- package/src/infrastructure/ui/views/item/views/productVariant/ProductVariant.tsx +4 -2
- package/src/infrastructure/ui/views/return/components/price/Price.style.ts +18 -16
- package/src/infrastructure/ui/views/return/components/price/Price.tsx +4 -2
- package/src/infrastructure/ui/views/return/components/productVariantPreview/ProductVariantPreview.style.ts +36 -31
- package/src/infrastructure/ui/views/return/components/productVariantPreview/ProductVariantPreview.tsx +11 -9
- package/src/infrastructure/ui/views/return/components/productVariantPreview/__snapshots__/ProductVariantPreview.test.tsx.snap +11 -12
- package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.ts +50 -48
- package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.tsx +13 -10
- package/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.style.ts +56 -50
- package/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.tsx +8 -6
- package/src/infrastructure/ui/views/shared/components/productVariant/__snapshots__/ProductVariant.test.tsx.snap +18 -0
- package/src/infrastructure/ui/views/summary/Summary.style.ts +84 -82
- package/src/infrastructure/ui/views/summary/Summary.tsx +17 -13
- package/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.style.ts +20 -18
- package/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.tsx +6 -3
- package/src/infrastructure/ui/views/summary/components/collapsiblePricing/__snapshots__/CollapsiblePricing.test.tsx.snap +22 -6
- package/src/infrastructure/ui/views/summary/components/pricing/Pricing.style.ts +15 -13
- package/src/infrastructure/ui/views/summary/components/pricing/Pricing.tsx +15 -10
- package/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/CheckoutItemsTabs.style.ts +29 -27
- package/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/CheckoutItemsTabs.tsx +22 -8
- package/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/__snapshots__/CheckoutItemsTabs.test.tsx.snap +36 -0
|
@@ -1,52 +1,54 @@
|
|
|
1
1
|
import { StyleSheet } from "react-native";
|
|
2
2
|
import { theme } from "@lookiero/sty-psp-ui";
|
|
3
3
|
import { HEADER_HEIGHT } from "../../../../components/templates/header/Header.style";
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
}
|
|
4
|
+
const style = () => {
|
|
5
|
+
const { borderRadius5, colorBgPrimaryLight, colorBgBase, colorTextMedium, space1, space4, space6, space8 } = theme();
|
|
6
|
+
return StyleSheet.create({
|
|
7
|
+
background: {
|
|
8
|
+
backgroundColor: colorBgPrimaryLight,
|
|
9
|
+
},
|
|
10
|
+
description: {
|
|
11
|
+
color: colorTextMedium,
|
|
12
|
+
},
|
|
13
|
+
desktopInfo: {
|
|
14
|
+
borderTopLeftRadius: borderRadius5,
|
|
15
|
+
borderTopRightRadius: borderRadius5,
|
|
16
|
+
},
|
|
17
|
+
desktopLayoutSpacing: {
|
|
18
|
+
paddingVertical: space8,
|
|
19
|
+
},
|
|
20
|
+
header: {
|
|
21
|
+
height: HEADER_HEIGHT,
|
|
22
|
+
},
|
|
23
|
+
headerWrapper: {
|
|
24
|
+
display: "flex",
|
|
25
|
+
flexDirection: "column",
|
|
26
|
+
},
|
|
27
|
+
info: {
|
|
28
|
+
backgroundColor: colorBgBase,
|
|
29
|
+
gap: space1,
|
|
30
|
+
paddingBottom: space4,
|
|
31
|
+
paddingHorizontal: space6,
|
|
32
|
+
paddingTop: space8,
|
|
33
|
+
},
|
|
34
|
+
layout: {
|
|
35
|
+
flex: 1,
|
|
36
|
+
justifyContent: "center",
|
|
37
|
+
},
|
|
38
|
+
safeAreaView: {
|
|
39
|
+
flex: 1,
|
|
40
|
+
},
|
|
41
|
+
scrollView: {
|
|
42
|
+
flex: 1,
|
|
43
|
+
},
|
|
44
|
+
submit: {
|
|
45
|
+
backgroundColor: colorBgBase,
|
|
46
|
+
padding: space6,
|
|
47
|
+
},
|
|
48
|
+
submitDesktop: {
|
|
49
|
+
borderBottomLeftRadius: borderRadius5,
|
|
50
|
+
borderBottomRightRadius: borderRadius5,
|
|
51
|
+
},
|
|
52
|
+
});
|
|
53
|
+
};
|
|
52
54
|
export { style };
|
|
@@ -1,28 +1,29 @@
|
|
|
1
|
-
import React from "react";
|
|
1
|
+
import React, { useMemo } from "react";
|
|
2
2
|
import { Pressable, View } from "react-native";
|
|
3
|
-
import {
|
|
3
|
+
import { Text } from "@lookiero/aurora";
|
|
4
4
|
import { useI18nMessage } from "@lookiero/i18n-react";
|
|
5
|
-
import { LazyImage } from "@lookiero/sty-psp-ui";
|
|
5
|
+
import { Icon, LazyImage } from "@lookiero/sty-psp-ui";
|
|
6
6
|
import { CheckoutItemStatus } from "../../../../../../domain/checkoutItem/model/checkoutItem";
|
|
7
7
|
import { size } from "../../../../../../projection/size/size";
|
|
8
8
|
import { Price } from "../../../../components/atoms/price/Price";
|
|
9
9
|
import { useMediaImage } from "../../../../hooks/useMediaImage";
|
|
10
10
|
import { COLOR_I18N_PREFIX, DOMAIN, I18nMessages } from "../../../../i18n/i18n";
|
|
11
|
-
import { IMAGE_WIDTH, style } from "./ProductVariant.style";
|
|
11
|
+
import { IMAGE_WIDTH, style as productVariantStyle } from "./ProductVariant.style";
|
|
12
12
|
const ProductVariant = ({ media, brand, name, price, size: sizeProjection, color, status, country, style: customStyle, onPress, }) => {
|
|
13
13
|
const uniqueText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.ITEM_UNIQUE });
|
|
14
14
|
const colorLabel = useI18nMessage({ domain: DOMAIN, id: color.name, prefix: COLOR_I18N_PREFIX });
|
|
15
15
|
const sizeChangeText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.PRODUCT_VARIANT_SIZE_CHANGE });
|
|
16
16
|
const cdnImageUrl = useMediaImage();
|
|
17
|
+
const style = useMemo(() => productVariantStyle(), []);
|
|
17
18
|
return (React.createElement(Pressable, { pointerEvents: onPress ? "auto" : "none", style: style.container, testID: "product-variant", onPress: onPress },
|
|
18
19
|
React.createElement(View, { style: style.row },
|
|
19
20
|
React.createElement(View, null,
|
|
20
21
|
React.createElement(LazyImage, { hiResSrc: cdnImageUrl({ url: media[0]?.url, width: IMAGE_WIDTH }), resizeMode: "contain", src: cdnImageUrl({ url: media[0]?.url, width: IMAGE_WIDTH, dpi: 1 }), style: { view: [style.media, customStyle?.image] }, testID: "product-variant-media" })),
|
|
21
22
|
React.createElement(View, { style: style.descriptionContainer },
|
|
22
23
|
React.createElement(View, { style: style.infoProductVariant },
|
|
23
|
-
React.createElement(Text, {
|
|
24
|
+
React.createElement(Text, { level: 2, style: style.text, detail: true }, brand),
|
|
24
25
|
React.createElement(Text, { level: 2, detail: true }, name),
|
|
25
|
-
React.createElement(Text, {
|
|
26
|
+
React.createElement(Text, { level: 2, style: style.text, detail: true },
|
|
26
27
|
sizeProjection.unique ? uniqueText : size({ size: sizeProjection, country }),
|
|
27
28
|
" / ",
|
|
28
29
|
colorLabel),
|
package/dist/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.style.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
declare const IMAGE_WIDTH = 104;
|
|
2
|
-
declare const style: {
|
|
2
|
+
declare const style: () => {
|
|
3
3
|
container: {
|
|
4
4
|
alignItems: "flex-end";
|
|
5
5
|
borderBottomColor: string;
|
|
@@ -35,5 +35,8 @@ declare const style: {
|
|
|
35
35
|
paddingHorizontal: number;
|
|
36
36
|
paddingTop: number;
|
|
37
37
|
};
|
|
38
|
+
text: {
|
|
39
|
+
color: string;
|
|
40
|
+
};
|
|
38
41
|
};
|
|
39
42
|
export { style, IMAGE_WIDTH };
|
package/dist/src/infrastructure/ui/views/shared/components/productVariant/ProductVariant.style.js
CHANGED
|
@@ -1,43 +1,48 @@
|
|
|
1
1
|
import { StyleSheet } from "react-native";
|
|
2
2
|
import { theme } from "@lookiero/sty-psp-ui";
|
|
3
|
-
const { colorBgSurface, borderRadius3, borderRadiusFull, borderWidth2, colorBorderInput, colorBgPrimaryLight, space05, space1, space2, space4, } = theme();
|
|
4
3
|
const IMAGE_WIDTH = 104;
|
|
5
4
|
const IMAGE_HEIGHT = 132;
|
|
6
|
-
const style =
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
5
|
+
const style = () => {
|
|
6
|
+
const { borderRadius3, borderRadiusFull, borderWidth2, colorBgPrimaryLight, colorBgSurface, colorBorderInput, colorTextMedium, space05, space1, space2, space4, } = theme();
|
|
7
|
+
return StyleSheet.create({
|
|
8
|
+
container: {
|
|
9
|
+
alignItems: "flex-end",
|
|
10
|
+
borderBottomColor: colorBgPrimaryLight,
|
|
11
|
+
borderBottomWidth: 1,
|
|
12
|
+
flexDirection: "row",
|
|
13
|
+
justifyContent: "space-between",
|
|
14
|
+
paddingVertical: space4,
|
|
15
|
+
},
|
|
16
|
+
descriptionContainer: {
|
|
17
|
+
alignSelf: "stretch",
|
|
18
|
+
justifyContent: "space-between",
|
|
19
|
+
marginLeft: space2,
|
|
20
|
+
},
|
|
21
|
+
infoProductVariant: {
|
|
22
|
+
alignItems: "flex-start",
|
|
23
|
+
},
|
|
24
|
+
media: {
|
|
25
|
+
borderColor: colorBorderInput,
|
|
26
|
+
borderRadius: borderRadius3,
|
|
27
|
+
borderWidth: borderWidth2,
|
|
28
|
+
height: IMAGE_HEIGHT,
|
|
29
|
+
width: IMAGE_WIDTH,
|
|
30
|
+
},
|
|
31
|
+
row: {
|
|
32
|
+
alignItems: "flex-end",
|
|
33
|
+
flexDirection: "row",
|
|
34
|
+
},
|
|
35
|
+
sizeChange: {
|
|
36
|
+
backgroundColor: colorBgSurface,
|
|
37
|
+
borderRadius: borderRadiusFull,
|
|
38
|
+
marginTop: space4,
|
|
39
|
+
paddingBottom: space05,
|
|
40
|
+
paddingHorizontal: space2,
|
|
41
|
+
paddingTop: space1,
|
|
42
|
+
},
|
|
43
|
+
text: {
|
|
44
|
+
color: colorTextMedium,
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
};
|
|
43
48
|
export { style, IMAGE_WIDTH };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React, { useCallback, useEffect, useMemo, useState } from "react";
|
|
2
2
|
import { Platform, ScrollView, View } from "react-native";
|
|
3
3
|
import { generatePath, useMatch, useNavigate } from "react-router-native";
|
|
4
|
-
import { Box, Text, Layout as AuroraLayout,
|
|
4
|
+
import { Box, Text, Layout as AuroraLayout, Spinner } from "@lookiero/aurora";
|
|
5
5
|
import { useI18nMessage } from "@lookiero/i18n-react";
|
|
6
6
|
import { QueryStatus } from "@lookiero/messaging-react";
|
|
7
|
-
import { Sticky } from "@lookiero/sty-psp-ui";
|
|
7
|
+
import { Sticky, useScreenSize } from "@lookiero/sty-psp-ui";
|
|
8
8
|
import { CheckoutItemStatus } from "../../../../domain/checkoutItem/model/checkoutItem";
|
|
9
9
|
import { useViewFirstAvailableCheckoutByCustomerId } from "../../../projection/checkout/react/useViewFirstAvailableCheckoutByCustomerId";
|
|
10
10
|
import { useViewFiveItemsDiscountByCustomerId } from "../../../projection/checkout/react/useViewFiveItemsDiscountByCustomerId";
|
|
@@ -18,16 +18,18 @@ import { Body } from "../../components/layouts/body/Body";
|
|
|
18
18
|
import { useStaticInfo } from "../../hooks/useStaticInfo";
|
|
19
19
|
import { DOMAIN, I18nMessages } from "../../i18n/i18n";
|
|
20
20
|
import { Routes } from "../../routing/routes";
|
|
21
|
-
import { style } from "./Summary.style";
|
|
21
|
+
import { style as summaryStyle } from "./Summary.style";
|
|
22
22
|
import { CollapsiblePricing } from "./components/collapsiblePricing/CollapsiblePricing";
|
|
23
23
|
const Summary = ({ layout: Layout, children }) => {
|
|
24
24
|
const { customer: { customerId, country, segment }, basePath, } = useStaticInfo();
|
|
25
|
+
const screenSize = useScreenSize();
|
|
26
|
+
const isDesktopScreen = screenSize === "L";
|
|
27
|
+
const style = useMemo(() => summaryStyle(), []);
|
|
25
28
|
const [pricingCollapsed, setPricingCollapsed] = useState(true);
|
|
26
29
|
const [pricingHeight, setPricingHeight] = useState(0);
|
|
27
30
|
const titleText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.SUMMARY_TITLE });
|
|
28
31
|
const descriptionText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.SUMMARY_DESCRIPTION });
|
|
29
32
|
const submitButtonText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.SUMMARY_SUBMIT_BUTTON });
|
|
30
|
-
const { screen } = useDevice();
|
|
31
33
|
const [checkout] = useViewFirstAvailableCheckoutByCustomerId({ customerId });
|
|
32
34
|
const [pricing, pricingStatus] = useViewPricingByCheckoutId({ checkoutId: checkout?.id });
|
|
33
35
|
const [fiveItemsDiscount = 0, fiveItemsDiscountStatus] = useViewFiveItemsDiscountByCustomerId({ customerId });
|
|
@@ -83,17 +85,17 @@ const Summary = ({ layout: Layout, children }) => {
|
|
|
83
85
|
} },
|
|
84
86
|
React.createElement(ScrollView, { showsVerticalScrollIndicator: false, testID: "summary-view" },
|
|
85
87
|
fiveItemsDiscount !== 0 && React.createElement(FiveItemsDiscountBanner, { fiveItemsDiscount: fiveItemsDiscount }),
|
|
86
|
-
React.createElement(AuroraLayout, { fullWidth: !
|
|
87
|
-
React.createElement(Box, { size: { L: "2/3" }, style:
|
|
88
|
-
React.createElement(View, { style: [style.contentWrapper,
|
|
89
|
-
React.createElement(View, { style: !
|
|
88
|
+
React.createElement(AuroraLayout, { fullWidth: !isDesktopScreen, style: [isDesktopScreen && style.desktopLayoutSpacing, !isDesktopScreen && { paddingBottom: pricingHeight }] },
|
|
89
|
+
React.createElement(Box, { size: { L: "2/3" }, style: isDesktopScreen && style.desktopListSpacing },
|
|
90
|
+
React.createElement(View, { style: [style.contentWrapper, isDesktopScreen && style.desktopContentWrapper] },
|
|
91
|
+
React.createElement(View, { style: !isDesktopScreen && style.mobileInfo },
|
|
90
92
|
React.createElement(Text, { level: 3, style: style.title, heading: true }, titleText),
|
|
91
93
|
React.createElement(Text, { level: 3, style: style.description }, descriptionText)),
|
|
92
94
|
children)),
|
|
93
|
-
pricing &&
|
|
95
|
+
pricing && isDesktopScreen ? (React.createElement(Box, { size: { L: "1/3" }, style: [style.resume, isDesktopScreen ? style.desktopResume : style.mobileResume] },
|
|
94
96
|
React.createElement(View, { style: style.princingWrapper },
|
|
95
97
|
React.createElement(CollapsiblePricing, { collapsed: false, collapsible: false, pricing: pricing, submitButtonText: submitButtonText, totalCheckoutItemsKept: totalCheckoutItemsKept, onSubmit: handleOnSubmit })))) : null)),
|
|
96
|
-
pricing && !
|
|
98
|
+
pricing && !isDesktopScreen ? (React.createElement(Sticky, { style: style.sticky, onLayout: Platform.OS !== "web" ? handleOnPricingLayout : undefined },
|
|
97
99
|
React.createElement(Body, null,
|
|
98
100
|
React.createElement(CollapsiblePricing, { collapsed: pricingCollapsed, pricing: pricing, submitButtonText: submitButtonText, totalCheckoutItemsKept: totalCheckoutItemsKept, onPress: handleOnPressPricing, onSubmit: handleOnSubmit })))) : null));
|
|
99
101
|
};
|
|
@@ -1,74 +1,76 @@
|
|
|
1
1
|
import { Platform, StyleSheet } from "react-native";
|
|
2
2
|
import { theme } from "@lookiero/sty-psp-ui";
|
|
3
3
|
import { HEADER_HEIGHT } from "../../components/templates/header/Header.style";
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
4
|
+
const style = () => {
|
|
5
|
+
const { colorTextMedium, colorText, colorBgPrimaryLight, space2, space3, space4, space6, space12, space16, borderRadius4, colorBgBase, } = theme();
|
|
6
|
+
return StyleSheet.create({
|
|
7
|
+
contentWrapper: {
|
|
8
|
+
backgroundColor: colorBgBase,
|
|
9
|
+
flexGrow: 0,
|
|
10
|
+
},
|
|
11
|
+
description: {
|
|
12
|
+
color: colorTextMedium,
|
|
13
|
+
marginBottom: space6,
|
|
14
|
+
},
|
|
15
|
+
desktopContentWrapper: {
|
|
16
|
+
borderRadius: borderRadius4,
|
|
17
|
+
paddingHorizontal: space6,
|
|
18
|
+
paddingVertical: space12,
|
|
19
|
+
},
|
|
20
|
+
desktopLayoutSpacing: {
|
|
21
|
+
paddingVertical: space12,
|
|
22
|
+
},
|
|
23
|
+
desktopListSpacing: {
|
|
24
|
+
paddingRight: space16,
|
|
25
|
+
},
|
|
26
|
+
desktopResume: {
|
|
27
|
+
borderRadius: borderRadius4,
|
|
28
|
+
},
|
|
29
|
+
header: {
|
|
30
|
+
height: HEADER_HEIGHT,
|
|
31
|
+
},
|
|
32
|
+
mobileInfo: {
|
|
33
|
+
paddingHorizontal: space6,
|
|
34
|
+
paddingTop: space6,
|
|
35
|
+
},
|
|
36
|
+
mobileResume: {
|
|
37
|
+
shadowColor: colorText,
|
|
38
|
+
shadowOpacity: 0.15,
|
|
39
|
+
...Platform.select({
|
|
40
|
+
web: {
|
|
41
|
+
shadowOffset: { width: 0, height: 8 },
|
|
42
|
+
shadowRadius: 18,
|
|
43
|
+
elevation: 0.5,
|
|
44
|
+
},
|
|
45
|
+
}),
|
|
46
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
47
|
+
},
|
|
48
|
+
princingWrapper: {
|
|
49
|
+
padding: space6,
|
|
50
|
+
},
|
|
51
|
+
resume: {
|
|
52
|
+
overflow: "hidden",
|
|
53
|
+
backgroundColor: colorBgBase,
|
|
54
|
+
...Platform.select({
|
|
55
|
+
web: {
|
|
56
|
+
position: "sticky",
|
|
57
|
+
top: space12,
|
|
58
|
+
alignSelf: "flex-start",
|
|
59
|
+
},
|
|
60
|
+
}),
|
|
61
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
62
|
+
},
|
|
63
|
+
scrollView: {
|
|
64
|
+
backgroundColor: colorBgPrimaryLight,
|
|
65
|
+
flex: 1,
|
|
66
|
+
},
|
|
67
|
+
sticky: {
|
|
68
|
+
paddingBottom: space4,
|
|
69
|
+
paddingTop: space3,
|
|
70
|
+
},
|
|
71
|
+
title: {
|
|
72
|
+
marginBottom: space2,
|
|
73
|
+
},
|
|
74
|
+
});
|
|
75
|
+
};
|
|
74
76
|
export { style };
|
package/dist/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.js
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import React from "react";
|
|
1
|
+
import React, { useMemo } from "react";
|
|
2
2
|
import { Pressable, View } from "react-native";
|
|
3
3
|
import Animated, { useAnimatedStyle, useSharedValue, withTiming } from "react-native-reanimated";
|
|
4
|
-
import { Button,
|
|
4
|
+
import { Button, Text } from "@lookiero/aurora";
|
|
5
5
|
import { useI18nMessage } from "@lookiero/i18n-react";
|
|
6
|
+
import { Icon } from "@lookiero/sty-psp-ui";
|
|
6
7
|
import { Price } from "../../../../components/atoms/price/Price";
|
|
7
8
|
import { DOMAIN, I18nMessages } from "../../../../i18n/i18n";
|
|
8
9
|
import { Pricing } from "../pricing/Pricing";
|
|
9
|
-
import { style } from "./CollapsiblePricing.style";
|
|
10
|
+
import { style as collapsiblePricingStyle } from "./CollapsiblePricing.style";
|
|
10
11
|
const CollapsiblePricing = ({ pricing, totalCheckoutItemsKept, collapsible = true, collapsed = false, submitButtonText, onPress = () => void 0, onSubmit, }) => {
|
|
11
12
|
const { pendingToPay } = pricing;
|
|
12
13
|
const totalText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.SUMMARY_TOTAL });
|
|
@@ -21,6 +22,7 @@ const CollapsiblePricing = ({ pricing, totalCheckoutItemsKept, collapsible = tru
|
|
|
21
22
|
const notCollapsedOpacity = useSharedValue(collapsed ? 0 : 1);
|
|
22
23
|
notCollapsedOpacity.value = collapsed ? 0 : 1;
|
|
23
24
|
const notCollapsedAnimatedStyle = useAnimatedStyle(() => ({ opacity: withTiming(notCollapsedOpacity.value) }), [notCollapsedOpacity.value]);
|
|
25
|
+
const style = useMemo(() => collapsiblePricingStyle(), []);
|
|
24
26
|
return (React.createElement(React.Fragment, null,
|
|
25
27
|
collapsible && (React.createElement(Pressable, { style: style.iconContainer, testID: "pricing-collapsed", onPress: onPress }, collapsed ? (React.createElement(Icon, { name: "arrow_up_small", testID: "arrow-up" })) : (React.createElement(Icon, { name: "arrow_down_small", testID: "arrow-down" })))),
|
|
26
28
|
collapsed && collapsible ? (React.createElement(Animated.View, { key: "collapsed", style: [style.collapsed, collapsedAnimatedStyle] },
|
|
@@ -1,21 +1,23 @@
|
|
|
1
1
|
import { StyleSheet } from "react-native";
|
|
2
2
|
import { theme } from "@lookiero/sty-psp-ui";
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
3
|
+
const style = () => {
|
|
4
|
+
const { space1, space3 } = theme();
|
|
5
|
+
return StyleSheet.create({
|
|
6
|
+
collapsed: {
|
|
7
|
+
flexDirection: "row",
|
|
8
|
+
justifyContent: "space-between",
|
|
9
|
+
},
|
|
10
|
+
collapsedContent: {
|
|
11
|
+
flex: 1,
|
|
12
|
+
marginBottom: space1,
|
|
13
|
+
},
|
|
14
|
+
iconContainer: {
|
|
15
|
+
alignItems: "center",
|
|
16
|
+
marginBottom: space3,
|
|
17
|
+
},
|
|
18
|
+
totalCollapsed: {
|
|
19
|
+
marginBottom: space1,
|
|
20
|
+
},
|
|
21
|
+
});
|
|
22
|
+
};
|
|
21
23
|
export { style };
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
import React from "react";
|
|
1
|
+
import React, { useMemo } from "react";
|
|
2
2
|
import { View } from "react-native";
|
|
3
3
|
import { Text } from "@lookiero/aurora";
|
|
4
4
|
import { useI18nMessage } from "@lookiero/i18n-react";
|
|
5
5
|
import { Price } from "../../../../components/atoms/price/Price";
|
|
6
6
|
import { DOMAIN, I18nMessages } from "../../../../i18n/i18n";
|
|
7
|
-
import { style } from "./Pricing.style";
|
|
8
|
-
const Row = ({ action = false, text, level = 3, children }) =>
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
import { style as pricingStyle } from "./Pricing.style";
|
|
8
|
+
const Row = ({ action = false, text, level = 3, children }) => {
|
|
9
|
+
const style = useMemo(() => pricingStyle(), []);
|
|
10
|
+
return (React.createElement(View, { style: style.row },
|
|
11
|
+
React.createElement(Text, { action: action, level: level }, text),
|
|
12
|
+
children));
|
|
13
|
+
};
|
|
11
14
|
const Pricing = ({ pricing, totalCheckoutItemsKept }) => {
|
|
12
15
|
const { pendingToPay, subtotal, balanceDiscount, discount, discountPercentage = 0, service } = pricing;
|
|
16
|
+
const style = useMemo(() => pricingStyle(), []);
|
|
13
17
|
const totalText = useI18nMessage({ domain: DOMAIN, id: I18nMessages.SUMMARY_TOTAL });
|
|
14
18
|
const totalCheckoutItemsKeptText = useI18nMessage({
|
|
15
19
|
domain: DOMAIN,
|
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
import { StyleSheet } from "react-native";
|
|
2
2
|
import { theme } from "@lookiero/sty-psp-ui";
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
3
|
+
const style = () => {
|
|
4
|
+
const { space4, colorBgPrimary } = theme();
|
|
5
|
+
return StyleSheet.create({
|
|
6
|
+
divider: {
|
|
7
|
+
backgroundColor: colorBgPrimary,
|
|
8
|
+
height: 1,
|
|
9
|
+
marginBottom: space4,
|
|
10
|
+
},
|
|
11
|
+
row: {
|
|
12
|
+
flexDirection: "row",
|
|
13
|
+
justifyContent: "space-between",
|
|
14
|
+
marginBottom: space4,
|
|
15
|
+
},
|
|
16
|
+
});
|
|
17
|
+
};
|
|
16
18
|
export { style };
|