@lookiero/checkout 9.9.0-beta.2 → 9.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/dist/fake-dependencies/@lookiero/payments-front/index.d.ts +6 -8
  2. package/dist/fake-dependencies/@lookiero/payments-front/index.js +4 -7
  3. package/dist/index.js +2 -2
  4. package/dist/src/ExpoRoot.js +13 -17
  5. package/dist/src/infrastructure/ui/Root.d.ts +2 -0
  6. package/dist/src/infrastructure/ui/Root.js +4 -2
  7. package/dist/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.style.js +3 -2
  8. package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.js +1 -1
  9. package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.d.ts +0 -1
  10. package/dist/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.js +0 -1
  11. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.js +1 -1
  12. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.d.ts +0 -1
  13. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.js +0 -1
  14. package/dist/src/infrastructure/ui/hooks/usePaymentInstrumentEvents.d.ts +2 -3
  15. package/dist/src/infrastructure/ui/hooks/usePaymentInstrumentEvents.js +26 -17
  16. package/dist/src/infrastructure/ui/hooks/useQueryBus.d.ts +9 -0
  17. package/dist/src/infrastructure/ui/hooks/useQueryBus.js +10 -0
  18. package/dist/src/infrastructure/ui/hooks/useSubmitCheckout.d.ts +1 -1
  19. package/dist/src/infrastructure/ui/hooks/useSubmitCheckout.js +55 -22
  20. package/dist/src/infrastructure/ui/i18n/i18n.d.ts +0 -1
  21. package/dist/src/infrastructure/ui/i18n/i18n.js +0 -1
  22. package/dist/src/infrastructure/ui/views/App.js +6 -5
  23. package/dist/src/infrastructure/ui/views/checkout/Checkout.js +2 -5
  24. package/dist/src/infrastructure/ui/views/checkout/Checkout.style.d.ts +0 -3
  25. package/dist/src/infrastructure/ui/views/checkout/Checkout.style.js +0 -3
  26. package/dist/src/infrastructure/ui/views/checkout/components/checkoutPaymentModal/CheckoutPaymentModal.js +2 -2
  27. package/dist/src/infrastructure/ui/views/checkout/components/paymentInstrument/PaymentInstrument.js +7 -7
  28. package/dist/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.d.ts +1 -0
  29. package/dist/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.js +2 -1
  30. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +1 -0
  31. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.js +2 -1
  32. package/dist/src/projection/customer/customer.d.ts +0 -2
  33. package/dist/src/version.d.ts +1 -1
  34. package/dist/src/version.js +1 -1
  35. package/fake-dependencies/@lookiero/payments-front/index.tsx +9 -32
  36. package/index.ts +2 -2
  37. package/jest.config.js +2 -2
  38. package/package.json +7 -7
  39. package/src/ExpoRoot.tsx +32 -37
  40. package/src/infrastructure/ui/Root.tsx +30 -17
  41. package/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/FiveItemsDiscountBanner.style.ts +3 -2
  42. package/src/infrastructure/ui/components/atoms/fiveItemsDiscountBanner/__snapshots__/FiveItemsDiscountBanner.test.tsx.snap +1 -1
  43. package/src/infrastructure/ui/components/atoms/price/__snapshots__/Price.test.tsx.snap +3 -3
  44. package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.style.ts +0 -1
  45. package/src/infrastructure/ui/components/organisms/checkoutQuestions/components/textareaCheckoutQuestionItem/TextareaCheckoutQuestionItem.tsx +1 -0
  46. package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.style.ts +0 -1
  47. package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.tsx +1 -0
  48. package/src/infrastructure/ui/components/templates/header/checkoutHeader/__snapshots__/CheckoutHeader.test.tsx.snap +1 -1
  49. package/src/infrastructure/ui/components/templates/header/itemDetailHeader/__snapshots__/ItemDetailHeader.test.tsx.snap +1 -1
  50. package/src/infrastructure/ui/components/templates/header/itemHeader/__snapshots__/ItemHeader.test.tsx.snap +1 -1
  51. package/src/infrastructure/ui/hooks/usePaymentInstrumentEvents.ts +60 -18
  52. package/src/infrastructure/ui/hooks/useQueryBus.test.tsx +23 -0
  53. package/src/infrastructure/ui/hooks/useQueryBus.tsx +27 -0
  54. package/src/infrastructure/ui/hooks/useSubmitCheckout.test.ts +58 -0
  55. package/src/infrastructure/ui/hooks/useSubmitCheckout.ts +77 -33
  56. package/src/infrastructure/ui/i18n/i18n.ts +0 -1
  57. package/src/infrastructure/ui/views/App.tsx +13 -5
  58. package/src/infrastructure/ui/views/checkout/Checkout.style.ts +0 -3
  59. package/src/infrastructure/ui/views/checkout/Checkout.tsx +3 -12
  60. package/src/infrastructure/ui/views/checkout/components/checkoutPaymentModal/CheckoutPaymentModal.tsx +2 -2
  61. package/src/infrastructure/ui/views/checkout/components/deliveryBanner/__snapshots__/DeliveryBanner.test.tsx.snap +1 -1
  62. package/src/infrastructure/ui/views/checkout/components/paymentInstrument/PaymentInstrument.tsx +8 -8
  63. package/src/infrastructure/ui/views/item/components/banner/__snapshots__/CustomerDecissionBanner.test.tsx.snap +3 -3
  64. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/__snapshots__/GetOutOfCheckoutModal.test.tsx.snap +3 -3
  65. package/src/infrastructure/ui/views/item/components/itemActions/__snapshots__/ItemActions.test.tsx.snap +5 -5
  66. package/src/infrastructure/ui/views/item/components/productVariantDescription/ProductVariantDescription.style.ts +2 -1
  67. package/src/infrastructure/ui/views/item/components/productVariantDescription/__snapshots__/ProductVariantDescription.test.tsx.snap +10 -8
  68. package/src/infrastructure/ui/views/item/components/productVariantSlider/__snapshots__/ProductVariantSlider.test.tsx.snap +30 -30
  69. package/src/infrastructure/ui/views/item/components/selectModal/__snapshots__/SelecModal.test.tsx.snap +1 -1
  70. package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/__snapshots__/SizeWithoutStockModal.test.tsx.snap +2 -2
  71. package/src/infrastructure/ui/views/item/views/productVariant/__snapshots__/ProductVariant.test.tsx.snap +105 -102
  72. package/src/infrastructure/ui/views/return/components/price/__snapshots__/Price.test.tsx.snap +3 -3
  73. package/src/infrastructure/ui/views/return/components/productVariantPreview/__snapshots__/ProductVariantPreview.test.tsx.snap +1 -1
  74. package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.ts +2 -1
  75. package/src/infrastructure/ui/views/shared/components/productVariant/__snapshots__/ProductVariant.test.tsx.snap +30 -30
  76. package/src/infrastructure/ui/views/summary/components/collapsiblePricing/__snapshots__/CollapsiblePricing.test.tsx.snap +4 -4
  77. package/src/infrastructure/ui/views/summaryTabs/components/checkoutItemsTabs/__snapshots__/CheckoutItemsTabs.test.tsx.snap +62 -62
  78. package/src/projection/customer/customer.ts +0 -2
  79. package/dist/pact.config.d.ts +0 -21
  80. package/dist/pact.config.js +0 -16
  81. package/dist/public/public/assets/adaptive-icon.png +0 -0
  82. package/dist/public/public/assets/favicon.png +0 -0
  83. package/dist/public/public/assets/icon.png +0 -0
  84. package/dist/public/public/assets/splash.png +0 -0
  85. package/dist/public/public/images/not-found.png +0 -0
  86. package/dist/src/infrastructure/projection/bookedProductsVariants/httpBookedProductsVariantsForCheckoutItemView.pact.d.ts +0 -1
  87. package/dist/src/infrastructure/projection/bookedProductsVariants/httpBookedProductsVariantsForCheckoutItemView.pact.js +0 -55
  88. package/dist/src/infrastructure/projection/checkout/httpCheckoutByIdView.pact.d.ts +0 -1
  89. package/dist/src/infrastructure/projection/checkout/httpCheckoutByIdView.pact.js +0 -116
  90. package/dist/src/infrastructure/projection/checkout/httpFirstAvailableCheckoutByCustomerIdView.pact.d.ts +0 -1
  91. package/dist/src/infrastructure/projection/checkout/httpFirstAvailableCheckoutByCustomerIdView.pact.js +0 -56
  92. package/dist/src/infrastructure/projection/checkout/httpFiveItemsDiscountByCustomerIdView.pact.d.ts +0 -1
  93. package/dist/src/infrastructure/projection/checkout/httpFiveItemsDiscountByCustomerIdView.pact.js +0 -51
  94. package/dist/src/infrastructure/projection/checkout/httpIsCheckoutEnabledByCustomerIdView.pact.d.ts +0 -1
  95. package/dist/src/infrastructure/projection/checkout/httpIsCheckoutEnabledByCustomerIdView.pact.js +0 -51
  96. package/dist/src/infrastructure/projection/checkout/httpIsSizeChangeEnabledByCheckoutIdView.pact.d.ts +0 -1
  97. package/dist/src/infrastructure/projection/checkout/httpIsSizeChangeEnabledByCheckoutIdView.pact.js +0 -51
  98. package/dist/src/infrastructure/projection/checkout/react/useViewIsCheckoutAccessibleByCustomerId.d.ts +0 -13
  99. package/dist/src/infrastructure/projection/checkout/react/useViewIsCheckoutAccessibleByCustomerId.js +0 -19
  100. package/dist/src/infrastructure/projection/checkoutBooking/httpCheckoutBookingByIdView.pact.d.ts +0 -1
  101. package/dist/src/infrastructure/projection/checkoutBooking/httpCheckoutBookingByIdView.pact.js +0 -56
  102. package/dist/src/infrastructure/projection/checkoutItem/httpCheckoutItemByIdView.pact.d.ts +0 -1
  103. package/dist/src/infrastructure/projection/checkoutItem/httpCheckoutItemByIdView.pact.js +0 -57
  104. package/dist/src/infrastructure/projection/checkoutQuestion/httpCheckoutQuestionsByCheckoutIdView.pact.d.ts +0 -1
  105. package/dist/src/infrastructure/projection/checkoutQuestion/httpCheckoutQuestionsByCheckoutIdView.pact.js +0 -55
  106. package/dist/src/infrastructure/projection/payment/httpPaymentFlowPayloadByCheckoutIdView.pact.d.ts +0 -1
  107. package/dist/src/infrastructure/projection/payment/httpPaymentFlowPayloadByCheckoutIdView.pact.js +0 -120
  108. package/dist/src/infrastructure/projection/pricing/httpPricingByCheckoutIdView.pact.d.ts +0 -1
  109. package/dist/src/infrastructure/projection/pricing/httpPricingByCheckoutIdView.pact.js +0 -55
  110. package/dist/src/infrastructure/projection/returnQuestion/httpReturnQuestionsByCheckoutItemIdView.pact.d.ts +0 -1
  111. package/dist/src/infrastructure/projection/returnQuestion/httpReturnQuestionsByCheckoutItemIdView.pact.js +0 -55
  112. package/dist/src/infrastructure/ui/components/layouts/layout/Layout.d.ts +0 -22
  113. package/dist/src/infrastructure/ui/components/layouts/layout/Layout.js +0 -1
  114. package/dist/src/infrastructure/ui/components/layouts/layout/components/footer/Footer.d.ts +0 -7
  115. package/dist/src/infrastructure/ui/components/layouts/layout/components/footer/Footer.js +0 -5
  116. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.d.ts +0 -7
  117. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.js +0 -6
  118. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.style.d.ts +0 -4
  119. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.style.js +0 -20
  120. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.d.ts +0 -4
  121. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.js +0 -43
  122. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.style.d.ts +0 -12
  123. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.style.js +0 -14
  124. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.d.ts +0 -7
  125. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.js +0 -21
  126. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.style.d.ts +0 -8
  127. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.style.js +0 -12
  128. package/dist/src/infrastructure/ui/hooks/useNewFeedbackExperiment.d.ts +0 -12
  129. package/dist/src/infrastructure/ui/hooks/useNewFeedbackExperiment.js +0 -64
  130. package/dist/src/infrastructure/ui/i18n/fetchTranslations.d.ts +0 -10
  131. package/dist/src/infrastructure/ui/i18n/fetchTranslations.js +0 -17
  132. package/dist/src/infrastructure/ui/i18n/translationEndpoint.d.ts +0 -20
  133. package/dist/src/infrastructure/ui/i18n/translationEndpoint.js +0 -27
  134. package/dist/src/infrastructure/ui/routing/CheckoutAccessibilityMiddleware.d.ts +0 -10
  135. package/dist/src/infrastructure/ui/routing/CheckoutAccessibilityMiddleware.js +0 -27
  136. package/dist/src/infrastructure/ui/views/App.style.d.ts +0 -6
  137. package/dist/src/infrastructure/ui/views/App.style.js +0 -8
  138. package/dist/src/infrastructure/ui/views/feedback/components/checkoutQuestionsForm/CheckoutQuestionsForm.style.d.ts +0 -7
  139. package/dist/src/infrastructure/ui/views/feedback/components/checkoutQuestionsForm/CheckoutQuestionsForm.style.js +0 -11
  140. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.d.ts +0 -12
  141. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.js +0 -64
  142. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +0 -12
  143. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.style.js +0 -16
  144. package/dist/src/infrastructure/ui/views/return/Return.style.d.ts +0 -40
  145. package/dist/src/infrastructure/ui/views/return/Return.style.js +0 -44
  146. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.d.ts +0 -14
  147. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.js +0 -28
  148. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.style.d.ts +0 -7
  149. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.style.js +0 -11
  150. package/dist/src/projection/checkout/viewIsCheckoutAccessibleByCustomerId.d.ts +0 -26
  151. package/dist/src/projection/checkout/viewIsCheckoutAccessibleByCustomerId.js +0 -21
  152. package/dist/src/projection/shared/country.d.ts +0 -14
  153. package/dist/src/projection/shared/country.js +0 -15
  154. package/dist/src/projection/shared/customer.d.ts +0 -9
  155. package/dist/src/projection/shared/customer.js +0 -1
  156. package/dist/src/projection/shared/locale.d.ts +0 -12
  157. package/dist/src/projection/shared/locale.js +0 -13
  158. package/dist/src/projection/shared/order.d.ts +0 -6
  159. package/dist/src/projection/shared/order.js +0 -1
  160. package/dist/src/projection/shared/price.d.ts +0 -11
  161. package/dist/src/projection/shared/price.js +0 -1
  162. package/dist/src/projection/shared/size.d.ts +0 -21
  163. package/dist/src/projection/shared/size.js +0 -4
  164. package/dist/src/projection/shared/subscription.d.ts +0 -2
  165. package/dist/src/projection/shared/subscription.js +0 -1
  166. package/dist/src/shared/ui/components/atoms/aspectRatioView/AspectRatioView.d.ts +0 -15
  167. package/dist/src/shared/ui/components/atoms/aspectRatioView/AspectRatioView.js +0 -16
  168. package/dist/src/shared/ui/components/atoms/error/Error.d.ts +0 -11
  169. package/dist/src/shared/ui/components/atoms/error/Error.js +0 -6
  170. package/dist/src/shared/ui/components/atoms/field/Field.d.ts +0 -14
  171. package/dist/src/shared/ui/components/atoms/field/Field.js +0 -29
  172. package/dist/src/shared/ui/components/atoms/field/Field.style.d.ts +0 -16
  173. package/dist/src/shared/ui/components/atoms/field/Field.style.js +0 -19
  174. package/dist/src/shared/ui/components/molecules/inputField/InputField.d.ts +0 -24
  175. package/dist/src/shared/ui/components/molecules/inputField/InputField.js +0 -28
  176. package/dist/src/shared/ui/components/molecules/inputField/InputField.style.d.ts +0 -29
  177. package/dist/src/shared/ui/components/molecules/inputField/InputField.style.js +0 -37
