@commercelayer/react-components 4.20.1 → 4.21.0-beta.2
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/index.cjs +3 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +3271 -0
- package/dist/index.d.ts +3271 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -0
- package/package.json +19 -154
- package/lib/cjs/components/ExternalFunction.d.ts +0 -7
- package/lib/cjs/components/ExternalFunction.js +0 -2
- package/lib/cjs/components/MetadataInput.d.ts +0 -5
- package/lib/cjs/components/MetadataInput.js +0 -2
- package/lib/cjs/components/SubmitButton.d.ts +0 -10
- package/lib/cjs/components/SubmitButton.js +0 -2
- package/lib/cjs/components/addresses/Address.d.ts +0 -31
- package/lib/cjs/components/addresses/Address.js +0 -2
- package/lib/cjs/components/addresses/AddressCountrySelector.d.ts +0 -34
- package/lib/cjs/components/addresses/AddressCountrySelector.js +0 -2
- package/lib/cjs/components/addresses/AddressField.d.ts +0 -61
- package/lib/cjs/components/addresses/AddressField.js +0 -2
- package/lib/cjs/components/addresses/AddressInput.d.ts +0 -34
- package/lib/cjs/components/addresses/AddressInput.js +0 -2
- package/lib/cjs/components/addresses/AddressInputSelect.d.ts +0 -29
- package/lib/cjs/components/addresses/AddressInputSelect.js +0 -2
- package/lib/cjs/components/addresses/AddressStateSelector.d.ts +0 -36
- package/lib/cjs/components/addresses/AddressStateSelector.js +0 -2
- package/lib/cjs/components/addresses/AddressesContainer.d.ts +0 -40
- package/lib/cjs/components/addresses/AddressesContainer.js +0 -2
- package/lib/cjs/components/addresses/AddressesEmpty.d.ts +0 -26
- package/lib/cjs/components/addresses/AddressesEmpty.js +0 -2
- package/lib/cjs/components/addresses/BillingAddressContainer.d.ts +0 -6
- package/lib/cjs/components/addresses/BillingAddressContainer.js +0 -2
- package/lib/cjs/components/addresses/BillingAddressForm.d.ts +0 -34
- package/lib/cjs/components/addresses/BillingAddressForm.js +0 -2
- package/lib/cjs/components/addresses/SaveAddressesButton.d.ts +0 -18
- package/lib/cjs/components/addresses/SaveAddressesButton.js +0 -2
- package/lib/cjs/components/addresses/ShippingAddressContainer.d.ts +0 -7
- package/lib/cjs/components/addresses/ShippingAddressContainer.js +0 -2
- package/lib/cjs/components/addresses/ShippingAddressForm.d.ts +0 -31
- package/lib/cjs/components/addresses/ShippingAddressForm.js +0 -2
- package/lib/cjs/components/auth/CommerceLayer.d.ts +0 -25
- package/lib/cjs/components/auth/CommerceLayer.js +0 -2
- package/lib/cjs/components/customers/CustomerAddressForm.d.ts +0 -13
- package/lib/cjs/components/customers/CustomerAddressForm.js +0 -2
- package/lib/cjs/components/customers/CustomerContainer.d.ts +0 -38
- package/lib/cjs/components/customers/CustomerContainer.js +0 -2
- package/lib/cjs/components/customers/CustomerField.d.ts +0 -25
- package/lib/cjs/components/customers/CustomerField.js +0 -2
- package/lib/cjs/components/customers/CustomerInput.d.ts +0 -11
- package/lib/cjs/components/customers/CustomerInput.js +0 -2
- package/lib/cjs/components/customers/CustomerPaymentSource.d.ts +0 -11
- package/lib/cjs/components/customers/CustomerPaymentSource.js +0 -2
- package/lib/cjs/components/customers/CustomerPaymentSourceEmpty.d.ts +0 -14
- package/lib/cjs/components/customers/CustomerPaymentSourceEmpty.js +0 -2
- package/lib/cjs/components/customers/MyAccountLink.d.ts +0 -38
- package/lib/cjs/components/customers/MyAccountLink.js +0 -2
- package/lib/cjs/components/customers/MyIdentityLink.d.ts +0 -59
- package/lib/cjs/components/customers/MyIdentityLink.js +0 -2
- package/lib/cjs/components/customers/SaveCustomerButton.d.ts +0 -12
- package/lib/cjs/components/customers/SaveCustomerButton.js +0 -2
- package/lib/cjs/components/errors/Errors.d.ts +0 -31
- package/lib/cjs/components/errors/Errors.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCard.d.ts +0 -10
- package/lib/cjs/components/gift_cards/GiftCard.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardContainer.d.ts +0 -6
- package/lib/cjs/components/gift_cards/GiftCardContainer.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardCurrencySelector.d.ts +0 -7
- package/lib/cjs/components/gift_cards/GiftCardCurrencySelector.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardInput.d.ts +0 -7
- package/lib/cjs/components/gift_cards/GiftCardInput.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardOrCouponCode.d.ts +0 -16
- package/lib/cjs/components/gift_cards/GiftCardOrCouponCode.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardOrCouponForm.d.ts +0 -15
- package/lib/cjs/components/gift_cards/GiftCardOrCouponForm.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardOrCouponInput.d.ts +0 -11
- package/lib/cjs/components/gift_cards/GiftCardOrCouponInput.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardOrCouponRemoveButton.d.ts +0 -20
- package/lib/cjs/components/gift_cards/GiftCardOrCouponRemoveButton.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardOrCouponSubmit.d.ts +0 -10
- package/lib/cjs/components/gift_cards/GiftCardOrCouponSubmit.js +0 -2
- package/lib/cjs/components/gift_cards/GiftCardRecipientInput.d.ts +0 -0
- package/lib/cjs/components/gift_cards/GiftCardRecipientInput.js +0 -2
- package/lib/cjs/components/in_stock_subscriptions/InStockSubscriptionButton.d.ts +0 -36
- package/lib/cjs/components/in_stock_subscriptions/InStockSubscriptionButton.js +0 -2
- package/lib/cjs/components/in_stock_subscriptions/InStockSubscriptionsContainer.d.ts +0 -10
- package/lib/cjs/components/in_stock_subscriptions/InStockSubscriptionsContainer.js +0 -2
- package/lib/cjs/components/line_items/LineItem.d.ts +0 -8
- package/lib/cjs/components/line_items/LineItem.js +0 -2
- package/lib/cjs/components/line_items/LineItemAmount.d.ts +0 -7
- package/lib/cjs/components/line_items/LineItemAmount.js +0 -2
- package/lib/cjs/components/line_items/LineItemCode.d.ts +0 -13
- package/lib/cjs/components/line_items/LineItemCode.js +0 -2
- package/lib/cjs/components/line_items/LineItemField.d.ts +0 -14
- package/lib/cjs/components/line_items/LineItemField.js +0 -2
- package/lib/cjs/components/line_items/LineItemImage.d.ts +0 -17
- package/lib/cjs/components/line_items/LineItemImage.js +0 -2
- package/lib/cjs/components/line_items/LineItemName.d.ts +0 -12
- package/lib/cjs/components/line_items/LineItemName.js +0 -2
- package/lib/cjs/components/line_items/LineItemOption.d.ts +0 -19
- package/lib/cjs/components/line_items/LineItemOption.js +0 -2
- package/lib/cjs/components/line_items/LineItemOptions.d.ts +0 -16
- package/lib/cjs/components/line_items/LineItemOptions.js +0 -2
- package/lib/cjs/components/line_items/LineItemQuantity.d.ts +0 -21
- package/lib/cjs/components/line_items/LineItemQuantity.js +0 -2
- package/lib/cjs/components/line_items/LineItemRemoveLink.d.ts +0 -14
- package/lib/cjs/components/line_items/LineItemRemoveLink.js +0 -2
- package/lib/cjs/components/line_items/LineItemsContainer.d.ts +0 -9
- package/lib/cjs/components/line_items/LineItemsContainer.js +0 -2
- package/lib/cjs/components/line_items/LineItemsCount.d.ts +0 -12
- package/lib/cjs/components/line_items/LineItemsCount.js +0 -2
- package/lib/cjs/components/line_items/LineItemsEmpty.d.ts +0 -12
- package/lib/cjs/components/line_items/LineItemsEmpty.js +0 -2
- package/lib/cjs/components/orders/AddToCartButton.d.ts +0 -95
- package/lib/cjs/components/orders/AddToCartButton.js +0 -2
- package/lib/cjs/components/orders/AdjustmentAmount.d.ts +0 -4
- package/lib/cjs/components/orders/AdjustmentAmount.js +0 -2
- package/lib/cjs/components/orders/CartLink.d.ts +0 -47
- package/lib/cjs/components/orders/CartLink.js +0 -2
- package/lib/cjs/components/orders/CheckoutLink.d.ts +0 -28
- package/lib/cjs/components/orders/CheckoutLink.js +0 -2
- package/lib/cjs/components/orders/DiscountAmount.d.ts +0 -4
- package/lib/cjs/components/orders/DiscountAmount.js +0 -2
- package/lib/cjs/components/orders/GiftCardAmount.d.ts +0 -4
- package/lib/cjs/components/orders/GiftCardAmount.js +0 -2
- package/lib/cjs/components/orders/HostedCart.d.ts +0 -58
- package/lib/cjs/components/orders/HostedCart.js +0 -2
- package/lib/cjs/components/orders/OrderContainer.d.ts +0 -62
- package/lib/cjs/components/orders/OrderContainer.js +0 -2
- package/lib/cjs/components/orders/OrderList.d.ts +0 -83
- package/lib/cjs/components/orders/OrderList.js +0 -2
- package/lib/cjs/components/orders/OrderListEmpty.d.ts +0 -17
- package/lib/cjs/components/orders/OrderListEmpty.js +0 -2
- package/lib/cjs/components/orders/OrderListPaginationButtons.d.ts +0 -48
- package/lib/cjs/components/orders/OrderListPaginationButtons.js +0 -2
- package/lib/cjs/components/orders/OrderListPaginationInfo.d.ts +0 -29
- package/lib/cjs/components/orders/OrderListPaginationInfo.js +0 -2
- package/lib/cjs/components/orders/OrderListRow.d.ts +0 -29
- package/lib/cjs/components/orders/OrderListRow.js +0 -2
- package/lib/cjs/components/orders/OrderNumber.d.ts +0 -5
- package/lib/cjs/components/orders/OrderNumber.js +0 -2
- package/lib/cjs/components/orders/OrderStorage.d.ts +0 -31
- package/lib/cjs/components/orders/OrderStorage.js +0 -2
- package/lib/cjs/components/orders/PaymentMethodAmount.d.ts +0 -4
- package/lib/cjs/components/orders/PaymentMethodAmount.js +0 -2
- package/lib/cjs/components/orders/PlaceOrderButton.d.ts +0 -35
- package/lib/cjs/components/orders/PlaceOrderButton.js +0 -2
- package/lib/cjs/components/orders/PlaceOrderContainer.d.ts +0 -8
- package/lib/cjs/components/orders/PlaceOrderContainer.js +0 -2
- package/lib/cjs/components/orders/PrivacyAndTermsCheckbox.d.ts +0 -4
- package/lib/cjs/components/orders/PrivacyAndTermsCheckbox.js +0 -2
- package/lib/cjs/components/orders/ShippingAmount.d.ts +0 -4
- package/lib/cjs/components/orders/ShippingAmount.js +0 -2
- package/lib/cjs/components/orders/SubTotalAmount.d.ts +0 -4
- package/lib/cjs/components/orders/SubTotalAmount.js +0 -2
- package/lib/cjs/components/orders/TaxesAmount.d.ts +0 -4
- package/lib/cjs/components/orders/TaxesAmount.js +0 -2
- package/lib/cjs/components/orders/TotalAmount.d.ts +0 -4
- package/lib/cjs/components/orders/TotalAmount.js +0 -2
- package/lib/cjs/components/parcels/ParcelField.d.ts +0 -14
- package/lib/cjs/components/parcels/ParcelField.js +0 -2
- package/lib/cjs/components/parcels/ParcelLineItem.d.ts +0 -7
- package/lib/cjs/components/parcels/ParcelLineItem.js +0 -2
- package/lib/cjs/components/parcels/ParcelLineItemField.d.ts +0 -14
- package/lib/cjs/components/parcels/ParcelLineItemField.js +0 -2
- package/lib/cjs/components/parcels/ParcelLineItemsCount.d.ts +0 -18
- package/lib/cjs/components/parcels/ParcelLineItemsCount.js +0 -2
- package/lib/cjs/components/parcels/Parcels.d.ts +0 -7
- package/lib/cjs/components/parcels/Parcels.js +0 -2
- package/lib/cjs/components/parcels/ParcelsCount.d.ts +0 -18
- package/lib/cjs/components/parcels/ParcelsCount.js +0 -2
- package/lib/cjs/components/payment_gateways/AdyenGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/AdyenGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/BraintreeGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/BraintreeGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/CheckoutComGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/CheckoutComGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/ExternalGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/ExternalGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/KlarnaGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/KlarnaGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/PaymentGateway.d.ts +0 -16
- package/lib/cjs/components/payment_gateways/PaymentGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/PaypalGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/PaypalGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/StripeGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/StripeGateway.js +0 -2
- package/lib/cjs/components/payment_gateways/WireTransferGateway.d.ts +0 -5
- package/lib/cjs/components/payment_gateways/WireTransferGateway.js +0 -2
- package/lib/cjs/components/payment_methods/PaymentMethod.d.ts +0 -45
- package/lib/cjs/components/payment_methods/PaymentMethod.js +0 -2
- package/lib/cjs/components/payment_methods/PaymentMethodName.d.ts +0 -10
- package/lib/cjs/components/payment_methods/PaymentMethodName.js +0 -2
- package/lib/cjs/components/payment_methods/PaymentMethodPrice.d.ts +0 -8
- package/lib/cjs/components/payment_methods/PaymentMethodPrice.js +0 -2
- package/lib/cjs/components/payment_methods/PaymentMethodRadioButton.d.ts +0 -17
- package/lib/cjs/components/payment_methods/PaymentMethodRadioButton.js +0 -2
- package/lib/cjs/components/payment_methods/PaymentMethodsContainer.d.ts +0 -8
- package/lib/cjs/components/payment_methods/PaymentMethodsContainer.js +0 -2
- package/lib/cjs/components/payment_source/AdyenPayment.d.ts +0 -54
- package/lib/cjs/components/payment_source/AdyenPayment.js +0 -2
- package/lib/cjs/components/payment_source/BraintreePayment.d.ts +0 -32
- package/lib/cjs/components/payment_source/BraintreePayment.js +0 -2
- package/lib/cjs/components/payment_source/CheckoutComPayment.d.ts +0 -23
- package/lib/cjs/components/payment_source/CheckoutComPayment.js +0 -2
- package/lib/cjs/components/payment_source/ExternalPayment.d.ts +0 -24
- package/lib/cjs/components/payment_source/ExternalPayment.js +0 -2
- package/lib/cjs/components/payment_source/KlarnaPayment.d.ts +0 -10
- package/lib/cjs/components/payment_source/KlarnaPayment.js +0 -2
- package/lib/cjs/components/payment_source/PaymentSource.d.ts +0 -19
- package/lib/cjs/components/payment_source/PaymentSource.js +0 -2
- package/lib/cjs/components/payment_source/PaymentSourceBrandIcon.d.ts +0 -15
- package/lib/cjs/components/payment_source/PaymentSourceBrandIcon.js +0 -2
- package/lib/cjs/components/payment_source/PaymentSourceBrandName.d.ts +0 -12
- package/lib/cjs/components/payment_source/PaymentSourceBrandName.js +0 -2
- package/lib/cjs/components/payment_source/PaymentSourceDetail.d.ts +0 -15
- package/lib/cjs/components/payment_source/PaymentSourceDetail.js +0 -2
- package/lib/cjs/components/payment_source/PaymentSourceEditButton.d.ts +0 -10
- package/lib/cjs/components/payment_source/PaymentSourceEditButton.js +0 -2
- package/lib/cjs/components/payment_source/PaypalPayment.d.ts +0 -12
- package/lib/cjs/components/payment_source/PaypalPayment.js +0 -2
- package/lib/cjs/components/payment_source/StripeExpressPayment.d.ts +0 -6
- package/lib/cjs/components/payment_source/StripeExpressPayment.js +0 -2
- package/lib/cjs/components/payment_source/StripePayment.d.ts +0 -21
- package/lib/cjs/components/payment_source/StripePayment.js +0 -2
- package/lib/cjs/components/payment_source/WireTransferPayment.d.ts +0 -12
- package/lib/cjs/components/payment_source/WireTransferPayment.js +0 -2
- package/lib/cjs/components/prices/Price.d.ts +0 -35
- package/lib/cjs/components/prices/Price.js +0 -2
- package/lib/cjs/components/prices/PricesContainer.d.ts +0 -41
- package/lib/cjs/components/prices/PricesContainer.js +0 -2
- package/lib/cjs/components/shipments/Shipment.d.ts +0 -10
- package/lib/cjs/components/shipments/Shipment.js +0 -2
- package/lib/cjs/components/shipments/ShipmentField.d.ts +0 -12
- package/lib/cjs/components/shipments/ShipmentField.js +0 -2
- package/lib/cjs/components/shipments/ShipmentsContainer.d.ts +0 -6
- package/lib/cjs/components/shipments/ShipmentsContainer.js +0 -2
- package/lib/cjs/components/shipments/ShipmentsCount.d.ts +0 -18
- package/lib/cjs/components/shipments/ShipmentsCount.js +0 -2
- package/lib/cjs/components/shipping_methods/ShippingMethod.d.ts +0 -8
- package/lib/cjs/components/shipping_methods/ShippingMethod.js +0 -2
- package/lib/cjs/components/shipping_methods/ShippingMethodName.d.ts +0 -11
- package/lib/cjs/components/shipping_methods/ShippingMethodName.js +0 -2
- package/lib/cjs/components/shipping_methods/ShippingMethodPrice.d.ts +0 -20
- package/lib/cjs/components/shipping_methods/ShippingMethodPrice.js +0 -2
- package/lib/cjs/components/shipping_methods/ShippingMethodRadioButton.d.ts +0 -17
- package/lib/cjs/components/shipping_methods/ShippingMethodRadioButton.js +0 -2
- package/lib/cjs/components/skus/AvailabilityContainer.d.ts +0 -34
- package/lib/cjs/components/skus/AvailabilityContainer.js +0 -2
- package/lib/cjs/components/skus/AvailabilityTemplate.d.ts +0 -52
- package/lib/cjs/components/skus/AvailabilityTemplate.js +0 -2
- package/lib/cjs/components/skus/DeliveryLeadTime.d.ts +0 -10
- package/lib/cjs/components/skus/DeliveryLeadTime.js +0 -2
- package/lib/cjs/components/skus/SkuField.d.ts +0 -25
- package/lib/cjs/components/skus/SkuField.js +0 -2
- package/lib/cjs/components/skus/SkuList.d.ts +0 -10
- package/lib/cjs/components/skus/SkuList.js +0 -2
- package/lib/cjs/components/skus/SkuListsContainer.d.ts +0 -6
- package/lib/cjs/components/skus/SkuListsContainer.js +0 -2
- package/lib/cjs/components/skus/Skus.d.ts +0 -18
- package/lib/cjs/components/skus/Skus.js +0 -2
- package/lib/cjs/components/skus/SkusContainer.d.ts +0 -31
- package/lib/cjs/components/skus/SkusContainer.js +0 -2
- package/lib/cjs/components/stock_transfers/StockTransfer.d.ts +0 -7
- package/lib/cjs/components/stock_transfers/StockTransfer.js +0 -2
- package/lib/cjs/components/stock_transfers/StockTransferField.d.ts +0 -10
- package/lib/cjs/components/stock_transfers/StockTransferField.js +0 -2
- package/lib/cjs/components/utils/AddressCardsTemplate.d.ts +0 -26
- package/lib/cjs/components/utils/AddressCardsTemplate.js +0 -2
- package/lib/cjs/components/utils/BaseField.d.ts +0 -8
- package/lib/cjs/components/utils/BaseField.js +0 -2
- package/lib/cjs/components/utils/BaseInput.d.ts +0 -5
- package/lib/cjs/components/utils/BaseInput.js +0 -2
- package/lib/cjs/components/utils/BaseOrderPrice.d.ts +0 -6
- package/lib/cjs/components/utils/BaseOrderPrice.js +0 -2
- package/lib/cjs/components/utils/BaseSelect.d.ts +0 -5
- package/lib/cjs/components/utils/BaseSelect.js +0 -2
- package/lib/cjs/components/utils/ErrorBoundary.d.ts +0 -14
- package/lib/cjs/components/utils/ErrorBoundary.js +0 -2
- package/lib/cjs/components/utils/GenericFieldComponent.d.ts +0 -58
- package/lib/cjs/components/utils/GenericFieldComponent.js +0 -2
- package/lib/cjs/components/utils/Parent.d.ts +0 -6
- package/lib/cjs/components/utils/Parent.js +0 -2
- package/lib/cjs/components/utils/PaymentCardsTemplate.d.ts +0 -41
- package/lib/cjs/components/utils/PaymentCardsTemplate.js +0 -2
- package/lib/cjs/components/utils/PriceTemplate.d.ts +0 -8
- package/lib/cjs/components/utils/PriceTemplate.js +0 -2
- package/lib/cjs/components/utils/getAllErrors.d.ts +0 -16
- package/lib/cjs/components/utils/getAllErrors.js +0 -2
- package/lib/cjs/config/currency.d.ts +0 -5
- package/lib/cjs/config/currency.js +0 -2
- package/lib/cjs/context/AddressChildrenContext.d.ts +0 -6
- package/lib/cjs/context/AddressChildrenContext.js +0 -2
- package/lib/cjs/context/AddressContext.d.ts +0 -18
- package/lib/cjs/context/AddressContext.js +0 -2
- package/lib/cjs/context/AvailabilityContext.d.ts +0 -2
- package/lib/cjs/context/AvailabilityContext.js +0 -2
- package/lib/cjs/context/BillingAddressContext.d.ts +0 -9
- package/lib/cjs/context/BillingAddressContext.js +0 -2
- package/lib/cjs/context/BillingAddressFormContext.d.ts +0 -22
- package/lib/cjs/context/BillingAddressFormContext.js +0 -2
- package/lib/cjs/context/CommerceLayerContext.d.ts +0 -6
- package/lib/cjs/context/CommerceLayerContext.js +0 -2
- package/lib/cjs/context/CouponAndGiftCardFormContext.d.ts +0 -8
- package/lib/cjs/context/CouponAndGiftCardFormContext.js +0 -2
- package/lib/cjs/context/CustomerAddressFormContext.d.ts +0 -17
- package/lib/cjs/context/CustomerAddressFormContext.js +0 -2
- package/lib/cjs/context/CustomerContext.d.ts +0 -29
- package/lib/cjs/context/CustomerContext.js +0 -2
- package/lib/cjs/context/CustomerPaymentSourceContext.d.ts +0 -11
- package/lib/cjs/context/CustomerPaymentSourceContext.js +0 -2
- package/lib/cjs/context/ExternalFunctionContext.d.ts +0 -11
- package/lib/cjs/context/ExternalFunctionContext.js +0 -2
- package/lib/cjs/context/GiftCardContext.d.ts +0 -10
- package/lib/cjs/context/GiftCardContext.js +0 -2
- package/lib/cjs/context/InStockSubscriptionContext.d.ts +0 -6
- package/lib/cjs/context/InStockSubscriptionContext.js +0 -2
- package/lib/cjs/context/LineItemChildrenContext.d.ts +0 -8
- package/lib/cjs/context/LineItemChildrenContext.js +0 -2
- package/lib/cjs/context/LineItemContext.d.ts +0 -7
- package/lib/cjs/context/LineItemContext.js +0 -2
- package/lib/cjs/context/LineItemOptionChildrenContext.d.ts +0 -9
- package/lib/cjs/context/LineItemOptionChildrenContext.js +0 -2
- package/lib/cjs/context/OrderContext.d.ts +0 -30
- package/lib/cjs/context/OrderContext.js +0 -2
- package/lib/cjs/context/OrderListChildrenContext.d.ts +0 -73
- package/lib/cjs/context/OrderListChildrenContext.js +0 -2
- package/lib/cjs/context/OrderListPaginationContext.d.ts +0 -15
- package/lib/cjs/context/OrderListPaginationContext.js +0 -2
- package/lib/cjs/context/OrderStorageContext.d.ts +0 -10
- package/lib/cjs/context/OrderStorageContext.js +0 -2
- package/lib/cjs/context/ParcelChildrenContext.d.ts +0 -6
- package/lib/cjs/context/ParcelChildrenContext.js +0 -2
- package/lib/cjs/context/ParcelLineItemChildrenContext.d.ts +0 -6
- package/lib/cjs/context/ParcelLineItemChildrenContext.js +0 -2
- package/lib/cjs/context/PaymentMethodChildrenContext.d.ts +0 -10
- package/lib/cjs/context/PaymentMethodChildrenContext.js +0 -2
- package/lib/cjs/context/PaymentMethodContext.d.ts +0 -13
- package/lib/cjs/context/PaymentMethodContext.js +0 -2
- package/lib/cjs/context/PaymentSourceContext.d.ts +0 -14
- package/lib/cjs/context/PaymentSourceContext.js +0 -2
- package/lib/cjs/context/PlaceOrderContext.d.ts +0 -12
- package/lib/cjs/context/PlaceOrderContext.js +0 -2
- package/lib/cjs/context/PricesContext.d.ts +0 -6
- package/lib/cjs/context/PricesContext.js +0 -2
- package/lib/cjs/context/ShipmentChildrenContext.d.ts +0 -13
- package/lib/cjs/context/ShipmentChildrenContext.js +0 -2
- package/lib/cjs/context/ShipmentContext.d.ts +0 -10
- package/lib/cjs/context/ShipmentContext.js +0 -2
- package/lib/cjs/context/ShippingAddressContext.d.ts +0 -9
- package/lib/cjs/context/ShippingAddressContext.js +0 -2
- package/lib/cjs/context/ShippingAddressFormContext.d.ts +0 -3
- package/lib/cjs/context/ShippingAddressFormContext.js +0 -2
- package/lib/cjs/context/ShippingMethodChildrenContext.d.ts +0 -9
- package/lib/cjs/context/ShippingMethodChildrenContext.js +0 -2
- package/lib/cjs/context/SkuChildrenContext.d.ts +0 -8
- package/lib/cjs/context/SkuChildrenContext.js +0 -2
- package/lib/cjs/context/SkuContext.d.ts +0 -8
- package/lib/cjs/context/SkuContext.js +0 -2
- package/lib/cjs/context/SkuListsContext.d.ts +0 -5
- package/lib/cjs/context/SkuListsContext.js +0 -2
- package/lib/cjs/context/StockTransferChildrenContext.d.ts +0 -6
- package/lib/cjs/context/StockTransferChildrenContext.js +0 -2
- package/lib/cjs/hooks/useCommerceLayer.d.ts +0 -12
- package/lib/cjs/hooks/useCommerceLayer.js +0 -2
- package/lib/cjs/hooks/useCustomerContainer.d.ts +0 -12
- package/lib/cjs/hooks/useCustomerContainer.js +0 -2
- package/lib/cjs/hooks/useOrderContainer.d.ts +0 -16
- package/lib/cjs/hooks/useOrderContainer.js +0 -2
- package/lib/cjs/index.d.ts +0 -107
- package/lib/cjs/index.js +0 -2
- package/lib/cjs/reducers/AddressReducer.d.ts +0 -80
- package/lib/cjs/reducers/AddressReducer.js +0 -2
- package/lib/cjs/reducers/AvailabilityReducer.d.ts +0 -53
- package/lib/cjs/reducers/AvailabilityReducer.js +0 -2
- package/lib/cjs/reducers/BillingAddressReducer.d.ts +0 -31
- package/lib/cjs/reducers/BillingAddressReducer.js +0 -2
- package/lib/cjs/reducers/CustomerReducer.d.ts +0 -183
- package/lib/cjs/reducers/CustomerReducer.js +0 -2
- package/lib/cjs/reducers/GiftCardReducer.d.ts +0 -66
- package/lib/cjs/reducers/GiftCardReducer.js +0 -2
- package/lib/cjs/reducers/InStockSubscriptionReducer.d.ts +0 -33
- package/lib/cjs/reducers/InStockSubscriptionReducer.js +0 -2
- package/lib/cjs/reducers/LineItemReducer.d.ts +0 -47
- package/lib/cjs/reducers/LineItemReducer.js +0 -2
- package/lib/cjs/reducers/OrderReducer.d.ts +0 -171
- package/lib/cjs/reducers/OrderReducer.js +0 -2
- package/lib/cjs/reducers/PaymentMethodReducer.d.ts +0 -161
- package/lib/cjs/reducers/PaymentMethodReducer.js +0 -2
- package/lib/cjs/reducers/PlaceOrderReducer.d.ts +0 -72
- package/lib/cjs/reducers/PlaceOrderReducer.js +0 -2
- package/lib/cjs/reducers/PriceReducer.d.ts +0 -35
- package/lib/cjs/reducers/PriceReducer.js +0 -2
- package/lib/cjs/reducers/ShipmentReducer.d.ts +0 -41
- package/lib/cjs/reducers/ShipmentReducer.js +0 -2
- package/lib/cjs/reducers/ShippingAddressReducer.d.ts +0 -32
- package/lib/cjs/reducers/ShippingAddressReducer.js +0 -2
- package/lib/cjs/reducers/SkuListsReducer.d.ts +0 -21
- package/lib/cjs/reducers/SkuListsReducer.js +0 -2
- package/lib/cjs/reducers/SkuReducer.d.ts +0 -21
- package/lib/cjs/reducers/SkuReducer.js +0 -2
- package/lib/cjs/typings/errors.d.ts +0 -15
- package/lib/cjs/typings/errors.js +0 -2
- package/lib/cjs/typings/globals.d.ts +0 -6
- package/lib/cjs/typings/globals.js +0 -2
- package/lib/cjs/typings/index.d.ts +0 -117
- package/lib/cjs/typings/index.js +0 -2
- package/lib/cjs/utils/PropsType.d.ts +0 -33
- package/lib/cjs/utils/PropsType.js +0 -2
- package/lib/cjs/utils/addressesManager.d.ts +0 -64
- package/lib/cjs/utils/addressesManager.js +0 -2
- package/lib/cjs/utils/adyen/manageGiftCard.d.ts +0 -16
- package/lib/cjs/utils/adyen/manageGiftCard.js +0 -2
- package/lib/cjs/utils/baseReducer.d.ts +0 -3
- package/lib/cjs/utils/baseReducer.js +0 -2
- package/lib/cjs/utils/browserInfo.d.ts +0 -12
- package/lib/cjs/utils/browserInfo.js +0 -2
- package/lib/cjs/utils/canPlaceOrder.d.ts +0 -5
- package/lib/cjs/utils/canPlaceOrder.js +0 -2
- package/lib/cjs/utils/checkIncludeResource.d.ts +0 -8
- package/lib/cjs/utils/checkIncludeResource.js +0 -2
- package/lib/cjs/utils/compareObjAttribute.d.ts +0 -7
- package/lib/cjs/utils/compareObjAttribute.js +0 -2
- package/lib/cjs/utils/countryStateCity.d.ts +0 -801
- package/lib/cjs/utils/countryStateCity.js +0 -2
- package/lib/cjs/utils/customMessages.d.ts +0 -2
- package/lib/cjs/utils/customMessages.js +0 -2
- package/lib/cjs/utils/customerOrderOptions.d.ts +0 -3
- package/lib/cjs/utils/customerOrderOptions.js +0 -2
- package/lib/cjs/utils/events.d.ts +0 -5
- package/lib/cjs/utils/events.js +0 -2
- package/lib/cjs/utils/expressPaymentHelper.d.ts +0 -92
- package/lib/cjs/utils/expressPaymentHelper.js +0 -2
- package/lib/cjs/utils/filterChildren.d.ts +0 -12
- package/lib/cjs/utils/filterChildren.js +0 -2
- package/lib/cjs/utils/formCleaner.d.ts +0 -4
- package/lib/cjs/utils/formCleaner.js +0 -2
- package/lib/cjs/utils/getAmount.d.ts +0 -7
- package/lib/cjs/utils/getAmount.js +0 -2
- package/lib/cjs/utils/getApplicationLink.d.ts +0 -35
- package/lib/cjs/utils/getApplicationLink.js +0 -2
- package/lib/cjs/utils/getCardDetails.d.ts +0 -16
- package/lib/cjs/utils/getCardDetails.js +0 -2
- package/lib/cjs/utils/getCustomerIdByToken.d.ts +0 -6
- package/lib/cjs/utils/getCustomerIdByToken.js +0 -2
- package/lib/cjs/utils/getDomain.d.ts +0 -4
- package/lib/cjs/utils/getDomain.js +0 -2
- package/lib/cjs/utils/getErrors.d.ts +0 -19
- package/lib/cjs/utils/getErrors.js +0 -2
- package/lib/cjs/utils/getLineItemsCount.d.ts +0 -10
- package/lib/cjs/utils/getLineItemsCount.js +0 -2
- package/lib/cjs/utils/getLoaderComponent.d.ts +0 -3
- package/lib/cjs/utils/getLoaderComponent.js +0 -2
- package/lib/cjs/utils/getPaymentAttributes.d.ts +0 -17
- package/lib/cjs/utils/getPaymentAttributes.js +0 -2
- package/lib/cjs/utils/getPrices.d.ts +0 -6
- package/lib/cjs/utils/getPrices.js +0 -2
- package/lib/cjs/utils/getPublicIp.d.ts +0 -1
- package/lib/cjs/utils/getPublicIp.js +0 -2
- package/lib/cjs/utils/getSdk.d.ts +0 -3
- package/lib/cjs/utils/getSdk.js +0 -2
- package/lib/cjs/utils/getSkus.d.ts +0 -3
- package/lib/cjs/utils/getSkus.js +0 -2
- package/lib/cjs/utils/hasSubscriptions.d.ts +0 -7
- package/lib/cjs/utils/hasSubscriptions.js +0 -2
- package/lib/cjs/utils/hooks/useCustomContext.d.ts +0 -21
- package/lib/cjs/utils/hooks/useCustomContext.js +0 -2
- package/lib/cjs/utils/hooks/useExternalScript.d.ts +0 -1
- package/lib/cjs/utils/hooks/useExternalScript.js +0 -2
- package/lib/cjs/utils/icons.d.ts +0 -2
- package/lib/cjs/utils/icons.js +0 -2
- package/lib/cjs/utils/isDate.d.ts +0 -1
- package/lib/cjs/utils/isDate.js +0 -2
- package/lib/cjs/utils/isEmpty.d.ts +0 -1
- package/lib/cjs/utils/isEmpty.js +0 -2
- package/lib/cjs/utils/isGuestToken.d.ts +0 -6
- package/lib/cjs/utils/isGuestToken.js +0 -2
- package/lib/cjs/utils/isJSON.d.ts +0 -1
- package/lib/cjs/utils/isJSON.js +0 -2
- package/lib/cjs/utils/jwt.d.ts +0 -27
- package/lib/cjs/utils/jwt.js +0 -2
- package/lib/cjs/utils/localStorage.d.ts +0 -11
- package/lib/cjs/utils/localStorage.js +0 -2
- package/lib/cjs/utils/omit.d.ts +0 -1
- package/lib/cjs/utils/omit.js +0 -2
- package/lib/cjs/utils/organization.d.ts +0 -18
- package/lib/cjs/utils/organization.js +0 -2
- package/lib/cjs/utils/payment-methods/sortPaymentMethods.d.ts +0 -2
- package/lib/cjs/utils/payment-methods/sortPaymentMethods.js +0 -2
- package/lib/cjs/utils/pick.d.ts +0 -1
- package/lib/cjs/utils/pick.js +0 -2
- package/lib/cjs/utils/placeholderImages.d.ts +0 -2
- package/lib/cjs/utils/placeholderImages.js +0 -2
- package/lib/cjs/utils/promisify.d.ts +0 -1
- package/lib/cjs/utils/promisify.js +0 -2
- package/lib/cjs/utils/replace.d.ts +0 -2
- package/lib/cjs/utils/replace.js +0 -2
- package/lib/cjs/utils/scrollbarWidth.d.ts +0 -1
- package/lib/cjs/utils/scrollbarWidth.js +0 -2
- package/lib/cjs/utils/shipments.d.ts +0 -3
- package/lib/cjs/utils/shipments.js +0 -2
- package/lib/cjs/utils/snakeToCamelCase.d.ts +0 -5
- package/lib/cjs/utils/snakeToCamelCase.js +0 -2
- package/lib/cjs/utils/stripe/retrievePaymentIntent.d.ts +0 -14
- package/lib/cjs/utils/stripe/retrievePaymentIntent.js +0 -2
- package/lib/cjs/utils/triggerAttributeHelper.d.ts +0 -31
- package/lib/cjs/utils/triggerAttributeHelper.js +0 -2
- package/lib/cjs/utils/updateOrderSubscriptionCustomerPaymentSource.d.ts +0 -8
- package/lib/cjs/utils/updateOrderSubscriptionCustomerPaymentSource.js +0 -2
- package/lib/cjs/utils/validateFormFields.d.ts +0 -16
- package/lib/cjs/utils/validateFormFields.js +0 -2
- package/lib/esm/components/ExternalFunction.d.ts +0 -7
- package/lib/esm/components/ExternalFunction.js +0 -2
- package/lib/esm/components/MetadataInput.d.ts +0 -5
- package/lib/esm/components/MetadataInput.js +0 -2
- package/lib/esm/components/SubmitButton.d.ts +0 -10
- package/lib/esm/components/SubmitButton.js +0 -2
- package/lib/esm/components/addresses/Address.d.ts +0 -31
- package/lib/esm/components/addresses/Address.js +0 -2
- package/lib/esm/components/addresses/AddressCountrySelector.d.ts +0 -34
- package/lib/esm/components/addresses/AddressCountrySelector.js +0 -2
- package/lib/esm/components/addresses/AddressField.d.ts +0 -61
- package/lib/esm/components/addresses/AddressField.js +0 -2
- package/lib/esm/components/addresses/AddressInput.d.ts +0 -34
- package/lib/esm/components/addresses/AddressInput.js +0 -2
- package/lib/esm/components/addresses/AddressInputSelect.d.ts +0 -29
- package/lib/esm/components/addresses/AddressInputSelect.js +0 -2
- package/lib/esm/components/addresses/AddressStateSelector.d.ts +0 -36
- package/lib/esm/components/addresses/AddressStateSelector.js +0 -2
- package/lib/esm/components/addresses/AddressesContainer.d.ts +0 -40
- package/lib/esm/components/addresses/AddressesContainer.js +0 -2
- package/lib/esm/components/addresses/AddressesEmpty.d.ts +0 -26
- package/lib/esm/components/addresses/AddressesEmpty.js +0 -2
- package/lib/esm/components/addresses/BillingAddressContainer.d.ts +0 -6
- package/lib/esm/components/addresses/BillingAddressContainer.js +0 -2
- package/lib/esm/components/addresses/BillingAddressForm.d.ts +0 -34
- package/lib/esm/components/addresses/BillingAddressForm.js +0 -2
- package/lib/esm/components/addresses/SaveAddressesButton.d.ts +0 -18
- package/lib/esm/components/addresses/SaveAddressesButton.js +0 -2
- package/lib/esm/components/addresses/ShippingAddressContainer.d.ts +0 -7
- package/lib/esm/components/addresses/ShippingAddressContainer.js +0 -2
- package/lib/esm/components/addresses/ShippingAddressForm.d.ts +0 -31
- package/lib/esm/components/addresses/ShippingAddressForm.js +0 -2
- package/lib/esm/components/auth/CommerceLayer.d.ts +0 -25
- package/lib/esm/components/auth/CommerceLayer.js +0 -2
- package/lib/esm/components/customers/CustomerAddressForm.d.ts +0 -13
- package/lib/esm/components/customers/CustomerAddressForm.js +0 -2
- package/lib/esm/components/customers/CustomerContainer.d.ts +0 -38
- package/lib/esm/components/customers/CustomerContainer.js +0 -2
- package/lib/esm/components/customers/CustomerField.d.ts +0 -25
- package/lib/esm/components/customers/CustomerField.js +0 -2
- package/lib/esm/components/customers/CustomerInput.d.ts +0 -11
- package/lib/esm/components/customers/CustomerInput.js +0 -2
- package/lib/esm/components/customers/CustomerPaymentSource.d.ts +0 -11
- package/lib/esm/components/customers/CustomerPaymentSource.js +0 -2
- package/lib/esm/components/customers/CustomerPaymentSourceEmpty.d.ts +0 -14
- package/lib/esm/components/customers/CustomerPaymentSourceEmpty.js +0 -2
- package/lib/esm/components/customers/MyAccountLink.d.ts +0 -38
- package/lib/esm/components/customers/MyAccountLink.js +0 -2
- package/lib/esm/components/customers/MyIdentityLink.d.ts +0 -59
- package/lib/esm/components/customers/MyIdentityLink.js +0 -2
- package/lib/esm/components/customers/SaveCustomerButton.d.ts +0 -12
- package/lib/esm/components/customers/SaveCustomerButton.js +0 -2
- package/lib/esm/components/errors/Errors.d.ts +0 -31
- package/lib/esm/components/errors/Errors.js +0 -2
- package/lib/esm/components/gift_cards/GiftCard.d.ts +0 -10
- package/lib/esm/components/gift_cards/GiftCard.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardContainer.d.ts +0 -6
- package/lib/esm/components/gift_cards/GiftCardContainer.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardCurrencySelector.d.ts +0 -7
- package/lib/esm/components/gift_cards/GiftCardCurrencySelector.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardInput.d.ts +0 -7
- package/lib/esm/components/gift_cards/GiftCardInput.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardOrCouponCode.d.ts +0 -16
- package/lib/esm/components/gift_cards/GiftCardOrCouponCode.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardOrCouponForm.d.ts +0 -15
- package/lib/esm/components/gift_cards/GiftCardOrCouponForm.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardOrCouponInput.d.ts +0 -11
- package/lib/esm/components/gift_cards/GiftCardOrCouponInput.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardOrCouponRemoveButton.d.ts +0 -20
- package/lib/esm/components/gift_cards/GiftCardOrCouponRemoveButton.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardOrCouponSubmit.d.ts +0 -10
- package/lib/esm/components/gift_cards/GiftCardOrCouponSubmit.js +0 -2
- package/lib/esm/components/gift_cards/GiftCardRecipientInput.d.ts +0 -0
- package/lib/esm/components/gift_cards/GiftCardRecipientInput.js +0 -2
- package/lib/esm/components/in_stock_subscriptions/InStockSubscriptionButton.d.ts +0 -36
- package/lib/esm/components/in_stock_subscriptions/InStockSubscriptionButton.js +0 -2
- package/lib/esm/components/in_stock_subscriptions/InStockSubscriptionsContainer.d.ts +0 -10
- package/lib/esm/components/in_stock_subscriptions/InStockSubscriptionsContainer.js +0 -2
- package/lib/esm/components/line_items/LineItem.d.ts +0 -8
- package/lib/esm/components/line_items/LineItem.js +0 -2
- package/lib/esm/components/line_items/LineItemAmount.d.ts +0 -7
- package/lib/esm/components/line_items/LineItemAmount.js +0 -2
- package/lib/esm/components/line_items/LineItemCode.d.ts +0 -13
- package/lib/esm/components/line_items/LineItemCode.js +0 -2
- package/lib/esm/components/line_items/LineItemField.d.ts +0 -14
- package/lib/esm/components/line_items/LineItemField.js +0 -2
- package/lib/esm/components/line_items/LineItemImage.d.ts +0 -17
- package/lib/esm/components/line_items/LineItemImage.js +0 -2
- package/lib/esm/components/line_items/LineItemName.d.ts +0 -12
- package/lib/esm/components/line_items/LineItemName.js +0 -2
- package/lib/esm/components/line_items/LineItemOption.d.ts +0 -19
- package/lib/esm/components/line_items/LineItemOption.js +0 -2
- package/lib/esm/components/line_items/LineItemOptions.d.ts +0 -16
- package/lib/esm/components/line_items/LineItemOptions.js +0 -2
- package/lib/esm/components/line_items/LineItemQuantity.d.ts +0 -21
- package/lib/esm/components/line_items/LineItemQuantity.js +0 -2
- package/lib/esm/components/line_items/LineItemRemoveLink.d.ts +0 -14
- package/lib/esm/components/line_items/LineItemRemoveLink.js +0 -2
- package/lib/esm/components/line_items/LineItemsContainer.d.ts +0 -9
- package/lib/esm/components/line_items/LineItemsContainer.js +0 -2
- package/lib/esm/components/line_items/LineItemsCount.d.ts +0 -12
- package/lib/esm/components/line_items/LineItemsCount.js +0 -2
- package/lib/esm/components/line_items/LineItemsEmpty.d.ts +0 -12
- package/lib/esm/components/line_items/LineItemsEmpty.js +0 -2
- package/lib/esm/components/orders/AddToCartButton.d.ts +0 -95
- package/lib/esm/components/orders/AddToCartButton.js +0 -2
- package/lib/esm/components/orders/AdjustmentAmount.d.ts +0 -4
- package/lib/esm/components/orders/AdjustmentAmount.js +0 -2
- package/lib/esm/components/orders/CartLink.d.ts +0 -47
- package/lib/esm/components/orders/CartLink.js +0 -2
- package/lib/esm/components/orders/CheckoutLink.d.ts +0 -28
- package/lib/esm/components/orders/CheckoutLink.js +0 -2
- package/lib/esm/components/orders/DiscountAmount.d.ts +0 -4
- package/lib/esm/components/orders/DiscountAmount.js +0 -2
- package/lib/esm/components/orders/GiftCardAmount.d.ts +0 -4
- package/lib/esm/components/orders/GiftCardAmount.js +0 -2
- package/lib/esm/components/orders/HostedCart.d.ts +0 -58
- package/lib/esm/components/orders/HostedCart.js +0 -2
- package/lib/esm/components/orders/OrderContainer.d.ts +0 -62
- package/lib/esm/components/orders/OrderContainer.js +0 -2
- package/lib/esm/components/orders/OrderList.d.ts +0 -83
- package/lib/esm/components/orders/OrderList.js +0 -2
- package/lib/esm/components/orders/OrderListEmpty.d.ts +0 -17
- package/lib/esm/components/orders/OrderListEmpty.js +0 -2
- package/lib/esm/components/orders/OrderListPaginationButtons.d.ts +0 -48
- package/lib/esm/components/orders/OrderListPaginationButtons.js +0 -2
- package/lib/esm/components/orders/OrderListPaginationInfo.d.ts +0 -29
- package/lib/esm/components/orders/OrderListPaginationInfo.js +0 -2
- package/lib/esm/components/orders/OrderListRow.d.ts +0 -29
- package/lib/esm/components/orders/OrderListRow.js +0 -2
- package/lib/esm/components/orders/OrderNumber.d.ts +0 -5
- package/lib/esm/components/orders/OrderNumber.js +0 -2
- package/lib/esm/components/orders/OrderStorage.d.ts +0 -31
- package/lib/esm/components/orders/OrderStorage.js +0 -2
- package/lib/esm/components/orders/PaymentMethodAmount.d.ts +0 -4
- package/lib/esm/components/orders/PaymentMethodAmount.js +0 -2
- package/lib/esm/components/orders/PlaceOrderButton.d.ts +0 -35
- package/lib/esm/components/orders/PlaceOrderButton.js +0 -2
- package/lib/esm/components/orders/PlaceOrderContainer.d.ts +0 -8
- package/lib/esm/components/orders/PlaceOrderContainer.js +0 -2
- package/lib/esm/components/orders/PrivacyAndTermsCheckbox.d.ts +0 -4
- package/lib/esm/components/orders/PrivacyAndTermsCheckbox.js +0 -2
- package/lib/esm/components/orders/ShippingAmount.d.ts +0 -4
- package/lib/esm/components/orders/ShippingAmount.js +0 -2
- package/lib/esm/components/orders/SubTotalAmount.d.ts +0 -4
- package/lib/esm/components/orders/SubTotalAmount.js +0 -2
- package/lib/esm/components/orders/TaxesAmount.d.ts +0 -4
- package/lib/esm/components/orders/TaxesAmount.js +0 -2
- package/lib/esm/components/orders/TotalAmount.d.ts +0 -4
- package/lib/esm/components/orders/TotalAmount.js +0 -2
- package/lib/esm/components/parcels/ParcelField.d.ts +0 -14
- package/lib/esm/components/parcels/ParcelField.js +0 -2
- package/lib/esm/components/parcels/ParcelLineItem.d.ts +0 -7
- package/lib/esm/components/parcels/ParcelLineItem.js +0 -2
- package/lib/esm/components/parcels/ParcelLineItemField.d.ts +0 -14
- package/lib/esm/components/parcels/ParcelLineItemField.js +0 -2
- package/lib/esm/components/parcels/ParcelLineItemsCount.d.ts +0 -18
- package/lib/esm/components/parcels/ParcelLineItemsCount.js +0 -2
- package/lib/esm/components/parcels/Parcels.d.ts +0 -7
- package/lib/esm/components/parcels/Parcels.js +0 -2
- package/lib/esm/components/parcels/ParcelsCount.d.ts +0 -18
- package/lib/esm/components/parcels/ParcelsCount.js +0 -2
- package/lib/esm/components/payment_gateways/AdyenGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/AdyenGateway.js +0 -2
- package/lib/esm/components/payment_gateways/BraintreeGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/BraintreeGateway.js +0 -2
- package/lib/esm/components/payment_gateways/CheckoutComGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/CheckoutComGateway.js +0 -2
- package/lib/esm/components/payment_gateways/ExternalGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/ExternalGateway.js +0 -2
- package/lib/esm/components/payment_gateways/KlarnaGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/KlarnaGateway.js +0 -2
- package/lib/esm/components/payment_gateways/PaymentGateway.d.ts +0 -16
- package/lib/esm/components/payment_gateways/PaymentGateway.js +0 -2
- package/lib/esm/components/payment_gateways/PaypalGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/PaypalGateway.js +0 -2
- package/lib/esm/components/payment_gateways/StripeGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/StripeGateway.js +0 -2
- package/lib/esm/components/payment_gateways/WireTransferGateway.d.ts +0 -5
- package/lib/esm/components/payment_gateways/WireTransferGateway.js +0 -2
- package/lib/esm/components/payment_methods/PaymentMethod.d.ts +0 -45
- package/lib/esm/components/payment_methods/PaymentMethod.js +0 -2
- package/lib/esm/components/payment_methods/PaymentMethodName.d.ts +0 -10
- package/lib/esm/components/payment_methods/PaymentMethodName.js +0 -2
- package/lib/esm/components/payment_methods/PaymentMethodPrice.d.ts +0 -8
- package/lib/esm/components/payment_methods/PaymentMethodPrice.js +0 -2
- package/lib/esm/components/payment_methods/PaymentMethodRadioButton.d.ts +0 -17
- package/lib/esm/components/payment_methods/PaymentMethodRadioButton.js +0 -2
- package/lib/esm/components/payment_methods/PaymentMethodsContainer.d.ts +0 -8
- package/lib/esm/components/payment_methods/PaymentMethodsContainer.js +0 -2
- package/lib/esm/components/payment_source/AdyenPayment.d.ts +0 -54
- package/lib/esm/components/payment_source/AdyenPayment.js +0 -2
- package/lib/esm/components/payment_source/BraintreePayment.d.ts +0 -32
- package/lib/esm/components/payment_source/BraintreePayment.js +0 -2
- package/lib/esm/components/payment_source/CheckoutComPayment.d.ts +0 -23
- package/lib/esm/components/payment_source/CheckoutComPayment.js +0 -2
- package/lib/esm/components/payment_source/ExternalPayment.d.ts +0 -24
- package/lib/esm/components/payment_source/ExternalPayment.js +0 -2
- package/lib/esm/components/payment_source/KlarnaPayment.d.ts +0 -10
- package/lib/esm/components/payment_source/KlarnaPayment.js +0 -2
- package/lib/esm/components/payment_source/PaymentSource.d.ts +0 -19
- package/lib/esm/components/payment_source/PaymentSource.js +0 -2
- package/lib/esm/components/payment_source/PaymentSourceBrandIcon.d.ts +0 -15
- package/lib/esm/components/payment_source/PaymentSourceBrandIcon.js +0 -2
- package/lib/esm/components/payment_source/PaymentSourceBrandName.d.ts +0 -12
- package/lib/esm/components/payment_source/PaymentSourceBrandName.js +0 -2
- package/lib/esm/components/payment_source/PaymentSourceDetail.d.ts +0 -15
- package/lib/esm/components/payment_source/PaymentSourceDetail.js +0 -2
- package/lib/esm/components/payment_source/PaymentSourceEditButton.d.ts +0 -10
- package/lib/esm/components/payment_source/PaymentSourceEditButton.js +0 -2
- package/lib/esm/components/payment_source/PaypalPayment.d.ts +0 -12
- package/lib/esm/components/payment_source/PaypalPayment.js +0 -2
- package/lib/esm/components/payment_source/StripeExpressPayment.d.ts +0 -6
- package/lib/esm/components/payment_source/StripeExpressPayment.js +0 -2
- package/lib/esm/components/payment_source/StripePayment.d.ts +0 -21
- package/lib/esm/components/payment_source/StripePayment.js +0 -2
- package/lib/esm/components/payment_source/WireTransferPayment.d.ts +0 -12
- package/lib/esm/components/payment_source/WireTransferPayment.js +0 -2
- package/lib/esm/components/prices/Price.d.ts +0 -35
- package/lib/esm/components/prices/Price.js +0 -2
- package/lib/esm/components/prices/PricesContainer.d.ts +0 -41
- package/lib/esm/components/prices/PricesContainer.js +0 -2
- package/lib/esm/components/shipments/Shipment.d.ts +0 -10
- package/lib/esm/components/shipments/Shipment.js +0 -2
- package/lib/esm/components/shipments/ShipmentField.d.ts +0 -12
- package/lib/esm/components/shipments/ShipmentField.js +0 -2
- package/lib/esm/components/shipments/ShipmentsContainer.d.ts +0 -6
- package/lib/esm/components/shipments/ShipmentsContainer.js +0 -2
- package/lib/esm/components/shipments/ShipmentsCount.d.ts +0 -18
- package/lib/esm/components/shipments/ShipmentsCount.js +0 -2
- package/lib/esm/components/shipping_methods/ShippingMethod.d.ts +0 -8
- package/lib/esm/components/shipping_methods/ShippingMethod.js +0 -2
- package/lib/esm/components/shipping_methods/ShippingMethodName.d.ts +0 -11
- package/lib/esm/components/shipping_methods/ShippingMethodName.js +0 -2
- package/lib/esm/components/shipping_methods/ShippingMethodPrice.d.ts +0 -20
- package/lib/esm/components/shipping_methods/ShippingMethodPrice.js +0 -2
- package/lib/esm/components/shipping_methods/ShippingMethodRadioButton.d.ts +0 -17
- package/lib/esm/components/shipping_methods/ShippingMethodRadioButton.js +0 -2
- package/lib/esm/components/skus/AvailabilityContainer.d.ts +0 -34
- package/lib/esm/components/skus/AvailabilityContainer.js +0 -2
- package/lib/esm/components/skus/AvailabilityTemplate.d.ts +0 -52
- package/lib/esm/components/skus/AvailabilityTemplate.js +0 -2
- package/lib/esm/components/skus/DeliveryLeadTime.d.ts +0 -10
- package/lib/esm/components/skus/DeliveryLeadTime.js +0 -2
- package/lib/esm/components/skus/SkuField.d.ts +0 -25
- package/lib/esm/components/skus/SkuField.js +0 -2
- package/lib/esm/components/skus/SkuList.d.ts +0 -10
- package/lib/esm/components/skus/SkuList.js +0 -2
- package/lib/esm/components/skus/SkuListsContainer.d.ts +0 -6
- package/lib/esm/components/skus/SkuListsContainer.js +0 -2
- package/lib/esm/components/skus/Skus.d.ts +0 -18
- package/lib/esm/components/skus/Skus.js +0 -2
- package/lib/esm/components/skus/SkusContainer.d.ts +0 -31
- package/lib/esm/components/skus/SkusContainer.js +0 -2
- package/lib/esm/components/stock_transfers/StockTransfer.d.ts +0 -7
- package/lib/esm/components/stock_transfers/StockTransfer.js +0 -2
- package/lib/esm/components/stock_transfers/StockTransferField.d.ts +0 -10
- package/lib/esm/components/stock_transfers/StockTransferField.js +0 -2
- package/lib/esm/components/utils/AddressCardsTemplate.d.ts +0 -26
- package/lib/esm/components/utils/AddressCardsTemplate.js +0 -2
- package/lib/esm/components/utils/BaseField.d.ts +0 -8
- package/lib/esm/components/utils/BaseField.js +0 -2
- package/lib/esm/components/utils/BaseInput.d.ts +0 -5
- package/lib/esm/components/utils/BaseInput.js +0 -2
- package/lib/esm/components/utils/BaseOrderPrice.d.ts +0 -6
- package/lib/esm/components/utils/BaseOrderPrice.js +0 -2
- package/lib/esm/components/utils/BaseSelect.d.ts +0 -5
- package/lib/esm/components/utils/BaseSelect.js +0 -2
- package/lib/esm/components/utils/ErrorBoundary.d.ts +0 -14
- package/lib/esm/components/utils/ErrorBoundary.js +0 -2
- package/lib/esm/components/utils/GenericFieldComponent.d.ts +0 -58
- package/lib/esm/components/utils/GenericFieldComponent.js +0 -2
- package/lib/esm/components/utils/Parent.d.ts +0 -6
- package/lib/esm/components/utils/Parent.js +0 -2
- package/lib/esm/components/utils/PaymentCardsTemplate.d.ts +0 -41
- package/lib/esm/components/utils/PaymentCardsTemplate.js +0 -2
- package/lib/esm/components/utils/PriceTemplate.d.ts +0 -8
- package/lib/esm/components/utils/PriceTemplate.js +0 -2
- package/lib/esm/components/utils/getAllErrors.d.ts +0 -16
- package/lib/esm/components/utils/getAllErrors.js +0 -2
- package/lib/esm/config/currency.d.ts +0 -5
- package/lib/esm/config/currency.js +0 -2
- package/lib/esm/context/AddressChildrenContext.d.ts +0 -6
- package/lib/esm/context/AddressChildrenContext.js +0 -2
- package/lib/esm/context/AddressContext.d.ts +0 -18
- package/lib/esm/context/AddressContext.js +0 -2
- package/lib/esm/context/AvailabilityContext.d.ts +0 -2
- package/lib/esm/context/AvailabilityContext.js +0 -2
- package/lib/esm/context/BillingAddressContext.d.ts +0 -9
- package/lib/esm/context/BillingAddressContext.js +0 -2
- package/lib/esm/context/BillingAddressFormContext.d.ts +0 -22
- package/lib/esm/context/BillingAddressFormContext.js +0 -2
- package/lib/esm/context/CommerceLayerContext.d.ts +0 -6
- package/lib/esm/context/CommerceLayerContext.js +0 -2
- package/lib/esm/context/CouponAndGiftCardFormContext.d.ts +0 -8
- package/lib/esm/context/CouponAndGiftCardFormContext.js +0 -2
- package/lib/esm/context/CustomerAddressFormContext.d.ts +0 -17
- package/lib/esm/context/CustomerAddressFormContext.js +0 -2
- package/lib/esm/context/CustomerContext.d.ts +0 -29
- package/lib/esm/context/CustomerContext.js +0 -2
- package/lib/esm/context/CustomerPaymentSourceContext.d.ts +0 -11
- package/lib/esm/context/CustomerPaymentSourceContext.js +0 -2
- package/lib/esm/context/ExternalFunctionContext.d.ts +0 -11
- package/lib/esm/context/ExternalFunctionContext.js +0 -2
- package/lib/esm/context/GiftCardContext.d.ts +0 -10
- package/lib/esm/context/GiftCardContext.js +0 -2
- package/lib/esm/context/InStockSubscriptionContext.d.ts +0 -6
- package/lib/esm/context/InStockSubscriptionContext.js +0 -2
- package/lib/esm/context/LineItemChildrenContext.d.ts +0 -8
- package/lib/esm/context/LineItemChildrenContext.js +0 -2
- package/lib/esm/context/LineItemContext.d.ts +0 -7
- package/lib/esm/context/LineItemContext.js +0 -2
- package/lib/esm/context/LineItemOptionChildrenContext.d.ts +0 -9
- package/lib/esm/context/LineItemOptionChildrenContext.js +0 -2
- package/lib/esm/context/OrderContext.d.ts +0 -30
- package/lib/esm/context/OrderContext.js +0 -2
- package/lib/esm/context/OrderListChildrenContext.d.ts +0 -73
- package/lib/esm/context/OrderListChildrenContext.js +0 -2
- package/lib/esm/context/OrderListPaginationContext.d.ts +0 -15
- package/lib/esm/context/OrderListPaginationContext.js +0 -2
- package/lib/esm/context/OrderStorageContext.d.ts +0 -10
- package/lib/esm/context/OrderStorageContext.js +0 -2
- package/lib/esm/context/ParcelChildrenContext.d.ts +0 -6
- package/lib/esm/context/ParcelChildrenContext.js +0 -2
- package/lib/esm/context/ParcelLineItemChildrenContext.d.ts +0 -6
- package/lib/esm/context/ParcelLineItemChildrenContext.js +0 -2
- package/lib/esm/context/PaymentMethodChildrenContext.d.ts +0 -10
- package/lib/esm/context/PaymentMethodChildrenContext.js +0 -2
- package/lib/esm/context/PaymentMethodContext.d.ts +0 -13
- package/lib/esm/context/PaymentMethodContext.js +0 -2
- package/lib/esm/context/PaymentSourceContext.d.ts +0 -14
- package/lib/esm/context/PaymentSourceContext.js +0 -2
- package/lib/esm/context/PlaceOrderContext.d.ts +0 -12
- package/lib/esm/context/PlaceOrderContext.js +0 -2
- package/lib/esm/context/PricesContext.d.ts +0 -6
- package/lib/esm/context/PricesContext.js +0 -2
- package/lib/esm/context/ShipmentChildrenContext.d.ts +0 -13
- package/lib/esm/context/ShipmentChildrenContext.js +0 -2
- package/lib/esm/context/ShipmentContext.d.ts +0 -10
- package/lib/esm/context/ShipmentContext.js +0 -2
- package/lib/esm/context/ShippingAddressContext.d.ts +0 -9
- package/lib/esm/context/ShippingAddressContext.js +0 -2
- package/lib/esm/context/ShippingAddressFormContext.d.ts +0 -3
- package/lib/esm/context/ShippingAddressFormContext.js +0 -2
- package/lib/esm/context/ShippingMethodChildrenContext.d.ts +0 -9
- package/lib/esm/context/ShippingMethodChildrenContext.js +0 -2
- package/lib/esm/context/SkuChildrenContext.d.ts +0 -8
- package/lib/esm/context/SkuChildrenContext.js +0 -2
- package/lib/esm/context/SkuContext.d.ts +0 -8
- package/lib/esm/context/SkuContext.js +0 -2
- package/lib/esm/context/SkuListsContext.d.ts +0 -5
- package/lib/esm/context/SkuListsContext.js +0 -2
- package/lib/esm/context/StockTransferChildrenContext.d.ts +0 -6
- package/lib/esm/context/StockTransferChildrenContext.js +0 -2
- package/lib/esm/hooks/useCommerceLayer.d.ts +0 -12
- package/lib/esm/hooks/useCommerceLayer.js +0 -2
- package/lib/esm/hooks/useCustomerContainer.d.ts +0 -12
- package/lib/esm/hooks/useCustomerContainer.js +0 -2
- package/lib/esm/hooks/useOrderContainer.d.ts +0 -16
- package/lib/esm/hooks/useOrderContainer.js +0 -2
- package/lib/esm/index.d.ts +0 -107
- package/lib/esm/index.js +0 -2
- package/lib/esm/reducers/AddressReducer.d.ts +0 -80
- package/lib/esm/reducers/AddressReducer.js +0 -2
- package/lib/esm/reducers/AvailabilityReducer.d.ts +0 -53
- package/lib/esm/reducers/AvailabilityReducer.js +0 -2
- package/lib/esm/reducers/BillingAddressReducer.d.ts +0 -31
- package/lib/esm/reducers/BillingAddressReducer.js +0 -2
- package/lib/esm/reducers/CustomerReducer.d.ts +0 -183
- package/lib/esm/reducers/CustomerReducer.js +0 -2
- package/lib/esm/reducers/GiftCardReducer.d.ts +0 -66
- package/lib/esm/reducers/GiftCardReducer.js +0 -2
- package/lib/esm/reducers/InStockSubscriptionReducer.d.ts +0 -33
- package/lib/esm/reducers/InStockSubscriptionReducer.js +0 -2
- package/lib/esm/reducers/LineItemReducer.d.ts +0 -47
- package/lib/esm/reducers/LineItemReducer.js +0 -2
- package/lib/esm/reducers/OrderReducer.d.ts +0 -171
- package/lib/esm/reducers/OrderReducer.js +0 -2
- package/lib/esm/reducers/PaymentMethodReducer.d.ts +0 -161
- package/lib/esm/reducers/PaymentMethodReducer.js +0 -2
- package/lib/esm/reducers/PlaceOrderReducer.d.ts +0 -72
- package/lib/esm/reducers/PlaceOrderReducer.js +0 -2
- package/lib/esm/reducers/PriceReducer.d.ts +0 -35
- package/lib/esm/reducers/PriceReducer.js +0 -2
- package/lib/esm/reducers/ShipmentReducer.d.ts +0 -41
- package/lib/esm/reducers/ShipmentReducer.js +0 -2
- package/lib/esm/reducers/ShippingAddressReducer.d.ts +0 -32
- package/lib/esm/reducers/ShippingAddressReducer.js +0 -2
- package/lib/esm/reducers/SkuListsReducer.d.ts +0 -21
- package/lib/esm/reducers/SkuListsReducer.js +0 -2
- package/lib/esm/reducers/SkuReducer.d.ts +0 -21
- package/lib/esm/reducers/SkuReducer.js +0 -2
- package/lib/esm/typings/errors.d.ts +0 -15
- package/lib/esm/typings/errors.js +0 -2
- package/lib/esm/typings/globals.d.ts +0 -6
- package/lib/esm/typings/globals.js +0 -2
- package/lib/esm/typings/index.d.ts +0 -117
- package/lib/esm/typings/index.js +0 -2
- package/lib/esm/utils/PropsType.d.ts +0 -33
- package/lib/esm/utils/PropsType.js +0 -2
- package/lib/esm/utils/addressesManager.d.ts +0 -64
- package/lib/esm/utils/addressesManager.js +0 -2
- package/lib/esm/utils/adyen/manageGiftCard.d.ts +0 -16
- package/lib/esm/utils/adyen/manageGiftCard.js +0 -2
- package/lib/esm/utils/baseReducer.d.ts +0 -3
- package/lib/esm/utils/baseReducer.js +0 -2
- package/lib/esm/utils/browserInfo.d.ts +0 -12
- package/lib/esm/utils/browserInfo.js +0 -2
- package/lib/esm/utils/canPlaceOrder.d.ts +0 -5
- package/lib/esm/utils/canPlaceOrder.js +0 -2
- package/lib/esm/utils/checkIncludeResource.d.ts +0 -8
- package/lib/esm/utils/checkIncludeResource.js +0 -2
- package/lib/esm/utils/compareObjAttribute.d.ts +0 -7
- package/lib/esm/utils/compareObjAttribute.js +0 -2
- package/lib/esm/utils/countryStateCity.d.ts +0 -801
- package/lib/esm/utils/countryStateCity.js +0 -2
- package/lib/esm/utils/customMessages.d.ts +0 -2
- package/lib/esm/utils/customMessages.js +0 -2
- package/lib/esm/utils/customerOrderOptions.d.ts +0 -3
- package/lib/esm/utils/customerOrderOptions.js +0 -2
- package/lib/esm/utils/events.d.ts +0 -5
- package/lib/esm/utils/events.js +0 -2
- package/lib/esm/utils/expressPaymentHelper.d.ts +0 -92
- package/lib/esm/utils/expressPaymentHelper.js +0 -2
- package/lib/esm/utils/filterChildren.d.ts +0 -12
- package/lib/esm/utils/filterChildren.js +0 -2
- package/lib/esm/utils/formCleaner.d.ts +0 -4
- package/lib/esm/utils/formCleaner.js +0 -2
- package/lib/esm/utils/getAmount.d.ts +0 -7
- package/lib/esm/utils/getAmount.js +0 -2
- package/lib/esm/utils/getApplicationLink.d.ts +0 -35
- package/lib/esm/utils/getApplicationLink.js +0 -2
- package/lib/esm/utils/getCardDetails.d.ts +0 -16
- package/lib/esm/utils/getCardDetails.js +0 -2
- package/lib/esm/utils/getCustomerIdByToken.d.ts +0 -6
- package/lib/esm/utils/getCustomerIdByToken.js +0 -2
- package/lib/esm/utils/getDomain.d.ts +0 -4
- package/lib/esm/utils/getDomain.js +0 -2
- package/lib/esm/utils/getErrors.d.ts +0 -19
- package/lib/esm/utils/getErrors.js +0 -2
- package/lib/esm/utils/getLineItemsCount.d.ts +0 -10
- package/lib/esm/utils/getLineItemsCount.js +0 -2
- package/lib/esm/utils/getLoaderComponent.d.ts +0 -3
- package/lib/esm/utils/getLoaderComponent.js +0 -2
- package/lib/esm/utils/getPaymentAttributes.d.ts +0 -17
- package/lib/esm/utils/getPaymentAttributes.js +0 -2
- package/lib/esm/utils/getPrices.d.ts +0 -6
- package/lib/esm/utils/getPrices.js +0 -2
- package/lib/esm/utils/getPublicIp.d.ts +0 -1
- package/lib/esm/utils/getPublicIp.js +0 -2
- package/lib/esm/utils/getSdk.d.ts +0 -3
- package/lib/esm/utils/getSdk.js +0 -2
- package/lib/esm/utils/getSkus.d.ts +0 -3
- package/lib/esm/utils/getSkus.js +0 -2
- package/lib/esm/utils/hasSubscriptions.d.ts +0 -7
- package/lib/esm/utils/hasSubscriptions.js +0 -2
- package/lib/esm/utils/hooks/useCustomContext.d.ts +0 -21
- package/lib/esm/utils/hooks/useCustomContext.js +0 -2
- package/lib/esm/utils/hooks/useExternalScript.d.ts +0 -1
- package/lib/esm/utils/hooks/useExternalScript.js +0 -2
- package/lib/esm/utils/icons.d.ts +0 -2
- package/lib/esm/utils/icons.js +0 -2
- package/lib/esm/utils/isDate.d.ts +0 -1
- package/lib/esm/utils/isDate.js +0 -2
- package/lib/esm/utils/isEmpty.d.ts +0 -1
- package/lib/esm/utils/isEmpty.js +0 -2
- package/lib/esm/utils/isGuestToken.d.ts +0 -6
- package/lib/esm/utils/isGuestToken.js +0 -2
- package/lib/esm/utils/isJSON.d.ts +0 -1
- package/lib/esm/utils/isJSON.js +0 -2
- package/lib/esm/utils/jwt.d.ts +0 -27
- package/lib/esm/utils/jwt.js +0 -2
- package/lib/esm/utils/localStorage.d.ts +0 -11
- package/lib/esm/utils/localStorage.js +0 -2
- package/lib/esm/utils/omit.d.ts +0 -1
- package/lib/esm/utils/omit.js +0 -2
- package/lib/esm/utils/organization.d.ts +0 -18
- package/lib/esm/utils/organization.js +0 -2
- package/lib/esm/utils/payment-methods/sortPaymentMethods.d.ts +0 -2
- package/lib/esm/utils/payment-methods/sortPaymentMethods.js +0 -2
- package/lib/esm/utils/pick.d.ts +0 -1
- package/lib/esm/utils/pick.js +0 -2
- package/lib/esm/utils/placeholderImages.d.ts +0 -2
- package/lib/esm/utils/placeholderImages.js +0 -2
- package/lib/esm/utils/promisify.d.ts +0 -1
- package/lib/esm/utils/promisify.js +0 -2
- package/lib/esm/utils/replace.d.ts +0 -2
- package/lib/esm/utils/replace.js +0 -2
- package/lib/esm/utils/scrollbarWidth.d.ts +0 -1
- package/lib/esm/utils/scrollbarWidth.js +0 -2
- package/lib/esm/utils/shipments.d.ts +0 -3
- package/lib/esm/utils/shipments.js +0 -2
- package/lib/esm/utils/snakeToCamelCase.d.ts +0 -5
- package/lib/esm/utils/snakeToCamelCase.js +0 -2
- package/lib/esm/utils/stripe/retrievePaymentIntent.d.ts +0 -14
- package/lib/esm/utils/stripe/retrievePaymentIntent.js +0 -2
- package/lib/esm/utils/triggerAttributeHelper.d.ts +0 -31
- package/lib/esm/utils/triggerAttributeHelper.js +0 -2
- package/lib/esm/utils/updateOrderSubscriptionCustomerPaymentSource.d.ts +0 -8
- package/lib/esm/utils/updateOrderSubscriptionCustomerPaymentSource.js +0 -2
- package/lib/esm/utils/validateFormFields.d.ts +0 -16
- package/lib/esm/utils/validateFormFields.js +0 -2
- package/lib/tsconfig.prod.esm.tsbuildinfo +0 -1
- package/lib/tsconfig.prod.tsbuildinfo +0 -1
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShipmentsContainer=ShipmentsContainer;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),ShipmentContext_1=tslib_1.__importStar(require("../../context/ShipmentContext")),react_1=require("react"),ShipmentReducer_1=tslib_1.__importStar(require("../../reducers/ShipmentReducer")),OrderContext_1=tslib_1.__importDefault(require("../../context/OrderContext")),CommerceLayerContext_1=tslib_1.__importDefault(require("../../context/CommerceLayerContext")),isEmpty_1=tslib_1.__importDefault(require("lodash/isEmpty"));function ShipmentsContainer(props){const{children}=props,[state,dispatch]=(0,react_1.useReducer)(ShipmentReducer_1.default,ShipmentReducer_1.shipmentInitialState),{order,getOrder,include,addResourceToInclude,includeLoaded}=(0,react_1.useContext)(OrderContext_1.default),config=(0,react_1.useContext)(CommerceLayerContext_1.default);(0,react_1.useEffect)(()=>{include?.includes("shipments.available_shipping_methods")?includeLoaded?.["shipments.available_shipping_methods"]||addResourceToInclude({newResourceLoaded:{"shipments.available_shipping_methods":!0,"shipments.stock_line_items.line_item":!0,"shipments.shipping_method":!0,"shipments.stock_transfers.line_item":!0,"shipments.stock_location":!0,"shipments.parcels.parcel_line_items":!0}}):addResourceToInclude({newResource:["shipments.available_shipping_methods","shipments.stock_line_items.line_item","shipments.shipping_method","shipments.stock_transfers.line_item","shipments.stock_location","shipments.parcels.parcel_line_items"]})},[include?.length,includeLoaded!=null]),(0,react_1.useEffect)(()=>{order!=null&&!(0,isEmpty_1.default)(config)&&order.shipments&&(0,ShipmentReducer_1.getShipments)({order,dispatch,config})},[order?.shipments]),(0,react_1.useEffect)(()=>(order&&(order.shipments&&order.shipments.length>0&&order.shipments.map(shipment=>shipment.available_shipping_methods&&shipment.available_shipping_methods.length>0).includes(!1)&&(0,ShipmentReducer_1.setShipmentErrors)([...state.errors||[],{code:"NO_SHIPPING_METHODS",message:"No shipping methods",resource:"shipments"}],dispatch),order.line_items&&order.line_items.length>0&&order.line_items.filter(({item_type:itemType})=>itemType==="skus").map(lineItem=>{var _a,_b,_c,_d;return!!(((_a=lineItem.item)===null||_a===void 0?void 0:_a.do_not_ship)||((_b=lineItem.item)===null||_b===void 0?void 0:_b.do_not_track)||((_d=(_c=lineItem.item)===null||_c===void 0?void 0:_c.inventory)===null||_d===void 0?void 0:_d.quantity)>=lineItem?.quantity)}).includes(!1)&&(0,ShipmentReducer_1.setShipmentErrors)([...state.errors||[],{code:"OUT_OF_STOCK",message:"No stock available",resource:"line_items"}],dispatch)),()=>{(0,ShipmentReducer_1.setShipmentErrors)([],dispatch)}),[order?.shipments]);const contextValue=(0,react_1.useMemo)(()=>Object.assign(Object.assign({},state),{setShipmentErrors:errors=>{ShipmentContext_1.defaultShipmentContext.setShipmentErrors(errors,dispatch)},setShippingMethod:(shipmentId,shippingMethodId)=>tslib_1.__awaiter(this,void 0,void 0,function*(){return yield(0,ShipmentReducer_1.setShippingMethod)({shippingMethodId,shipmentId,config,getOrder,order})})}),[state]);return(0,jsx_runtime_1.jsx)(ShipmentContext_1.default.Provider,{value:contextValue,children})}exports.default=ShipmentsContainer;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import type { ChildrenFunction } from '../../typings/index';
|
|
2
|
-
import type { Shipment } from '@commercelayer/sdk';
|
|
3
|
-
import type { JSX } from "react";
|
|
4
|
-
interface ChildrenProps extends Omit<Props, 'children'> {
|
|
5
|
-
/**
|
|
6
|
-
* Shipments of the current order
|
|
7
|
-
*/
|
|
8
|
-
shipments?: Shipment[] | null;
|
|
9
|
-
/**
|
|
10
|
-
* Quantity of the shipments
|
|
11
|
-
*/
|
|
12
|
-
quantity: number;
|
|
13
|
-
}
|
|
14
|
-
interface Props extends Omit<JSX.IntrinsicElements['span'], 'children' | 'ref'> {
|
|
15
|
-
children?: ChildrenFunction<ChildrenProps>;
|
|
16
|
-
}
|
|
17
|
-
export declare function ShipmentsCount({ children, ...p }: Props): JSX.Element;
|
|
18
|
-
export default ShipmentsCount;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShipmentsCount=ShipmentsCount;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),Parent_1=tslib_1.__importDefault(require("../utils/Parent")),ShipmentContext_1=tslib_1.__importDefault(require("../../context/ShipmentContext")),useCustomContext_1=tslib_1.__importDefault(require("../../utils/hooks/useCustomContext"));function ShipmentsCount(_a){var _b,{children}=_a,p=tslib_1.__rest(_a,["children"]);const{shipments}=(0,useCustomContext_1.default)({context:ShipmentContext_1.default,contextComponentName:"ShipmentsContainer",currentComponentName:"ShipmentsCount",key:"shipments"}),quantity=(_b=shipments?.length)!==null&&_b!==void 0?_b:0,childrenProps=Object.assign(Object.assign({},p),{quantity,shipments});return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},childrenProps,{children})):(0,jsx_runtime_1.jsx)("span",Object.assign({},p,{children:quantity}))}exports.default=ShipmentsCount;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShippingMethod=ShippingMethod;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),ShippingMethodChildrenContext_1=tslib_1.__importDefault(require("../../context/ShippingMethodChildrenContext")),ShipmentChildrenContext_1=tslib_1.__importDefault(require("../../context/ShipmentChildrenContext")),isEmpty_1=tslib_1.__importDefault(require("lodash/isEmpty"));function ShippingMethod(props){const{children,readonly,emptyText="There are not any shipping method available"}=props,{shippingMethods,currentShippingMethodId,deliveryLeadTimes,shipment}=(0,react_1.useContext)(ShipmentChildrenContext_1.default),[items,setItems]=(0,react_1.useState)([]);(0,react_1.useEffect)(()=>{const methods=shippingMethods?.filter(s=>readonly?s.id===currentShippingMethodId:!0).map((shippingMethod,k)=>{var _a;const[deliveryLeadTimeForShipment]=(_a=deliveryLeadTimes?.filter(delivery=>{var _a2;const deliveryShippingMethodId=(_a2=delivery.shipping_method)===null||_a2===void 0?void 0:_a2.id;return shippingMethod.id===deliveryShippingMethodId}))!==null&&_a!==void 0?_a:[],shippingProps={shipmentId:shipment?.id,shippingMethod,currentShippingMethodId,deliveryLeadTimeForShipment};return(0,jsx_runtime_1.jsx)(ShippingMethodChildrenContext_1.default.Provider,{value:shippingProps,children},k)});return methods&&setItems(methods),()=>{setItems([])}},[currentShippingMethodId,deliveryLeadTimes,shippingMethods]);const components=!(0,isEmpty_1.default)(items)&&items||emptyText;return(0,jsx_runtime_1.jsx)(jsx_runtime_1.Fragment,{children:components})}exports.default=ShippingMethod;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
import type { ShippingMethod } from '@commercelayer/sdk';
|
|
3
|
-
type ChildrenProps = Omit<Props, 'children'> & {
|
|
4
|
-
label: string;
|
|
5
|
-
shippingMethod: ShippingMethod;
|
|
6
|
-
};
|
|
7
|
-
interface Props extends Omit<JSX.IntrinsicElements['label'], 'children' | 'ref'> {
|
|
8
|
-
children?: (props: ChildrenProps) => JSX.Element;
|
|
9
|
-
}
|
|
10
|
-
export declare function ShippingMethodName(props: Props): JSX.Element;
|
|
11
|
-
export default ShippingMethodName;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShippingMethodName=ShippingMethodName;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),ShippingMethodChildrenContext_1=tslib_1.__importDefault(require("../../context/ShippingMethodChildrenContext")),Parent_1=tslib_1.__importDefault(require("../utils/Parent"));function ShippingMethodName(props){var _a;const{shippingMethod,deliveryLeadTimeForShipment,shipmentId}=(0,react_1.useContext)(ShippingMethodChildrenContext_1.default),htmlFor=`shipment-${shipmentId??""}-${(_a=shippingMethod?.id)!==null&&_a!==void 0?_a:""}`||"",labelName=shippingMethod?.name,parentProps=Object.assign({shippingMethod,deliveryLeadTimeForShipment,label:labelName,htmlFor},props);return props.children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children:props.children})):(0,jsx_runtime_1.jsx)("label",Object.assign({htmlFor},props,{children:labelName}))}exports.default=ShippingMethodName;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
import type { BaseAmountComponent } from '../../typings/index';
|
|
3
|
-
type Props = BaseAmountComponent & {
|
|
4
|
-
/**
|
|
5
|
-
* The label to show when the price is free
|
|
6
|
-
*/
|
|
7
|
-
labelFreeOver?: string;
|
|
8
|
-
/**
|
|
9
|
-
* The label to show when the price is external
|
|
10
|
-
*/
|
|
11
|
-
labelExternal?: string;
|
|
12
|
-
} & ({
|
|
13
|
-
type?: 'amount';
|
|
14
|
-
base?: 'freeOver';
|
|
15
|
-
} | {
|
|
16
|
-
type?: 'amount' | 'amountForShipment';
|
|
17
|
-
base?: 'price';
|
|
18
|
-
});
|
|
19
|
-
export declare function ShippingMethodPrice(props: Props): JSX.Element;
|
|
20
|
-
export default ShippingMethodPrice;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShippingMethodPrice=ShippingMethodPrice;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),getAmount_1=tslib_1.__importDefault(require("../../utils/getAmount")),ShippingMethodChildrenContext_1=tslib_1.__importDefault(require("../../context/ShippingMethodChildrenContext")),Parent_1=tslib_1.__importDefault(require("../utils/Parent"));function ShippingMethodPrice(props){const{base="price_amount",type="for_shipment",format="formatted",labelFreeOver="Free",labelExternal="Price estimates after the shipping method selection"}=props,p=tslib_1.__rest(props,["base","type","format","labelFreeOver","labelExternal"]),{shippingMethod}=(0,react_1.useContext)(ShippingMethodChildrenContext_1.default),[price,setPrice]=(0,react_1.useState)(""),[priceCents,setPriceCents]=(0,react_1.useState)(0),scheme=shippingMethod?.scheme;(0,react_1.useEffect)(()=>{if(shippingMethod){const p2=(0,getAmount_1.default)({base,type,format,obj:shippingMethod});setPrice(p2);const pCents=(0,getAmount_1.default)({base:"price_amount",type:"for_shipment",format:"cents",obj:shippingMethod});setPriceCents(pCents)}return()=>{setPrice(""),setPriceCents(0)}},[shippingMethod]);const parentProps=Object.assign({price,scheme},p),finalPrice=priceCents===0?labelFreeOver:price;return props.children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children:props.children})):(0,jsx_runtime_1.jsx)("span",Object.assign({},p,{children:scheme==="external"?labelExternal:finalPrice}))}exports.default=ShippingMethodPrice;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
import type { Order, ShippingMethod } from '@commercelayer/sdk';
|
|
3
|
-
interface ShippingMethodRadioButtonType extends Omit<Props, 'children'> {
|
|
4
|
-
shippingMethod: ShippingMethod;
|
|
5
|
-
shipmentId: string;
|
|
6
|
-
}
|
|
7
|
-
interface TOnChange {
|
|
8
|
-
shippingMethod: ShippingMethod;
|
|
9
|
-
shipmentId: string;
|
|
10
|
-
order?: Order;
|
|
11
|
-
}
|
|
12
|
-
type Props = {
|
|
13
|
-
children?: (props: ShippingMethodRadioButtonType) => JSX.Element;
|
|
14
|
-
onChange?: (params: TOnChange) => void;
|
|
15
|
-
} & Omit<JSX.IntrinsicElements['input'], 'onChange' | 'ref' | 'children'>;
|
|
16
|
-
export declare function ShippingMethodRadioButton(props: Props): JSX.Element;
|
|
17
|
-
export default ShippingMethodRadioButton;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ShippingMethodRadioButton=ShippingMethodRadioButton;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),ShippingMethodChildrenContext_1=tslib_1.__importDefault(require("../../context/ShippingMethodChildrenContext")),Parent_1=tslib_1.__importDefault(require("../utils/Parent")),ShipmentContext_1=tslib_1.__importDefault(require("../../context/ShipmentContext"));function ShippingMethodRadioButton(props){const{onChange,children}=props,p=tslib_1.__rest(props,["onChange","children"]),[checked,setChecked]=(0,react_1.useState)(!1),[disabled,setDisabled]=(0,react_1.useState)(!1),{shippingMethod,currentShippingMethodId,shipmentId}=(0,react_1.useContext)(ShippingMethodChildrenContext_1.default),{setShippingMethod}=(0,react_1.useContext)(ShipmentContext_1.default),shippingMethodId=shippingMethod?.id,name=`shipment-${shipmentId??""}`,id=`${name}-${shippingMethodId??""}`;(0,react_1.useEffect)(()=>(setChecked(shippingMethodId===currentShippingMethodId),()=>{setChecked(!1)}),[currentShippingMethodId,shippingMethodId]);const handleOnChange=()=>tslib_1.__awaiter(this,void 0,void 0,function*(){if(setDisabled(!0),shipmentId&&shippingMethodId&&setShippingMethod!=null){const{order}=yield setShippingMethod(shipmentId,shippingMethodId);shippingMethod&&onChange!=null&&onChange({shippingMethod,shipmentId,order})}setDisabled(!1)}),parentProps=Object.assign({shippingMethod,shipmentId,handleOnChange,name,id,disabled},props);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)("input",Object.assign({disabled,type:"radio",name,id,onChange:e=>{e.preventDefault(),e.stopPropagation(),handleOnChange()},checked},p))}exports.default=ShippingMethodRadioButton;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { type ReactNode, type JSX } from 'react';
|
|
2
|
-
interface Props {
|
|
3
|
-
/**
|
|
4
|
-
* The children component
|
|
5
|
-
*/
|
|
6
|
-
children: ReactNode;
|
|
7
|
-
/**
|
|
8
|
-
* The sku code
|
|
9
|
-
*/
|
|
10
|
-
skuCode?: string;
|
|
11
|
-
/**
|
|
12
|
-
* The sku id. If you use this prop, the skuCode will be ignored and the sku will be fetched by id improving the performance
|
|
13
|
-
*/
|
|
14
|
-
skuId?: string;
|
|
15
|
-
/**
|
|
16
|
-
* Callback called when the quantity is updated
|
|
17
|
-
*/
|
|
18
|
-
getQuantity?: (quantity: number) => void;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Main container for the Availability components.
|
|
22
|
-
* It stores - in its context - the sku quantity returned from the `inventory_model` and the `delivery_lead_time` for the first shipping method found in the inventory model.
|
|
23
|
-
*
|
|
24
|
-
* It can be used to fetch the quantities for a specific `sku_code` passed as prop.
|
|
25
|
-
* <span title='Requirements' type='warning'>
|
|
26
|
-
* Must be a child of the `<CommerceLayer>` component. <br/>
|
|
27
|
-
* Can be a child of the `<SkusContainer>` component and receive the `sku_code` from its context.
|
|
28
|
-
* </span>
|
|
29
|
-
* <span title='Children' type='info'>
|
|
30
|
-
* `<AvailabilityTemplate>`
|
|
31
|
-
* </span>
|
|
32
|
-
*/
|
|
33
|
-
export declare function AvailabilityContainer({ children, skuCode, skuId, getQuantity }: Props): JSX.Element;
|
|
34
|
-
export default AvailabilityContainer;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.AvailabilityContainer=AvailabilityContainer;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),AvailabilityReducer_1=tslib_1.__importStar(require("../../reducers/AvailabilityReducer")),AvailabilityContext_1=tslib_1.__importDefault(require("../../context/AvailabilityContext")),CommerceLayerContext_1=tslib_1.__importDefault(require("../../context/CommerceLayerContext")),LineItemChildrenContext_1=tslib_1.__importDefault(require("../../context/LineItemChildrenContext")),SkuChildrenContext_1=tslib_1.__importDefault(require("../../context/SkuChildrenContext")),useCustomContext_1=tslib_1.__importDefault(require("../../utils/hooks/useCustomContext"));function AvailabilityContainer({children,skuCode,skuId,getQuantity}){const{lineItem}=(0,react_1.useContext)(LineItemChildrenContext_1.default),{sku}=(0,react_1.useContext)(SkuChildrenContext_1.default),{accessToken,endpoint}=(0,useCustomContext_1.default)({context:CommerceLayerContext_1.default,contextComponentName:"CommerceLayer",currentComponentName:"AvailabilityContainer",key:"accessToken"}),[state,dispatch]=(0,react_1.useReducer)(AvailabilityReducer_1.default,AvailabilityReducer_1.availabilityInitialState),sCode=skuCode||lineItem?.sku_code||sku?.code;(0,react_1.useEffect)(()=>{if(accessToken!=null&&accessToken!==""){const config={accessToken,endpoint};(sCode!=null||skuId!=null)&&(0,AvailabilityReducer_1.getAvailability)({skuCode:sCode,skuId,config,dispatch})}return()=>{dispatch({type:"setAvailability",payload:{}})}},[accessToken,sCode,skuId]),(0,react_1.useEffect)(()=>{getQuantity!=null&&state?.quantity!=null&&getQuantity(state?.quantity)},[state.quantity]);const memoized=(0,react_1.useMemo)(()=>Object.assign(Object.assign({},state),{parent:!0}),[state]);return(0,jsx_runtime_1.jsx)(AvailabilityContext_1.default.Provider,{value:memoized,children})}exports.default=AvailabilityContainer;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import type { TimeFormat, ChildrenFunction } from '../../typings/index';
|
|
2
|
-
import type { DeliveryLeadTime } from '../../reducers/AvailabilityReducer';
|
|
3
|
-
import type { JSX } from "react";
|
|
4
|
-
interface AvailabilityTemplateChildrenProps extends Omit<Props, 'children'>, DeliveryLeadTime {
|
|
5
|
-
text: string;
|
|
6
|
-
quantity: number;
|
|
7
|
-
}
|
|
8
|
-
type FormatRules = {
|
|
9
|
-
/**
|
|
10
|
-
* Set time format for shipping method. When not set, ``delivery_lead_times`` will not be displayed.
|
|
11
|
-
* When set, `delivery_lead_times` for the first shipping method found in the inventory model, will be displayed in the format specified.
|
|
12
|
-
*/
|
|
13
|
-
timeFormat?: TimeFormat;
|
|
14
|
-
/**
|
|
15
|
-
* Show shipping method name. Requires `timeFormat` to be set.
|
|
16
|
-
*/
|
|
17
|
-
showShippingMethodName?: false;
|
|
18
|
-
/**
|
|
19
|
-
* Show shipping method price. Requires `timeFormat` to be set.
|
|
20
|
-
*/
|
|
21
|
-
showShippingMethodPrice?: false;
|
|
22
|
-
} | {
|
|
23
|
-
timeFormat: TimeFormat;
|
|
24
|
-
showShippingMethodName: true;
|
|
25
|
-
showShippingMethodPrice?: boolean;
|
|
26
|
-
} | {
|
|
27
|
-
timeFormat: TimeFormat;
|
|
28
|
-
showShippingMethodName?: boolean;
|
|
29
|
-
showShippingMethodPrice: true;
|
|
30
|
-
};
|
|
31
|
-
type Props = {
|
|
32
|
-
children?: ChildrenFunction<AvailabilityTemplateChildrenProps>;
|
|
33
|
-
labels?: {
|
|
34
|
-
available?: string;
|
|
35
|
-
outOfStock?: string;
|
|
36
|
-
negativeStock?: string;
|
|
37
|
-
};
|
|
38
|
-
} & Omit<JSX.IntrinsicElements['span'], 'children' | 'ref'> & FormatRules;
|
|
39
|
-
/**
|
|
40
|
-
* The AvailabilityTemplate component displays the availability of the SKU specified
|
|
41
|
-
* in the parent `<AvailabilityContainer>` component.
|
|
42
|
-
*
|
|
43
|
-
* It is possible to customize the text displayed in case of `available`, `outOfStock` or `negativeStock.
|
|
44
|
-
* It is also possible to show delivery lead time and either shipping method name and/or price.
|
|
45
|
-
* This information will be retrieve from the first shipping method found in the inventory model.
|
|
46
|
-
*
|
|
47
|
-
* <span type="Requirement" type="info">
|
|
48
|
-
* It must to be used inside the `<AvailabilityContainer>` component.
|
|
49
|
-
* </span>
|
|
50
|
-
*/
|
|
51
|
-
export declare function AvailabilityTemplate(props: Props): JSX.Element;
|
|
52
|
-
export default AvailabilityTemplate;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.AvailabilityTemplate=AvailabilityTemplate;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),AvailabilityContext_1=tslib_1.__importDefault(require("../../context/AvailabilityContext")),Parent_1=tslib_1.__importDefault(require("../utils/Parent")),useCustomContext_1=tslib_1.__importDefault(require("../../utils/hooks/useCustomContext"));function AvailabilityTemplate(props){var _a,_b,_c;const{timeFormat,showShippingMethodName,showShippingMethodPrice,children,labels}=props,p=tslib_1.__rest(props,["timeFormat","showShippingMethodName","showShippingMethodPrice","children","labels"]),{min,max,shipping_method:shippingMethod,quantity,skuCode}=(0,useCustomContext_1.default)({context:AvailabilityContext_1.default,contextComponentName:"AvailabilityContainer",currentComponentName:"AvailabilityTemplate",key:"parent"}),text=[],mn=min!=null&&timeFormat!=null?min?.[timeFormat]:"",mx=max!=null&&timeFormat!=null?max?.[timeFormat]:"",shippingMethodPrice=showShippingMethodPrice&&shippingMethod?.formatted_price_amount?`(${shippingMethod?.formatted_price_amount})`:"",name=showShippingMethodName&&shippingMethod?`with ${shippingMethod.name}`:"";quantity!=null&&(quantity>0?(text.push((_a=labels?.available)!==null&&_a!==void 0?_a:"Available"),mn&&mx&&timeFormat&&text.push(`in ${mn} - ${mx} ${timeFormat} ${name} ${shippingMethodPrice}`)):quantity===0?text.push((_b=labels?.outOfStock)!==null&&_b!==void 0?_b:"Out of stock"):quantity<0&&text.push((_c=labels?.negativeStock)!==null&&_c!==void 0?_c:"Out of stock"));const parentProps=Object.assign({min,max,shipping_method:shippingMethod,quantity,text:text.join(" ")},props);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)("span",Object.assign({"data-testid":skuCode?`availability-${skuCode}`:""},p,{children:text.join(" ")}))}exports.default=AvailabilityTemplate;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
export type DeliveryLeadTimeField = 'min_hours' | 'max_hours' | 'min_days' | 'max_days';
|
|
3
|
-
export type DeliveryLeadTimeComponentChildren = Omit<Props, 'children' | 'ref'>;
|
|
4
|
-
type Props = Partial<Omit<JSX.IntrinsicElements['span'], 'ref'>> & {
|
|
5
|
-
children?: (props: DeliveryLeadTimeComponentChildren) => JSX.Element;
|
|
6
|
-
type: DeliveryLeadTimeField;
|
|
7
|
-
text?: string;
|
|
8
|
-
};
|
|
9
|
-
export declare function DeliveryLeadTime(props: Props): JSX.Element;
|
|
10
|
-
export default DeliveryLeadTime;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.DeliveryLeadTime=DeliveryLeadTime;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),ShippingMethodChildrenContext_1=tslib_1.__importDefault(require("../../context/ShippingMethodChildrenContext")),Parent_1=tslib_1.__importDefault(require("../utils/Parent"));function DeliveryLeadTime(props){const{type}=props,p=tslib_1.__rest(props,["type"]),[text,setText]=(0,react_1.useState)(),{deliveryLeadTimeForShipment}=(0,react_1.useContext)(ShippingMethodChildrenContext_1.default);(0,react_1.useEffect)(()=>(deliveryLeadTimeForShipment?.[type]&&setText(deliveryLeadTimeForShipment[type]),()=>{setText("")}),[deliveryLeadTimeForShipment]);const parentProps=Object.assign({text},p);return props.children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children:props.children})):(0,jsx_runtime_1.jsx)("span",Object.assign({},p,{children:text}))}exports.default=DeliveryLeadTime;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import type { ConditionalElement } from '../../typings/index';
|
|
2
|
-
import { type TGenericChildrenProps, type TResources } from '../utils/GenericFieldComponent';
|
|
3
|
-
import type { JSX } from "react";
|
|
4
|
-
type SkuFieldChildrenProps = TGenericChildrenProps<TResources['Sku']>;
|
|
5
|
-
type TCondition = ConditionalElement<Exclude<TResources['Sku'], 'resource'>>;
|
|
6
|
-
type Props = {
|
|
7
|
-
children?: (props: SkuFieldChildrenProps) => JSX.Element;
|
|
8
|
-
} & TCondition;
|
|
9
|
-
/**
|
|
10
|
-
* The SkuField component displays any attribute of the `sku` specified in the parent `<SkusContainer>` component.
|
|
11
|
-
*
|
|
12
|
-
* It also accepts a `tagElement` props to enable specific tag-related props.
|
|
13
|
-
* For examples, when `tagElement` is set to `img` it will also accept props related to `<img>` tag such as `height` and `width`.
|
|
14
|
-
*
|
|
15
|
-
* <span title="Requirement" type="warning">
|
|
16
|
-
* It must to be used inside the `<SkusContainer>` component.
|
|
17
|
-
* </span>
|
|
18
|
-
*
|
|
19
|
-
* <span title="Fields" type="info">
|
|
20
|
-
* Check the `skus` resource from our [Core API documentation](https://docs.commercelayer.io/core/v/api-reference/skus/object)
|
|
21
|
-
* for more details about the available attributes to render.
|
|
22
|
-
* </span>
|
|
23
|
-
*/
|
|
24
|
-
export declare function SkuField<P extends Props>(props: P): JSX.Element;
|
|
25
|
-
export default SkuField;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SkuField=SkuField;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),SkuChildrenContext_1=tslib_1.__importDefault(require("../../context/SkuChildrenContext")),GenericFieldComponent_1=tslib_1.__importDefault(require("../utils/GenericFieldComponent"));function SkuField(props){const{attribute,tagElement="span",children}=props,p=tslib_1.__rest(props,["attribute","tagElement","children"]);return(0,jsx_runtime_1.jsx)(GenericFieldComponent_1.default,Object.assign({resource:"sku",attribute,tagElement,context:SkuChildrenContext_1.default},p,{children}))}exports.default=SkuField;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SkuList=SkuList;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),SkuListsContext_1=tslib_1.__importDefault(require("../../context/SkuListsContext"));function SkuList(props){const{id,children}=props,{listIds}=(0,react_1.useContext)(SkuListsContext_1.default);return(0,react_1.useEffect)(()=>{listIds&&!listIds.includes(id)&&listIds.push(id)},[]),(0,jsx_runtime_1.jsx)(jsx_runtime_1.Fragment,{children})}exports.default=SkuList;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SkuListsContainer=SkuListsContainer;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),SkuListsContext_1=tslib_1.__importDefault(require("../../context/SkuListsContext")),CommerceLayerContext_1=tslib_1.__importDefault(require("../../context/CommerceLayerContext")),SkuListsReducer_1=tslib_1.__importStar(require("../../reducers/SkuListsReducer"));function SkuListsContainer(props){const{children}=props,[state,dispatch]=(0,react_1.useReducer)(SkuListsReducer_1.default,SkuListsReducer_1.skuListsInitialState),config=(0,react_1.useContext)(CommerceLayerContext_1.default);return(0,react_1.useEffect)(()=>{state.listIds&&state.listIds.length>0&&config.accessToken&&(0,SkuListsReducer_1.getSkuList)({listIds:state.listIds,dispatch,config,state})},[config.accessToken]),(0,jsx_runtime_1.jsx)(SkuListsContext_1.default.Provider,{value:state,children})}exports.default=SkuListsContainer;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { type ReactNode, type JSX } from 'react';
|
|
2
|
-
interface Props {
|
|
3
|
-
children: ReactNode;
|
|
4
|
-
}
|
|
5
|
-
/**
|
|
6
|
-
* The `Skus` components loop through the list of `skus` found in `SkusContainer` context and render the children filled with the proper sku value.
|
|
7
|
-
* This means that the children will be rendered as many times as the number of skus found in the `skus` prop array
|
|
8
|
-
* and there is no need to manually loop through them from your consumer app.
|
|
9
|
-
*
|
|
10
|
-
* <span title='Requirements' type='warning'>
|
|
11
|
-
* Must be a child of the `<SkusContainer>` component.
|
|
12
|
-
* </span>
|
|
13
|
-
* <span title='Children' type='info'>
|
|
14
|
-
* `<SkuField>`, `<AvailabilityContainer>`
|
|
15
|
-
* </span>
|
|
16
|
-
*/
|
|
17
|
-
export declare function Skus<P extends Props>({ children }: P): JSX.Element;
|
|
18
|
-
export default Skus;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.Skus=Skus;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),SkuChildrenContext_1=tslib_1.__importDefault(require("../../context/SkuChildrenContext")),SkuContext_1=tslib_1.__importDefault(require("../../context/SkuContext")),react_1=require("react");function Skus({children}){const{skus}=(0,react_1.useContext)(SkuContext_1.default),components=skus?.map((sku,key)=>{const value={sku};return(0,jsx_runtime_1.jsx)(SkuChildrenContext_1.default.Provider,{value,children},key)});return(0,jsx_runtime_1.jsx)(jsx_runtime_1.Fragment,{children:components})}exports.default=Skus;
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import type { QueryParamsList } from '@commercelayer/sdk';
|
|
2
|
-
import { type ReactNode, type JSX } from 'react';
|
|
3
|
-
interface Props {
|
|
4
|
-
/**
|
|
5
|
-
* An array of skus to display.
|
|
6
|
-
*/
|
|
7
|
-
skus: string[];
|
|
8
|
-
/**
|
|
9
|
-
* Accept a React node and [Skus](./Skus.d.ts) component as children to display above the skus.
|
|
10
|
-
*/
|
|
11
|
-
children: ReactNode;
|
|
12
|
-
/**
|
|
13
|
-
* An object params to query the skus resource
|
|
14
|
-
*/
|
|
15
|
-
queryParams?: QueryParamsList;
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* Main container for the SKUs components.
|
|
19
|
-
* It stores - in its context - the details for each `sku` defined in the `skus` prop array.
|
|
20
|
-
*
|
|
21
|
-
* It also accept a `queryParams` prop to refine pagination, sorting, filtering and includes for the fetch request.
|
|
22
|
-
*
|
|
23
|
-
* <span title='Requirements' type='warning'>
|
|
24
|
-
* Must be a child of the `<CommerceLayer>` component.
|
|
25
|
-
* </span>
|
|
26
|
-
* <span title='Children' type='info'>
|
|
27
|
-
* `<Skus>`
|
|
28
|
-
* </span>
|
|
29
|
-
*/
|
|
30
|
-
export declare function SkusContainer<P extends Props>(props: P): JSX.Element;
|
|
31
|
-
export default SkusContainer;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SkusContainer=SkusContainer;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),CommerceLayerContext_1=tslib_1.__importDefault(require("../../context/CommerceLayerContext")),SkuContext_1=tslib_1.__importDefault(require("../../context/SkuContext")),SkuReducer_1=tslib_1.__importStar(require("../../reducers/SkuReducer")),react_1=require("react");function SkusContainer(props){const{skus,children,queryParams}=props,[state,dispatch]=(0,react_1.useReducer)(SkuReducer_1.default,SkuReducer_1.skuInitialState),config=(0,react_1.useContext)(CommerceLayerContext_1.default),loadSkus=()=>tslib_1.__awaiter(this,void 0,void 0,function*(){yield(0,SkuReducer_1.getSku)({config,dispatch,skus,queryParams})});(0,react_1.useEffect)(()=>(config.accessToken&&state?.skus&&state?.skus.length===0&&loadSkus(),()=>{dispatch({type:"setLoading",payload:{loading:!0}})}),[config,skus]);const contextValue=(0,react_1.useMemo)(()=>state,[state]);return(0,jsx_runtime_1.jsx)(SkuContext_1.default.Provider,{value:contextValue,children})}exports.default=SkusContainer;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.StockTransfer=StockTransfer;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react"),ShipmentChildrenContext_1=tslib_1.__importDefault(require("../../context/ShipmentChildrenContext")),StockTransferChildrenContext_1=tslib_1.__importDefault(require("../../context/StockTransferChildrenContext"));function StockTransfer(props){const{children}=props,{stockTransfers,lineItems}=(0,react_1.useContext)(ShipmentChildrenContext_1.default),components=stockTransfers?.filter(st=>!!lineItems?.find(l=>l?.sku_code!==st?.sku_code)).map((stockTransfer,k)=>{const stockTransferProps={stockTransfer:stockTransfer.type==="line_items"?stockTransfer:stockTransfer?.line_item};return(0,jsx_runtime_1.jsx)(StockTransferChildrenContext_1.default.Provider,{value:stockTransferProps,children},k)});return(0,jsx_runtime_1.jsx)(jsx_runtime_1.Fragment,{children:components})}exports.default=StockTransfer;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { ConditionalElement } from '../../typings/index';
|
|
2
|
-
import { type TGenericChildrenProps, type TResources } from '../utils/GenericFieldComponent';
|
|
3
|
-
import type { JSX } from "react";
|
|
4
|
-
type StockTransferFieldChildrenProps = TGenericChildrenProps<TResources['StockTransfer']>;
|
|
5
|
-
type TCondition = ConditionalElement<Exclude<TResources['StockTransfer'], 'resource'>>;
|
|
6
|
-
type Props = {
|
|
7
|
-
children?: (props: StockTransferFieldChildrenProps) => JSX.Element;
|
|
8
|
-
} & TCondition;
|
|
9
|
-
export declare function StockTransferField<P extends Props>(props: P): JSX.Element;
|
|
10
|
-
export default StockTransferField;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.StockTransferField=StockTransferField;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),StockTransferChildrenContext_1=tslib_1.__importDefault(require("../../context/StockTransferChildrenContext")),GenericFieldComponent_1=tslib_1.__importDefault(require("../utils/GenericFieldComponent"));function StockTransferField(props){const{attribute,tagElement="span",children}=props,p=tslib_1.__rest(props,["attribute","tagElement","children"]);return(0,jsx_runtime_1.jsx)(GenericFieldComponent_1.default,Object.assign({resource:"stockTransfer",attribute,tagElement,context:StockTransferChildrenContext_1.default},p,{children}))}exports.default=StockTransferField;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
import type { Address } from '@commercelayer/sdk';
|
|
3
|
-
import AddressChildrenContext from '../../context/AddressChildrenContext';
|
|
4
|
-
import type { ChildrenFunction } from '../../typings/index';
|
|
5
|
-
export interface TAddressCards extends Pick<Props, 'customerAddresses' | 'className'> {
|
|
6
|
-
AddressProvider: typeof AddressChildrenContext.Provider;
|
|
7
|
-
}
|
|
8
|
-
export interface CustomerAddress extends Address {
|
|
9
|
-
onClick: () => void;
|
|
10
|
-
handleSelect?: () => void;
|
|
11
|
-
}
|
|
12
|
-
export type AddressCardsTemplateChildren = ChildrenFunction<TAddressCards>;
|
|
13
|
-
export type HandleSelect = (k: number, addressId: string, customerAddressId: string, disabled: boolean, address: Address) => Promise<void>;
|
|
14
|
-
interface Props {
|
|
15
|
-
customerAddresses: CustomerAddress[];
|
|
16
|
-
countryLock?: string | null;
|
|
17
|
-
children: AddressCardsTemplateChildren;
|
|
18
|
-
selectedClassName?: string;
|
|
19
|
-
disabledClassName?: string;
|
|
20
|
-
deselect?: boolean;
|
|
21
|
-
selected?: number | null;
|
|
22
|
-
className?: string;
|
|
23
|
-
handleSelect: HandleSelect;
|
|
24
|
-
}
|
|
25
|
-
export default function AddressCardsTemplate({ customerAddresses, children, deselect, countryLock, selected, selectedClassName, className, disabledClassName, handleSelect }: Props): JSX.Element;
|
|
26
|
-
export {};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=AddressCardsTemplate;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),Parent_1=tslib_1.__importDefault(require("../utils/Parent")),react_1=require("react"),AddressChildrenContext_1=tslib_1.__importDefault(require("../../context/AddressChildrenContext")),ShippingAddressContext_1=tslib_1.__importDefault(require("../../context/ShippingAddressContext"));function AddressCardsTemplate({customerAddresses,children,deselect,countryLock,selected,selectedClassName,className,disabledClassName,handleSelect}){const{setShippingAddress}=(0,react_1.useContext)(ShippingAddressContext_1.default),value={customerAddresses:customerAddresses.map((address,k)=>{const attributes=address,disabled=setShippingAddress&&countryLock&&countryLock!==address.country_code||!1,selectedClass=deselect?"":selectedClassName,addressSelectedClass=selected===k?`${className??""} ${selectedClass??""}`:className,finalClassName=disabled?`${className??""} ${disabledClassName??""}`:addressSelectedClass,customerAddressId=address?.reference||"",onClick=()=>tslib_1.__awaiter(this,void 0,void 0,function*(){yield handleSelect(k,address.id,customerAddressId,disabled,address)});return Object.assign(Object.assign({},attributes),{className:finalClassName,onClick})}),AddressProvider:AddressChildrenContext_1.default.Provider};return(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},value,{children}))}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { type FunctionComponent, type JSX } from 'react';
|
|
2
|
-
type BaseFieldChildren = Omit<BaseFieldProps, 'children'>;
|
|
3
|
-
export interface BaseFieldProps extends Omit<JSX.IntrinsicElements['span'], 'children' | 'ref'> {
|
|
4
|
-
attribute: 'number' | 'id';
|
|
5
|
-
children?: (props: BaseFieldChildren) => JSX.Element;
|
|
6
|
-
}
|
|
7
|
-
declare const BaseField: FunctionComponent<BaseFieldProps>;
|
|
8
|
-
export default BaseField;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),OrderContext_1=tslib_1.__importDefault(require("../../context/OrderContext")),react_1=require("react"),Parent_1=tslib_1.__importDefault(require("./Parent")),BaseField=_a=>{var{children,attribute}=_a,p=tslib_1.__rest(_a,["children","attribute"]);const{order}=(0,react_1.useContext)(OrderContext_1.default),[field,setField]=(0,react_1.useState)("");(0,react_1.useEffect)(()=>(order&&attribute in order&&setField(order[attribute]),()=>{setField("")}),[order]);const parentProps=Object.assign({attribute:field},p);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)("span",Object.assign({},p,{children:field}))};exports.default=BaseField;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import React, { type JSX } from 'react';
|
|
2
|
-
import type { BaseInputComponentProps } from '../../typings/index';
|
|
3
|
-
export type BaseInputProps = BaseInputComponentProps & Omit<JSX.IntrinsicElements['input'], 'children' | 'pattern'> & Omit<JSX.IntrinsicElements['textarea'], 'children' | 'pattern'>;
|
|
4
|
-
declare const _default: React.ForwardRefExoticComponent<Omit<BaseInputProps, "ref"> & React.RefAttributes<any>>;
|
|
5
|
-
export default _default;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=tslib_1.__importDefault(require("react")),Parent_1=tslib_1.__importDefault(require("./Parent")),BaseInput=(props,ref)=>{const{children}=props,p=tslib_1.__rest(props,["children"]),input=props.type==="textarea"?(0,jsx_runtime_1.jsx)("textarea",Object.assign({ref},p)):(0,jsx_runtime_1.jsx)("input",Object.assign({ref},p));return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({parentRef:ref},p,{children})):input};exports.default=react_1.default.forwardRef(BaseInput);
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { type JSX } from 'react';
|
|
2
|
-
import type { PropsType } from '../../utils/PropsType';
|
|
3
|
-
import type { baseOrderPricePropTypes } from '../../typings/index';
|
|
4
|
-
export type BaseOrderPriceProps = PropsType<typeof baseOrderPricePropTypes, unknown> & Omit<JSX.IntrinsicElements['span'], 'children' | 'ref'>;
|
|
5
|
-
export declare function BaseOrderPrice(props: BaseOrderPriceProps): JSX.Element;
|
|
6
|
-
export default BaseOrderPrice;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.BaseOrderPrice=BaseOrderPrice;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),OrderContext_1=tslib_1.__importDefault(require("../../context/OrderContext")),getAmount_1=tslib_1.__importDefault(require("../../utils/getAmount")),Parent_1=tslib_1.__importDefault(require("./Parent")),react_1=require("react"),isEmpty_1=tslib_1.__importDefault(require("lodash/isEmpty"));function BaseOrderPrice(props){const{format="formatted",base,type,children}=props,p=tslib_1.__rest(props,["format","base","type","children"]),{order}=(0,react_1.useContext)(OrderContext_1.default),[price,setPrice]=(0,react_1.useState)(""),[cents,setCents]=(0,react_1.useState)(0);(0,react_1.useEffect)(()=>{const p2=(0,getAmount_1.default)({base,type,format,obj:order||{}}),c=(0,getAmount_1.default)({base,type,format:"cents",obj:order||{}});return setPrice(p2),setCents(c),()=>{(0,isEmpty_1.default)(order)&&setPrice("")}},[order]);const parentProps=Object.assign({priceCents:cents,price},p);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)("span",Object.assign({},p,{children:price}))}exports.default=BaseOrderPrice;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import type { BaseSelectComponentProps } from '../../typings/index';
|
|
3
|
-
export type BaseSelectProps = BaseSelectComponentProps;
|
|
4
|
-
declare const _default: React.ForwardRefExoticComponent<BaseSelectComponentProps & React.RefAttributes<any>>;
|
|
5
|
-
export default _default;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),react_1=tslib_1.__importDefault(require("react")),Parent_1=tslib_1.__importDefault(require("./Parent")),BaseSelect=(props,ref)=>{const{options=[],children,placeholder={label:"Select an option",value:""},value=""}=props,p=tslib_1.__rest(props,["options","children","placeholder","value"]);placeholder!=null&&(options.some(option=>option.value===placeholder.value)||options.unshift(placeholder));const Options=options.map((o,k)=>{const{label}=o,option=tslib_1.__rest(o,["label"]);return(0,jsx_runtime_1.jsx)("option",Object.assign({},option,{children:label}),k)}),parentProps=Object.assign({options,ref},p);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)("select",Object.assign({ref,defaultValue:value},p,{children:Options}))};exports.default=react_1.default.forwardRef(BaseSelect);
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { Component, type ErrorInfo, type JSX } from 'react';
|
|
2
|
-
interface Props {
|
|
3
|
-
children: JSX.Element;
|
|
4
|
-
}
|
|
5
|
-
interface State {
|
|
6
|
-
hasError: boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare class ErrorBoundary extends Component<Props, State> {
|
|
9
|
-
state: State;
|
|
10
|
-
static getDerivedStateFromError(): State;
|
|
11
|
-
componentDidCatch(error: Error, errorInfo: ErrorInfo): void;
|
|
12
|
-
render(): JSX.Element;
|
|
13
|
-
}
|
|
14
|
-
export default ErrorBoundary;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ErrorBoundary=void 0;const jsx_runtime_1=require("react/jsx-runtime"),react_1=require("react");class ErrorBoundary extends react_1.Component{constructor(){super(...arguments),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(error,errorInfo){if(process.env.NODE_ENV!=="test")console.error("Uncaught error:",error,errorInfo);else throw error}render(){return this.state.hasError?(0,jsx_runtime_1.jsx)("h1",{children:"Sorry.. there was an error, check the console."}):this.props.children}}exports.ErrorBoundary=ErrorBoundary,exports.default=ErrorBoundary;
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import type { InitialSkuContext } from '../../context/SkuChildrenContext';
|
|
2
|
-
import type { InitialStockTransferContext } from '../../context/StockTransferChildrenContext';
|
|
3
|
-
import type { Customer, LineItem, Sku, Parcel, ParcelLineItem } from '@commercelayer/sdk';
|
|
4
|
-
import type { InitialLineItemChildrenContext } from '../../context/LineItemChildrenContext';
|
|
5
|
-
import { type Context, type JSX } from 'react';
|
|
6
|
-
import type { InitialCustomerContext } from '../../context/CustomerContext';
|
|
7
|
-
import type { InitialParcelContext } from '../../context/ParcelChildrenContext';
|
|
8
|
-
import type { InitialParcelLineItemContext } from '../../context/ParcelLineItemChildrenContext';
|
|
9
|
-
export interface TResources {
|
|
10
|
-
StockTransfer: LineItem & {
|
|
11
|
-
resource: 'stockTransfer';
|
|
12
|
-
};
|
|
13
|
-
Sku: Sku & {
|
|
14
|
-
resource: 'sku';
|
|
15
|
-
};
|
|
16
|
-
LineItem: LineItem & {
|
|
17
|
-
resource: 'lineItem';
|
|
18
|
-
};
|
|
19
|
-
Customer: Customer & {
|
|
20
|
-
resource: 'customers';
|
|
21
|
-
};
|
|
22
|
-
Parcel: Parcel & {
|
|
23
|
-
resource: 'parcel';
|
|
24
|
-
};
|
|
25
|
-
ParcelLineItem: Pick<ParcelLineItem, 'quantity' | 'sku_code' | 'name' | 'image_url'> & {
|
|
26
|
-
resource: 'parcelLineItem';
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
export type TResourceKey = {
|
|
30
|
-
[K in keyof TResources]: K;
|
|
31
|
-
};
|
|
32
|
-
export type TGenericChildrenProps<E extends TResources[keyof TResources]> = Omit<Props<E>, 'children' | 'attribute' | 'context' | 'tagElement'> & {
|
|
33
|
-
attributeValue: E[keyof E];
|
|
34
|
-
};
|
|
35
|
-
interface ResourceContext {
|
|
36
|
-
stockTransfer: InitialStockTransferContext;
|
|
37
|
-
sku: InitialSkuContext;
|
|
38
|
-
lineItem: InitialLineItemChildrenContext;
|
|
39
|
-
customers: InitialCustomerContext;
|
|
40
|
-
parcel: InitialParcelContext;
|
|
41
|
-
parcelLineItem: InitialParcelLineItemContext;
|
|
42
|
-
}
|
|
43
|
-
type GenericContext<K extends keyof ResourceContext> = Context<ResourceContext[K]>;
|
|
44
|
-
interface Props<E extends TResources[keyof TResources]> {
|
|
45
|
-
children?: (props: TGenericChildrenProps<E>) => JSX.Element;
|
|
46
|
-
resource: E['resource'];
|
|
47
|
-
/**
|
|
48
|
-
* Resource attribute to display.
|
|
49
|
-
*/
|
|
50
|
-
attribute: keyof E;
|
|
51
|
-
/**
|
|
52
|
-
* Html tag to render. When tag is `img` the value will be used to fill the `src` attribute.
|
|
53
|
-
*/
|
|
54
|
-
tagElement: keyof JSX.IntrinsicElements;
|
|
55
|
-
context: GenericContext<E['resource']>;
|
|
56
|
-
}
|
|
57
|
-
export default function GenericFieldComponent<R extends keyof TResources>(props: Props<TResources[R]>): JSX.Element;
|
|
58
|
-
export {};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=GenericFieldComponent;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime"),Parent_1=tslib_1.__importDefault(require("./Parent")),react_1=require("react"),placeholderImages_1=require("../../utils/placeholderImages");function GenericFieldComponent(props){const{children,tagElement,attribute,context,resource}=props,p=tslib_1.__rest(props,["children","tagElement","attribute","context","resource"]),resourceContext=(0,react_1.useContext)(context);let attributeValue="";const keysContext=Object.keys(resourceContext).filter(key=>key===resource);if(keysContext.length===1){const[keyResource]=keysContext;keyResource&&attribute&&(attributeValue=resourceContext[keyResource][attribute])}const Tag=tagElement||"span";if(Tag==="img"&&!children){const src=attributeValue||placeholderImages_1.defaultImgUrl,name="";return(0,jsx_runtime_1.jsx)("img",Object.assign({alt:name,src},p))}const parentProps=Object.assign({attributeValue,tagElement},p);return children?(0,jsx_runtime_1.jsx)(Parent_1.default,Object.assign({},parentProps,{children})):(0,jsx_runtime_1.jsx)(Tag,Object.assign({"data-testid":attributeValue},p,{children:attributeValue}),attributeValue)}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { Component, ForwardedRef, JSX } from 'react';
|
|
2
|
-
export interface ParentProps {
|
|
3
|
-
parentRef?: ForwardedRef<any>;
|
|
4
|
-
children?: typeof Component | ((P: any) => JSX.Element | null);
|
|
5
|
-
}
|
|
6
|
-
export default function Parent({ children, ...p }: ParentProps): JSX.Element | null;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=Parent;const tslib_1=require("tslib"),jsx_runtime_1=require("react/jsx-runtime");function Parent(_a){var{children}=_a,p=tslib_1.__rest(_a,["children"]);const Child=children;return Child!==void 0?(0,jsx_runtime_1.jsx)(Child,Object.assign({},p)):null}
|