@@ -6,9 +6,11 @@ import { PaymentFlowRef } from "@lookiero/payments-front";
6
6
  import { ChargeStatus } from "@lookiero/payments-front/build/infrastructure/CheckoutAPI";
7
7
  import { Logger } from "@lookiero/sty-psp-logging";
8
8
  import { NotificationLevel, useCreateToastNotification } from "@lookiero/sty-psp-notifications";
9
+ import { CheckoutBookingProjection } from "../../../projection/checkoutBooking/checkoutBooking";
9
10
  import { useSubmitCheckout } from "../../domain/checkout/react/useSubmitCheckout";
10
11
  import { useBlockCheckoutBooking } from "../../domain/checkoutBooking/react/useBlockCheckoutBooking";
11
12
  import { paymentFlowPayload as mockPaymentFlowPayload } from "../../projection/payment/paymentFlowPayload.mock";
13
+ import { useQueryBus } from "./useQueryBus";
12
14
  import { useSubmitCheckout as sut } from "./useSubmitCheckout";
13
15
 
14
16
  const checkoutId = "9c450400-0cd7-44a4-b0e3-e0002a9bf8df";
@@ -18,6 +20,7 @@ const errorChargeStatuses = Object.values(ChargeStatus).filter((status) => statu
18
20
  const logger = mock<Logger>();
19
21
 
20
22
  jest.mock("@lookiero/sty-psp-notifications");
23
+ jest.mock("./useQueryBus");
21
24
  jest.mock("../../domain/checkout/react/useSubmitCheckout");
22
25
  jest.mock("../../domain/checkoutBooking/react/useBlockCheckoutBooking");
23
26
 
@@ -38,6 +41,7 @@ describe("useSubmitCheckout custom hook", () => {
38
41
  },
39
42
  };
40
43
 
44
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: false }) as CheckoutBookingProjection);
41
45
  (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.SUCCESS]);
42
46
  (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.SUCCESS]);
43
47
  (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.SUCCESS]);
@@ -86,6 +90,7 @@ describe("useSubmitCheckout custom hook", () => {
86
90
  },
87
91
  };
88
92
 
93
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: false }) as CheckoutBookingProjection);
89
94
  (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.SUCCESS]);
90
95
  (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.SUCCESS]);
91
96
  (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.SUCCESS]);
@@ -126,6 +131,7 @@ describe("useSubmitCheckout custom hook", () => {
126
131
  },
127
132
  };
128
133
 
134
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: false }) as CheckoutBookingProjection);
129
135
  (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.ERROR]);
130
136
  (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.IDLE]);
131
137
  (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.IDLE]);
@@ -166,6 +172,7 @@ describe("useSubmitCheckout custom hook", () => {
166
172
  },
167
173
  };
168
174
 
175
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: false }) as CheckoutBookingProjection);
169
176
  (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.SUCCESS]);
170
177
  (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.SUCCESS]);
171
178
  (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.IDLE]);
@@ -212,6 +219,7 @@ describe("useSubmitCheckout custom hook", () => {
212
219
  },
213
220
  };
214
221
 
222
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: false }) as CheckoutBookingProjection);
215
223
  (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.SUCCESS]);
216
224
  (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.ERROR]);
217
225
  (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.SUCCESS]);
@@ -236,4 +244,54 @@ describe("useSubmitCheckout custom hook", () => {
236
244
  expect(mockOnError).toHaveBeenCalled();
237
245
  });
238
246
  });
247
+
248
+ test("returns submitCheckout error as the status right after calling 'submitCheckout' if CheckoutBooking isExpired", async () => {
249
+ const mockBlockCheckoutBooking = jest.fn();
250
+ const mockSubmitCheckout = jest.fn();
251
+ const mockCreateToastNotification = jest.fn();
252
+ const mockOnError = jest.fn();
253
+ const mockOnSuccess = jest.fn();
254
+ const mockPaymentFlowRef: RefObject<PaymentFlowRef> = {
255
+ current: {
256
+ // eslint-disable-next-line @typescript-eslint/naming-convention
257
+ startLegacyBoxCheckout: jest.fn().mockImplementation((_payload, callback) => {
258
+ callback({ status: ChargeStatus.EXECUTED, final: true });
259
+ }),
260
+ startCheckout: jest.fn(),
261
+ },
262
+ };
263
+
264
+ (useQueryBus as jest.Mock).mockReturnValue(() => ({ isExpired: true }) as CheckoutBookingProjection);
265
+ (useBlockCheckoutBooking as jest.Mock).mockReturnValue([mockBlockCheckoutBooking, CommandStatus.SUCCESS]);
266
+ (useCreateToastNotification as jest.Mock).mockReturnValue([mockCreateToastNotification, CommandStatus.SUCCESS]);
267
+ (useSubmitCheckout as jest.Mock).mockReturnValue([mockSubmitCheckout, CommandStatus.SUCCESS]);
268
+
269
+ const { result } = renderHook(() =>
270
+ sut({
271
+ checkoutId,
272
+ checkoutBookingId,
273
+ paymentFlowRef: mockPaymentFlowRef,
274
+ onError: mockOnError,
275
+ onSuccess: mockOnSuccess,
276
+ logger,
277
+ }),
278
+ );
279
+
280
+ await act(async () => {
281
+ const [submitCheckout] = result.current;
282
+ await submitCheckout({ paymentFlowPayload: mockPaymentFlowPayload, sizeChangeEnabled: true });
283
+ });
284
+
285
+ await waitFor(() => {
286
+ const [, status] = result.current;
287
+
288
+ expect(mockBlockCheckoutBooking).toHaveBeenCalled();
289
+ expect(mockCreateToastNotification).not.toHaveBeenCalled();
290
+ expect(mockSubmitCheckout).not.toHaveBeenCalled();
291
+
292
+ expect(status).toBe("error");
293
+ expect(mockOnSuccess).not.toHaveBeenCalled();
294
+ expect(mockOnError).toHaveBeenCalled();
295
+ });
296
+ });
239
297
  });
@@ -1,14 +1,39 @@
1
1
  import { RefObject, useCallback, useMemo, useState } from "react";
2
2
  import { CommandStatus } from "@lookiero/messaging-react";
3
- import { PaymentFlowRef, PaymentPayload } from "@lookiero/payments-front";
3
+ import { PaymentFlowRef } from "@lookiero/payments-front";
4
4
  import { Logger } from "@lookiero/sty-psp-logging";
5
5
  import { NotificationLevel, useCreateToastNotification } from "@lookiero/sty-psp-notifications";
6
+ import {
7
+ ViewCheckoutBookingById,
8
+ viewCheckoutBookingById,
9
+ ViewCheckoutBookingByIdResult,
10
+ } from "../../../projection/checkoutBooking/viewCheckoutBookingById";
6
11
  import { PaymentFlowPayloadProjection } from "../../../projection/payment/paymentFlowPayload";
7
12
  import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
8
13
  import { useSubmitCheckout as useSubmitCheckoutCommand } from "../../domain/checkout/react/useSubmitCheckout";
9
14
  import { useBlockCheckoutBooking } from "../../domain/checkoutBooking/react/useBlockCheckoutBooking";
10
15
  import { I18nMessages } from "../i18n/i18n";
11
- import { usePaymentInstrumentEvents } from "./usePaymentInstrumentEvents";
16
+ import { useQueryBus } from "./useQueryBus";
17
+
18
+ enum ChargeStatus {
19
+ EXECUTED = "EXECUTED",
20
+ REQUIRES_ACTION = "REQUIRES_ACTION",
21
+ REQUIRED_ACTION_CANCELLED = "REQUIRED_ACTION_CANCELLED",
22
+ REJECTED = "REJECTED",
23
+ CANCELLED = "CANCELLED",
24
+ TO_CONFIRM = "TO_CONFIRM",
25
+ ERROR = "ERROR",
26
+ UNKNOWN = "UNKNOWN",
27
+ }
28
+ interface LegacyBoxCheckout {
29
+ readonly status: ChargeStatus;
30
+ readonly toaster: {
31
+ id: string;
32
+ } | null;
33
+ readonly final: boolean;
34
+ readonly id?: string;
35
+ readonly translation?: string;
36
+ }
12
37
 
13
38
  type Status = "idle" | "loading" | "success" | "error";
14
39
 
@@ -28,7 +53,7 @@ interface UseSubmitCheckoutFunctionArgs {
28
53
  readonly checkoutBookingId: string;
29
54
  readonly paymentFlowRef: RefObject<PaymentFlowRef>;
30
55
  readonly onError: () => void;
31
- readonly onSuccess: () => void;
56
+ readonly onSuccess?: () => void;
32
57
  readonly logger: Logger;
33
58
  }
34
59
 
@@ -44,9 +69,11 @@ const useSubmitCheckout: UseSubmitCheckoutFunction = ({
44
69
  onSuccess,
45
70
  logger,
46
71
  }) => {
72
+ const queryBus = useQueryBus();
47
73
  const [submitCheckoutCommand, submitCheckoutCommandStatus] = useSubmitCheckoutCommand({ checkoutId, logger });
48
74
  const [blockCheckoutBooking, blockCheckoutBookingStatus] = useBlockCheckoutBooking({ checkoutBookingId, logger });
49
75
  const [createNotification] = useCreateToastNotification({ contextId: MESSAGING_CONTEXT_ID, logger });
76
+ const [checkoutBookingExpired, setCheckoutBookingExpired] = useState(false);
50
77
 
51
78
  const [startLegacyBoxCheckoutStatus, setStartLegacyBoxCheckoutStatus] = useState<Status>("idle");
52
79
 
@@ -58,37 +85,48 @@ const useSubmitCheckout: UseSubmitCheckoutFunction = ({
58
85
  return;
59
86
  }
60
87
 
61
- setStartLegacyBoxCheckoutStatus("loading");
62
-
63
- // eslint-disable-next-line @typescript-eslint/ban-ts-comment
64
- // @ts-ignore
65
- paymentFlowRef.current?.startLegacyBoxCheckout(paymentFlowPayload);
66
- },
67
- [paymentFlowRef, blockCheckoutBooking],
68
- );
88
+ const checkoutBooking = await queryBus<ViewCheckoutBookingById, ViewCheckoutBookingByIdResult>(
89
+ viewCheckoutBookingById({ checkoutBookingId }),
90
+ );
69
91
 
70
- const onPaymentSuccess = useCallback(async () => {
71
- setStartLegacyBoxCheckoutStatus("success");
72
-
73
- await submitCheckoutCommand();
74
-
75
- createNotification({
76
- bodyI18nKey: I18nMessages.CHECKOUT_TOAST_PAYMENT_SUCCESS,
77
- level: NotificationLevel.SUCCESS,
78
- });
79
- }, [createNotification, submitCheckoutCommand]);
80
- const onPaymentError = useCallback(
81
- (payload: PaymentPayload) => {
82
- setStartLegacyBoxCheckoutStatus("error");
92
+ if (checkoutBooking?.isExpired) {
93
+ setCheckoutBookingExpired(true);
94
+ return;
95
+ }
83
96
 
84
- createNotification({
85
- bodyI18nKey: payload.metadata?.toaster?.id || I18nMessages.CHECKOUT_TOAST_PAYMENT_ERROR,
86
- level: NotificationLevel.ERROR,
87
- });
97
+ paymentFlowRef.current?.startLegacyBoxCheckout(
98
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
99
+ // @ts-ignore
100
+ paymentFlowPayload,
101
+ async ({ status, toaster, final }: LegacyBoxCheckout) => {
102
+ setStartLegacyBoxCheckoutStatus("loading");
103
+
104
+ if (final) {
105
+ if (status === ChargeStatus.EXECUTED) {
106
+ setStartLegacyBoxCheckoutStatus("success");
107
+ await submitCheckoutCommand();
108
+ onSuccess?.();
109
+ } else {
110
+ createNotification({
111
+ level: NotificationLevel.ERROR,
112
+ bodyI18nKey: toaster?.id || I18nMessages.CHECKOUT_TOAST_PAYMENT_ERROR,
113
+ });
114
+ setStartLegacyBoxCheckoutStatus("error");
115
+ }
116
+ }
117
+ },
118
+ );
88
119
  },
89
- [createNotification],
120
+ [
121
+ queryBus,
122
+ checkoutBookingId,
123
+ paymentFlowRef,
124
+ blockCheckoutBooking,
125
+ submitCheckoutCommand,
126
+ onSuccess,
127
+ createNotification,
128
+ ],
90
129
  );
91
- usePaymentInstrumentEvents({ onSuccess: onPaymentSuccess, onError: onPaymentError });
92
130
 
93
131
  const status: Status = useMemo(() => {
94
132
  if (
@@ -103,20 +141,26 @@ const useSubmitCheckout: UseSubmitCheckoutFunction = ({
103
141
  startLegacyBoxCheckoutStatus === "success" &&
104
142
  submitCheckoutCommandStatus === CommandStatus.SUCCESS
105
143
  ) {
106
- onSuccess();
107
144
  return "success";
108
145
  }
109
146
  if (
110
147
  blockCheckoutBookingStatus === CommandStatus.ERROR ||
111
148
  startLegacyBoxCheckoutStatus === "error" ||
112
- submitCheckoutCommandStatus === CommandStatus.ERROR
149
+ submitCheckoutCommandStatus === CommandStatus.ERROR ||
150
+ checkoutBookingExpired
113
151
  ) {
114
152
  onError();
115
153
  return "error";
116
154
  }
117
155
 
118
156
  return "idle";
119
- }, [blockCheckoutBookingStatus, startLegacyBoxCheckoutStatus, submitCheckoutCommandStatus, onSuccess, onError]);
157
+ }, [
158
+ blockCheckoutBookingStatus,
159
+ startLegacyBoxCheckoutStatus,
160
+ submitCheckoutCommandStatus,
161
+ checkoutBookingExpired,
162
+ onError,
163
+ ]);
120
164
 
121
165
  return [submitCheckout, status];
122
166
  };
@@ -48,7 +48,6 @@ enum I18nMessages {
48
48
  CHECKOUT_TITLE = "checkout.title",
49
49
  CHECKOUT_PAY_BUTTON = "checkout.pay_button",
50
50
  CHECKOUT_TOAST_PAYMENT_ERROR = "checkout.toast_payment_error",
51
- CHECKOUT_TOAST_PAYMENT_SUCCESS = "checkout.toast_payment_success",
52
51
  CHECKOUT_SUCCESS_MODAL_TITLE = "checkout.success_modal_title",
53
52
  CHECKOUT_SUCCESS_MODAL_DESCRIPTION = "checkout.success_modal_description",
54
53
  CHECKOUT_SUCCESS_MODAL_BUTTON = "checkout.success_modal_button",
@@ -1,7 +1,8 @@
1
- import { PortalHost } from "@gorhom/portal";
1
+ import { PortalProvider } from "@gorhom/portal";
2
2
  import React, { FC } from "react";
3
3
  import { StatusBar } from "react-native";
4
4
  import { SafeAreaProvider } from "react-native-safe-area-context";
5
+ import { PortalProvider as AuroraPortalProvider } from "@lookiero/aurora";
5
6
  import { Notifications } from "@lookiero/sty-psp-notifications";
6
7
  import { theme } from "@lookiero/sty-psp-ui";
7
8
  import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
@@ -14,10 +15,17 @@ interface AppProps {
14
15
 
15
16
  const App: FC<AppProps> = ({ children }) => (
16
17
  <SafeAreaProvider>
17
- <StatusBar backgroundColor={colorBgBase} barStyle="dark-content" translucent />
18
- <Notifications contextId={MESSAGING_CONTEXT_ID} portalHostName="Checkout" />
19
- <PortalHost name="Checkout" />
20
- {children}
18
+ <PortalProvider rootHostName="Checkout">
19
+ <StatusBar backgroundColor={colorBgBase} barStyle="dark-content" translucent />
20
+ <Notifications contextId={MESSAGING_CONTEXT_ID} portalHostName="Checkout" />
21
+ {/*
22
+ We are using the Aurora's PortalProvider at this level for notifications to work properly.
23
+
24
+ PaymentInstrumentSelect uses Aurora's Portal, and if we rely on UAF's Portal (injected by <Aurora>)
25
+ notifications would be displayed in a layer below Portal's one (not visible).
26
+ */}
27
+ <AuroraPortalProvider>{children}</AuroraPortalProvider>
28
+ </PortalProvider>
21
29
  </SafeAreaProvider>
22
30
  );
23
31
 
@@ -30,9 +30,6 @@ const style = StyleSheet.create({
30
30
  paymentSelector: {
31
31
  marginTop: space6,
32
32
  },
33
- paymentSelectorNL: {
34
- marginBottom: space6,
35
- },
36
33
  princingWrapper: {
37
34
  padding: space6,
38
35
  },
@@ -4,7 +4,6 @@ import { useNavigate } from "react-router-native";
4
4
  import { Box, Button, Layout as AuroraLayout, Spinner, Text, useDevice } from "@lookiero/aurora";
5
5
  import { useI18nMessage } from "@lookiero/i18n-react";
6
6
  import { QueryStatus } from "@lookiero/messaging-react";
7
- import { Country } from "@lookiero/sty-psp-locale";
8
7
  import { Layout as UiLayout, Sticky } from "@lookiero/sty-psp-ui";
9
8
  import { CheckoutItemStatus } from "../../../../domain/checkoutItem/model/checkoutItem";
10
9
  import { useViewFirstAvailableCheckoutByCustomerId } from "../../../projection/checkout/react/useViewFirstAvailableCheckoutByCustomerId";
@@ -117,12 +116,6 @@ const Checkout: FC<CheckoutProps> = ({ children, layout: Layout, useRedirect })
117
116
  >
118
117
  <Box size={{ L: "2/3" }} style={screen.L && style.desktopListSpacing}>
119
118
  <View style={[style.contentWrapper, screen.L && style.desktopContentWrapper]}>
120
- {country === Country.NL && (
121
- <View style={style.paymentSelectorNL}>
122
- <PaymentInstrument useRedirect={useRedirect} />
123
- </View>
124
- )}
125
-
126
119
  <Text level={3} style={style.title} heading>
127
120
  {titleText}
128
121
  </Text>
@@ -146,11 +139,9 @@ const Checkout: FC<CheckoutProps> = ({ children, layout: Layout, useRedirect })
146
139
  </View>
147
140
  ))}
148
141
 
149
- {country !== Country.NL && (
150
- <View style={style.paymentSelector}>
151
- <PaymentInstrument useRedirect={useRedirect} />
152
- </View>
153
- )}
142
+ <View style={style.paymentSelector}>
143
+ <PaymentInstrument useRedirect={useRedirect} />
144
+ </View>
154
145
  </View>
155
146
  </Box>
156
147
 
@@ -1,7 +1,7 @@
1
1
  import React, { FC, useCallback, useEffect, useRef, useState } from "react";
2
2
  import { useNavigate } from "react-router-native";
3
3
  import { QueryStatus } from "@lookiero/messaging-react";
4
- import { PaymentFlow, PaymentFlowRef, Section } from "@lookiero/payments-front";
4
+ import { PaymentFlow, PaymentFlowRef } from "@lookiero/payments-front";
5
5
  import { useLogger } from "@lookiero/sty-psp-logging";
6
6
  import { CheckoutItemStatus } from "../../../../../../domain/checkoutItem/model/checkoutItem";
7
7
  import { Currency } from "../../../../../../domain/checkoutItem/model/currency";
@@ -119,7 +119,7 @@ const CheckoutPaymentModal: FC<CheckoutPaymentModalProps> = ({
119
119
 
120
120
  if (!dependenciesLoaded) return null;
121
121
 
122
- return <PaymentFlow ref={paymentFlowRef} section={Section.BOX_CHECKOUT} token={authToken} />;
122
+ return <PaymentFlow ref={paymentFlowRef} token={authToken} />;
123
123
  };
124
124
 
125
125
  export { CheckoutPaymentModal };
@@ -78,7 +78,7 @@ exports[`DeliveryBanner component matches the snapshot 1`] = `
78
78
  "paddingBottom": 0,
79
79
  "paddingLeft": 0,
80
80
  "paddingRight": 0,
81
- "paddingTop": 5,
81
+ "paddingTop": 4,
82
82
  },
83
83
  ]
84
84
  }
@@ -1,24 +1,24 @@
1
- import React, { FC } from "react";
1
+ import React, { FC, useRef } from "react";
2
2
  import { PaymentInstrumentSelect, Section } from "@lookiero/payments-front";
3
- import { useStaticInfo } from "../../../../hooks/useStaticInfo";
3
+ import { useLogger } from "@lookiero/sty-psp-logging";
4
+ import { usePaymentInstrumentEvents } from "../../../../hooks/usePaymentInstrumentEvents";
4
5
 
5
6
  interface PaymentInstrumentProps {
6
7
  readonly useRedirect: () => Record<string, string>;
7
8
  }
8
9
  const PaymentInstrument: FC<PaymentInstrumentProps> = ({ useRedirect }) => {
10
+ const paymentInstrumentSelectRef = useRef(null);
9
11
  const { returnUrl } = useRedirect();
10
- const { customer } = useStaticInfo();
12
+ const logger = useLogger();
13
+
14
+ usePaymentInstrumentEvents({ logger });
11
15
 
12
16
  return (
13
17
  <PaymentInstrumentSelect
18
+ ref={paymentInstrumentSelectRef}
14
19
  beforeRedirect={returnUrl ? () => Promise.resolve(returnUrl) : undefined}
15
20
  hasError={false}
16
21
  section={Section.BOX_CHECKOUT}
17
- userInformation={{
18
- email: customer.email,
19
- name: customer.name,
20
- }}
21
- showSingleUsePaymentMethods
22
22
  />
23
23
  );
24
24
  };
@@ -89,7 +89,7 @@ exports[`CustomerDecissionBanner component matches the snapshot for a KEPT check
89
89
  "paddingBottom": 0,
90
90
  "paddingLeft": 0,
91
91
  "paddingRight": 0,
92
- "paddingTop": 5,
92
+ "paddingTop": 4,
93
93
  },
94
94
  ]
95
95
  }
@@ -258,7 +258,7 @@ exports[`CustomerDecissionBanner component matches the snapshot for a REPLACED c
258
258
  "paddingBottom": 0,
259
259
  "paddingLeft": 0,
260
260
  "paddingRight": 0,
261
- "paddingTop": 5,
261
+ "paddingTop": 4,
262
262
  },
263
263
  ]
264
264
  }
@@ -427,7 +427,7 @@ exports[`CustomerDecissionBanner component matches the snapshot for a RETURNED c
427
427
  "paddingBottom": 0,
428
428
  "paddingLeft": 0,
429
429
  "paddingRight": 0,
430
- "paddingTop": 5,
430
+ "paddingTop": 4,
431
431
  },
432
432
  ]
433
433
  }
@@ -217,7 +217,7 @@ exports[`GetOutOfCheckoutModal component matches the snapshot 1`] = `
217
217
  "paddingBottom": 0,
218
218
  "paddingLeft": 0,
219
219
  "paddingRight": 0,
220
- "paddingTop": 2,
220
+ "paddingTop": 0,
221
221
  "width": "100%",
222
222
  },
223
223
  ]
@@ -339,7 +339,7 @@ exports[`GetOutOfCheckoutModal component matches the snapshot 1`] = `
339
339
  "paddingBottom": 0,
340
340
  "paddingLeft": 0,
341
341
  "paddingRight": 0,
342
- "paddingTop": 2,
342
+ "paddingTop": 0,
343
343
  "textAlign": "center",
344
344
  "textTransform": "uppercase",
345
345
  "width": "100%",
@@ -469,7 +469,7 @@ exports[`GetOutOfCheckoutModal component matches the snapshot 1`] = `
469
469
  "paddingBottom": 0,
470
470
  "paddingLeft": 0,
471
471
  "paddingRight": 0,
472
- "paddingTop": 2,
472
+ "paddingTop": 0,
473
473
  "textAlign": "center",
474
474
  "textTransform": "uppercase",
475
475
  "width": "100%",
@@ -222,7 +222,7 @@ exports[`ItemActions component matches the snapshot 1`] = `
222
222
  "paddingBottom": 0,
223
223
  "paddingLeft": 0,
224
224
  "paddingRight": 0,
225
- "paddingTop": 2,
225
+ "paddingTop": 0,
226
226
  "textAlign": "center",
227
227
  },
228
228
  ]
@@ -350,7 +350,7 @@ exports[`ItemActions component matches the snapshot 1`] = `
350
350
  "paddingBottom": 0,
351
351
  "paddingLeft": 0,
352
352
  "paddingRight": 0,
353
- "paddingTop": 2,
353
+ "paddingTop": 0,
354
354
  "textAlign": "center",
355
355
  },
356
356
  ]
@@ -475,7 +475,7 @@ exports[`ItemActions component matches the snapshot 1`] = `
475
475
  "paddingBottom": 0,
476
476
  "paddingLeft": 0,
477
477
  "paddingRight": 0,
478
- "paddingTop": 2,
478
+ "paddingTop": 0,
479
479
  "textAlign": "center",
480
480
  },
481
481
  ]
@@ -788,7 +788,7 @@ exports[`ItemActions component matches the snapshot 1`] = `
788
788
  "paddingBottom": 0,
789
789
  "paddingLeft": 0,
790
790
  "paddingRight": 0,
791
- "paddingTop": 2,
791
+ "paddingTop": 0,
792
792
  },
793
793
  ]
794
794
  }
@@ -846,7 +846,7 @@ exports[`ItemActions component matches the snapshot 1`] = `
846
846
  "paddingBottom": 0,
847
847
  "paddingLeft": 0,
848
848
  "paddingRight": 0,
849
- "paddingTop": 2,
849
+ "paddingTop": 0,
850
850
  },
851
851
  ]
852
852
  }
@@ -1,11 +1,12 @@
1
1
  import { StyleSheet } from "react-native";
2
2
  import { theme } from "@lookiero/sty-psp-ui";
3
3
 
4
- const { space4, space6 } = theme();
4
+ const { space1, space4, space6 } = theme();
5
5
 
6
6
  const style = StyleSheet.create({
7
7
  brand: {
8
8
  flex: 1,
9
+ gap: space1,
9
10
  },
10
11
  container: {
11
12
  width: "100%",
@@ -54,6 +54,7 @@ exports[`ProductVariantDescription component matches the snapshot for a non-uniq
54
54
  style={
55
55
  {
56
56
  "flex": 1,
57
+ "gap": 4,
57
58
  }
58
59
  }
59
60
  >
@@ -71,7 +72,7 @@ exports[`ProductVariantDescription component matches the snapshot for a non-uniq
71
72
  "paddingBottom": 0,
72
73
  "paddingLeft": 0,
73
74
  "paddingRight": 0,
74
- "paddingTop": 4,
75
+ "paddingTop": 0,
75
76
  },
76
77
  ]
77
78
  }
@@ -92,7 +93,7 @@ exports[`ProductVariantDescription component matches the snapshot for a non-uniq
92
93
  "paddingBottom": 0,
93
94
  "paddingLeft": 0,
94
95
  "paddingRight": 0,
95
- "paddingTop": 4,
96
+ "paddingTop": 0,
96
97
  },
97
98
  ]
98
99
  }
@@ -122,7 +123,7 @@ exports[`ProductVariantDescription component matches the snapshot for a non-uniq
122
123
  "paddingBottom": 0,
123
124
  "paddingLeft": 0,
124
125
  "paddingRight": 0,
125
- "paddingTop": 4,
126
+ "paddingTop": 0,
126
127
  },
127
128
  ]
128
129
  }
@@ -146,7 +147,7 @@ exports[`ProductVariantDescription component matches the snapshot for a non-uniq
146
147
  "paddingBottom": 0,
147
148
  "paddingLeft": 0,
148
149
  "paddingRight": 0,
149
- "paddingTop": 4,
150
+ "paddingTop": 0,
150
151
  },
151
152
  ]
152
153
  }
@@ -211,6 +212,7 @@ exports[`ProductVariantDescription component matches the snapshot for an unique
211
212
  style={
212
213
  {
213
214
  "flex": 1,
215
+ "gap": 4,
214
216
  }
215
217
  }
216
218
  >
@@ -228,7 +230,7 @@ exports[`ProductVariantDescription component matches the snapshot for an unique
228
230
  "paddingBottom": 0,
229
231
  "paddingLeft": 0,
230
232
  "paddingRight": 0,
231
- "paddingTop": 4,
233
+ "paddingTop": 0,
232
234
  },
233
235
  ]
234
236
  }
@@ -249,7 +251,7 @@ exports[`ProductVariantDescription component matches the snapshot for an unique
249
251
  "paddingBottom": 0,
250
252
  "paddingLeft": 0,
251
253
  "paddingRight": 0,
252
- "paddingTop": 4,
254
+ "paddingTop": 0,
253
255
  },
254
256
  ]
255
257
  }
@@ -279,7 +281,7 @@ exports[`ProductVariantDescription component matches the snapshot for an unique
279
281
  "paddingBottom": 0,
280
282
  "paddingLeft": 0,
281
283
  "paddingRight": 0,
282
- "paddingTop": 4,
284
+ "paddingTop": 0,
283
285
  },
284
286
  ]
285
287
  }
@@ -303,7 +305,7 @@ exports[`ProductVariantDescription component matches the snapshot for an unique
303
305
  "paddingBottom": 0,
304
306
  "paddingLeft": 0,
305
307
  "paddingRight": 0,
306
- "paddingTop": 4,
308
+ "paddingTop": 0,
307
309
  },
308
310
  ]
309
311
  }