@lookiero/checkout 8.14.0-beta.2 → 8.14.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 (225) hide show
  1. package/.eslintrc.js +1 -1
  2. package/cypress/integration/checkout.spec.ts +259 -0
  3. package/cypress/support/e2e.ts +3 -0
  4. package/cypress/support/index.d.ts +8 -0
  5. package/cypress/support/interceptBlockCheckoutBooking.ts +4 -0
  6. package/cypress/support/interceptGiveCheckoutFeedback.ts +4 -0
  7. package/cypress/support/interceptKeepCheckoutItem.ts +4 -0
  8. package/cypress/support/interceptListCheckoutQuestionsByCheckoutId.ts +9 -0
  9. package/cypress/support/interceptListReturnQuestionsByCheckoutItemId.ts +9 -0
  10. package/cypress/support/interceptPayment.ts +23 -0
  11. package/cypress/support/interceptReplaceCheckoutItem.ts +4 -0
  12. package/cypress/support/interceptReturnCheckoutItem.ts +4 -0
  13. package/cypress/support/interceptSubmitCheckout.ts +4 -0
  14. package/cypress/support/interceptViewBookedProductsVariantsForCheckoutItem.ts +9 -0
  15. package/cypress/support/interceptViewCheckoutById.ts +6 -0
  16. package/cypress/support/interceptViewFirstAvailableCheckoutByCustomerId.ts +9 -0
  17. package/cypress/support/interceptViewFiveItemsDiscountByCustomerId.ts +6 -0
  18. package/cypress/support/interceptViewIsSizeChangeEnabledByCheckoutId.ts +6 -0
  19. package/cypress/support/interceptViewPaymentFlowPayloadByCheckoutId.ts +9 -0
  20. package/cypress/support/interceptViewPricingByCheckoutId.ts +6 -0
  21. package/cypress/tsconfig.json +8 -0
  22. package/cypress.config.ts +50 -0
  23. package/dist/src/ExpoRoot.js +2 -2
  24. package/dist/src/infrastructure/projection/payment/react/useViewPaymentFlowPayloadByCheckoutId.js +1 -1
  25. package/dist/src/infrastructure/ui/Root.d.ts +0 -2
  26. package/dist/src/infrastructure/ui/Root.js +2 -2
  27. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.d.ts +0 -5
  28. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.js +5 -3
  29. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.d.ts +0 -5
  30. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.js +1 -1
  31. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/behaviors/isChildReturnQuestion.js +2 -1
  32. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/behaviors/useReturnQuestionItem.d.ts +3 -3
  33. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/ReturnQuestionItem.d.ts +4 -8
  34. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionFeedbackItem/HostDefaultReturnQuestionFeedbackItem.d.ts +2 -1
  35. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionFeedbackItem/HostDefaultReturnQuestionFeedbackItem.js +1 -0
  36. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.d.ts +2 -1
  37. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.js +8 -6
  38. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.d.ts +2 -1
  39. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.js +2 -1
  40. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.d.ts +2 -1
  41. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.js +4 -3
  42. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.d.ts +1 -1
  43. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.js +1 -1
  44. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/form/HostStackReturnQuestionItem.d.ts +2 -1
  45. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/form/HostStackReturnQuestionItem.js +2 -1
  46. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.d.ts +2 -1
  47. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.js +7 -5
  48. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.d.ts +1 -3
  49. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.js +6 -4
  50. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.d.ts +2 -1
  51. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.js +2 -1
  52. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.d.ts +2 -1
  53. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.js +6 -5
  54. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.d.ts +2 -1
  55. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.js +2 -1
  56. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.d.ts +2 -1
  57. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.js +2 -1
  58. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/util/returnQuestionFeedback.js +18 -9
  59. package/dist/src/infrastructure/ui/routing/Routing.d.ts +0 -7
  60. package/dist/src/infrastructure/ui/routing/Routing.js +5 -5
  61. package/dist/src/infrastructure/ui/views/App.d.ts +0 -8
  62. package/dist/src/infrastructure/ui/views/App.js +6 -8
  63. package/dist/src/infrastructure/ui/views/item/Item.d.ts +0 -5
  64. package/dist/src/infrastructure/ui/views/item/Item.js +3 -3
  65. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.d.ts +0 -2
  66. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.js +2 -2
  67. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.d.ts +1 -1
  68. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.js +1 -1
  69. package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.d.ts +1 -5
  70. package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.js +2 -2
  71. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.d.ts +0 -5
  72. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.js +3 -3
  73. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.d.ts +3 -3
  74. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.js +2 -2
  75. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.d.ts +1 -1
  76. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.js +1 -1
  77. package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.d.ts +0 -2
  78. package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.js +2 -2
  79. package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.d.ts +0 -5
  80. package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.js +2 -2
  81. package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.d.ts +0 -5
  82. package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.js +2 -2
  83. package/dist/src/infrastructure/ui/views/return/Return.d.ts +0 -5
  84. package/dist/src/infrastructure/ui/views/return/Return.js +2 -2
  85. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.d.ts +0 -5
  86. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.js +15 -13
  87. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +6 -2
  88. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.js +6 -2
  89. package/dist/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.js +2 -2
  90. package/dist/src/projection/returnQuestion/returnQuestion.constants.d.ts +9 -0
  91. package/dist/src/projection/returnQuestion/returnQuestion.constants.js +10 -0
  92. package/dist/src/projection/returnQuestion/returnQuestion.d.ts +23 -16
  93. package/dist/src/projection/returnQuestion/returnQuestion.js +1 -11
  94. package/dist/src/projection/returnQuestion/returnQuestion.metadata.d.ts +12 -0
  95. package/dist/src/projection/returnQuestion/returnQuestion.metadata.js +1 -0
  96. package/dist/src/projection/returnQuestion/returnQuestion.typeguard.d.ts +5 -0
  97. package/dist/src/projection/returnQuestion/returnQuestion.typeguard.js +10 -0
  98. package/dist/src/version.d.ts +1 -1
  99. package/dist/src/version.js +1 -1
  100. package/jest.setup.js +0 -20
  101. package/package.json +9 -8
  102. package/src/ExpoRoot.tsx +2 -2
  103. package/src/infrastructure/domain/uiSetting/react/useUpdateUiSetting.test.ts +1 -1
  104. package/src/infrastructure/projection/payment/react/useViewPaymentFlowPayloadByCheckoutId.ts +1 -1
  105. package/src/infrastructure/projection/returnQuestion/react/useListReturnQuestionsByCheckoutItemId.test.ts +4 -9
  106. package/src/infrastructure/projection/returnQuestion/returnQuestions.mock.ts +72 -117
  107. package/src/infrastructure/ui/Root.tsx +1 -4
  108. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.test.tsx +10 -12
  109. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.tsx +11 -22
  110. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.test.tsx +10 -9
  111. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.tsx +1 -8
  112. package/src/infrastructure/ui/components/organisms/returnQuestions/behaviors/isChildReturnQuestion.ts +2 -1
  113. package/src/infrastructure/ui/components/organisms/returnQuestions/behaviors/useReturnQuestionItem.test.tsx +7 -9
  114. package/src/infrastructure/ui/components/organisms/returnQuestions/behaviors/useReturnQuestionItem.tsx +3 -3
  115. package/src/infrastructure/ui/components/organisms/returnQuestions/components/ReturnQuestionItem.ts +4 -9
  116. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionFeedbackItem/HostDefaultReturnQuestionFeedbackItem.test.tsx +7 -13
  117. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionFeedbackItem/HostDefaultReturnQuestionFeedbackItem.tsx +4 -2
  118. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.test.tsx +8 -14
  119. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem.tsx +13 -7
  120. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostRadioGroupReturnQuestionItem/HostRadioGroupReturnQuestionItem.tsx +7 -5
  121. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.style.ts +1 -1
  122. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.test.tsx +10 -14
  123. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.tsx +8 -7
  124. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/form/HostStackReturnQuestionItem.tsx +5 -5
  125. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.test.tsx +43 -36
  126. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.tsx +10 -9
  127. package/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.tsx +13 -14
  128. package/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.test.tsx +8 -14
  129. package/src/infrastructure/ui/components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem.tsx +6 -4
  130. package/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.tsx +8 -7
  131. package/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.test.tsx +23 -25
  132. package/src/infrastructure/ui/components/organisms/returnQuestions/components/returnQuestionFeedbackItem/ReturnQuestionFeedbackItem.tsx +5 -3
  133. package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.test.tsx +9 -29
  134. package/src/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.tsx +7 -5
  135. package/src/infrastructure/ui/components/organisms/returnQuestions/util/__snapshots__/returnQuestionFeedback.test.ts.snap +5 -4
  136. package/src/infrastructure/ui/components/organisms/returnQuestions/util/returnQuestionFeedback.ts +32 -18
  137. package/src/infrastructure/ui/routing/Routing.tsx +5 -13
  138. package/src/infrastructure/ui/views/App.tsx +11 -21
  139. package/src/infrastructure/ui/views/item/Item.tsx +2 -8
  140. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.style.ts +1 -1
  141. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.tsx +3 -9
  142. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/__snapshots__/GetOutOfCheckoutModal.test.tsx.snap +7 -0
  143. package/src/infrastructure/ui/views/item/components/itemActions/ItemActions.tsx +1 -8
  144. package/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.tsx +5 -16
  145. package/src/infrastructure/ui/views/item/components/selectModal/SelectModal.style.ts +1 -1
  146. package/src/infrastructure/ui/views/item/components/selectModal/SelectModal.tsx +6 -6
  147. package/src/infrastructure/ui/views/item/components/selectModal/__snapshots__/SelecModal.test.tsx.snap +7 -0
  148. package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.tsx +3 -4
  149. package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/__snapshots__/SizeWithoutStockModal.test.tsx.snap +7 -0
  150. package/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.tsx +2 -12
  151. package/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.tsx +4 -14
  152. package/src/infrastructure/ui/views/return/Return.tsx +1 -8
  153. package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.ts +6 -2
  154. package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.tsx +39 -34
  155. package/src/infrastructure/ui/views/summary/components/collapsiblePricing/CollapsiblePricing.tsx +2 -2
  156. package/src/infrastructure/ui/views/summary/components/collapsiblePricing/__snapshots__/CollapsiblePricing.test.tsx.snap +2 -2
  157. package/src/projection/returnQuestion/listReturnQuestionsByCheckoutItemId.test.ts +4 -12
  158. package/src/projection/returnQuestion/returnQuestion.constants.ts +10 -0
  159. package/src/projection/returnQuestion/returnQuestion.metadata.ts +17 -0
  160. package/src/projection/returnQuestion/returnQuestion.ts +42 -20
  161. package/src/projection/returnQuestion/returnQuestion.typeguard.ts +24 -0
  162. package/dist/pact.config.d.ts +0 -13
  163. package/dist/pact.config.js +0 -9
  164. package/dist/public/public/assets/adaptive-icon.png +0 -0
  165. package/dist/public/public/assets/favicon.png +0 -0
  166. package/dist/public/public/assets/icon.png +0 -0
  167. package/dist/public/public/assets/splash.png +0 -0
  168. package/dist/public/public/images/not-found.png +0 -0
  169. package/dist/src/infrastructure/projection/bookedProductsVariants/bookedProductsVariants.mock.d.ts +0 -3
  170. package/dist/src/infrastructure/projection/bookedProductsVariants/bookedProductsVariants.mock.js +0 -27
  171. package/dist/src/infrastructure/projection/bookedProductsVariants/httpBookedProductsVariantsForCheckoutItemView.pact.d.ts +0 -1
  172. package/dist/src/infrastructure/projection/bookedProductsVariants/httpBookedProductsVariantsForCheckoutItemView.pact.js +0 -48
  173. package/dist/src/infrastructure/projection/checkout/checkout.mock.d.ts +0 -19
  174. package/dist/src/infrastructure/projection/checkout/checkout.mock.js +0 -21
  175. package/dist/src/infrastructure/projection/checkout/httpCheckoutByIdView.pact.d.ts +0 -1
  176. package/dist/src/infrastructure/projection/checkout/httpCheckoutByIdView.pact.js +0 -109
  177. package/dist/src/infrastructure/projection/checkout/httpFirstAvailableCheckoutByCustomerIdView.pact.d.ts +0 -1
  178. package/dist/src/infrastructure/projection/checkout/httpFirstAvailableCheckoutByCustomerIdView.pact.js +0 -49
  179. package/dist/src/infrastructure/projection/checkout/httpFiveItemsDiscountByCustomerIdView.pact.d.ts +0 -1
  180. package/dist/src/infrastructure/projection/checkout/httpFiveItemsDiscountByCustomerIdView.pact.js +0 -44
  181. package/dist/src/infrastructure/projection/checkout/httpIsCheckoutEnabledByCustomerIdView.pact.d.ts +0 -1
  182. package/dist/src/infrastructure/projection/checkout/httpIsCheckoutEnabledByCustomerIdView.pact.js +0 -44
  183. package/dist/src/infrastructure/projection/checkout/httpIsSizeChangeEnabledByCheckoutIdView.pact.d.ts +0 -1
  184. package/dist/src/infrastructure/projection/checkout/httpIsSizeChangeEnabledByCheckoutIdView.pact.js +0 -44
  185. package/dist/src/infrastructure/projection/checkoutBooking/checkoutBooking.mock.d.ts +0 -3
  186. package/dist/src/infrastructure/projection/checkoutBooking/checkoutBooking.mock.js +0 -6
  187. package/dist/src/infrastructure/projection/checkoutBooking/httpCheckoutBookingByIdView.pact.d.ts +0 -1
  188. package/dist/src/infrastructure/projection/checkoutBooking/httpCheckoutBookingByIdView.pact.js +0 -49
  189. package/dist/src/infrastructure/projection/checkoutItem/checkoutItem.mock.d.ts +0 -15
  190. package/dist/src/infrastructure/projection/checkoutItem/checkoutItem.mock.js +0 -43
  191. package/dist/src/infrastructure/projection/checkoutItem/httpCheckoutItemByIdView.pact.d.ts +0 -1
  192. package/dist/src/infrastructure/projection/checkoutItem/httpCheckoutItemByIdView.pact.js +0 -50
  193. package/dist/src/infrastructure/projection/checkoutQuestion/checkoutQuestions.mock.d.ts +0 -3
  194. package/dist/src/infrastructure/projection/checkoutQuestion/checkoutQuestions.mock.js +0 -103
  195. package/dist/src/infrastructure/projection/checkoutQuestion/httpCheckoutQuestionsByCheckoutIdView.pact.d.ts +0 -1
  196. package/dist/src/infrastructure/projection/checkoutQuestion/httpCheckoutQuestionsByCheckoutIdView.pact.js +0 -48
  197. package/dist/src/infrastructure/projection/payment/httpPaymentFlowPayloadByCheckoutIdView.pact.d.ts +0 -1
  198. package/dist/src/infrastructure/projection/payment/httpPaymentFlowPayloadByCheckoutIdView.pact.js +0 -109
  199. package/dist/src/infrastructure/projection/payment/paymentFlowPayload.mock.d.ts +0 -6
  200. package/dist/src/infrastructure/projection/payment/paymentFlowPayload.mock.js +0 -183
  201. package/dist/src/infrastructure/projection/pricing/httpPricingByCheckoutIdView.pact.d.ts +0 -1
  202. package/dist/src/infrastructure/projection/pricing/httpPricingByCheckoutIdView.pact.js +0 -48
  203. package/dist/src/infrastructure/projection/pricing/pricing.mock.d.ts +0 -9
  204. package/dist/src/infrastructure/projection/pricing/pricing.mock.js +0 -42
  205. package/dist/src/infrastructure/projection/returnQuestion/httpReturnQuestionsByCheckoutItemIdView.pact.d.ts +0 -1
  206. package/dist/src/infrastructure/projection/returnQuestion/httpReturnQuestionsByCheckoutItemIdView.pact.js +0 -48
  207. package/dist/src/infrastructure/projection/returnQuestion/returnQuestions.mock.d.ts +0 -3
  208. package/dist/src/infrastructure/projection/returnQuestion/returnQuestions.mock.js +0 -400
  209. package/dist/src/infrastructure/ui/views/App.style.d.ts +0 -6
  210. package/dist/src/infrastructure/ui/views/App.style.js +0 -7
  211. package/pact.config.ts +0 -31
  212. package/pact.publish.js +0 -32
  213. package/src/infrastructure/projection/bookedProductsVariants/httpBookedProductsVariantsForCheckoutItemView.pact.ts +0 -62
  214. package/src/infrastructure/projection/checkout/httpCheckoutByIdView.pact.ts +0 -128
  215. package/src/infrastructure/projection/checkout/httpFirstAvailableCheckoutByCustomerIdView.pact.ts +0 -63
  216. package/src/infrastructure/projection/checkout/httpFiveItemsDiscountByCustomerIdView.pact.ts +0 -57
  217. package/src/infrastructure/projection/checkout/httpIsCheckoutEnabledByCustomerIdView.pact.ts +0 -57
  218. package/src/infrastructure/projection/checkout/httpIsSizeChangeEnabledByCheckoutIdView.pact.ts +0 -57
  219. package/src/infrastructure/projection/checkoutBooking/httpCheckoutBookingByIdView.pact.ts +0 -63
  220. package/src/infrastructure/projection/checkoutItem/httpCheckoutItemByIdView.pact.ts +0 -64
  221. package/src/infrastructure/projection/checkoutQuestion/httpCheckoutQuestionsByCheckoutIdView.pact.ts +0 -62
  222. package/src/infrastructure/projection/payment/httpPaymentFlowPayloadByCheckoutIdView.pact.ts +0 -136
  223. package/src/infrastructure/projection/pricing/httpPricingByCheckoutIdView.pact.ts +0 -62
  224. package/src/infrastructure/projection/returnQuestion/httpReturnQuestionsByCheckoutItemIdView.pact.ts +0 -62
  225. package/src/infrastructure/ui/views/App.style.ts +0 -9
@@ -1,5 +1,9 @@
1
1
  import { FeedbackProjection } from "../../../../../../projection/feedback/feedback";
2
2
  import { ReturnQuestionProjection } from "../../../../../../projection/returnQuestion/returnQuestion";
3
+ import {
4
+ returnQuestionHasChildren,
5
+ returnQuestionWithTranslationKey,
6
+ } from "../../../../../../projection/returnQuestion/returnQuestion.typeguard";
3
7
 
4
8
  type Uuid = string;
5
9
 
@@ -32,14 +36,16 @@ const feedbackForReturnQuestion: RecursiveFeedbackForReturnQuestionFunction = ({
32
36
  const returnQuestionFeedback = feedback[returnQuestionId];
33
37
 
34
38
  if (isUuid(returnQuestionFeedback as string)) {
35
- const feebackReturnQuestionChild = returnQuestion.children?.find(
36
- (childReturnQuestion) => childReturnQuestion.id === returnQuestionFeedback,
37
- );
39
+ const feebackReturnQuestionChild =
40
+ returnQuestionHasChildren(returnQuestion) &&
41
+ returnQuestion.children?.find((childReturnQuestion) => childReturnQuestion.id === returnQuestionFeedback);
38
42
 
39
43
  if (feebackReturnQuestionChild) {
40
44
  return [
41
45
  ...acc,
42
- translate(feebackReturnQuestionChild?.name),
46
+ ...(returnQuestionWithTranslationKey(feebackReturnQuestionChild)
47
+ ? [translate(feebackReturnQuestionChild.translationKey)]
48
+ : []),
43
49
  ...feedbackForReturnQuestion({ feedback, returnQuestion: feebackReturnQuestionChild, translate, acc }),
44
50
  ];
45
51
  }
@@ -51,13 +57,15 @@ const feedbackForReturnQuestion: RecursiveFeedbackForReturnQuestionFunction = ({
51
57
  }
52
58
 
53
59
  return (
54
- returnQuestion.children?.reduce(
55
- (acc, childReturnQuestion) => [
56
- ...acc,
57
- ...feedbackForReturnQuestion({ feedback, returnQuestion: childReturnQuestion, translate, acc }),
58
- ],
59
- [] as string[],
60
- ) || []
60
+ (returnQuestionHasChildren(returnQuestion) &&
61
+ returnQuestion.children?.reduce(
62
+ (acc, childReturnQuestion) => [
63
+ ...acc,
64
+ ...feedbackForReturnQuestion({ feedback, returnQuestion: childReturnQuestion, translate, acc }),
65
+ ],
66
+ [] as string[],
67
+ )) ||
68
+ []
61
69
  );
62
70
  };
63
71
 
@@ -84,9 +92,9 @@ const deepestReturnQuestionWithFeedbackForReturnQuestion: RecursiveDeepestReturn
84
92
  const returnQuestionFeedback = feedback[returnQuestionId];
85
93
 
86
94
  if (isUuid(returnQuestionFeedback as string)) {
87
- const feebackReturnQuestionChild = returnQuestion.children?.find(
88
- (childReturnQuestion) => childReturnQuestion.id === returnQuestionFeedback,
89
- );
95
+ const feebackReturnQuestionChild =
96
+ returnQuestionHasChildren(returnQuestion) &&
97
+ returnQuestion.children?.find((childReturnQuestion) => childReturnQuestion.id === returnQuestionFeedback);
90
98
 
91
99
  if (feebackReturnQuestionChild) {
92
100
  return deepestReturnQuestionWithFeedbackForReturnQuestion({
@@ -102,9 +110,11 @@ const deepestReturnQuestionWithFeedbackForReturnQuestion: RecursiveDeepestReturn
102
110
  return [returnQuestion, false];
103
111
  }
104
112
 
105
- const feebackReturnQuestionChild = returnQuestion.children?.find((childReturnQuestion) =>
106
- Object.keys(feedback).find((id) => id === childReturnQuestion.id),
107
- );
113
+ const feebackReturnQuestionChild =
114
+ returnQuestionHasChildren(returnQuestion) &&
115
+ returnQuestion.children?.find((childReturnQuestion) =>
116
+ Object.keys(feedback).find((id) => id === childReturnQuestion.id),
117
+ );
108
118
 
109
119
  if (feebackReturnQuestionChild) {
110
120
  return deepestReturnQuestionWithFeedbackForReturnQuestion({
@@ -114,7 +124,11 @@ const deepestReturnQuestionWithFeedbackForReturnQuestion: RecursiveDeepestReturn
114
124
  });
115
125
  }
116
126
 
117
- return [deepestReturnQuestion, !returnQuestion.children || returnQuestion.children.length === 0];
127
+ const hasChildren = Boolean(
128
+ returnQuestionHasChildren(returnQuestion) && returnQuestion.children && returnQuestion.children.length > 0,
129
+ );
130
+
131
+ return [deepestReturnQuestion, !hasChildren];
118
132
  };
119
133
 
120
134
  export { feedbackForReturnQuestion, deepestReturnQuestionWithFeedbackForReturnQuestion };
@@ -1,5 +1,4 @@
1
1
  import React, { FC, memo, Suspense } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { Navigate, Outlet, useRoutes as reactRouterUseRoutes } from "react-router-native";
4
3
  import { Spinner } from "@lookiero/aurora";
5
4
  import { I18n } from "@lookiero/i18n-react";
@@ -11,7 +10,7 @@ import { Order } from "../../../projection/order/order";
11
10
  import { Subscription } from "../../../projection/subscription/subscription";
12
11
  import { KameleoonEnvironment } from "../../ab-testing/kameleoonEnvironment";
13
12
  import { StaticInfoProvider } from "../hooks/useStaticInfo";
14
- import { App, AppStyle } from "../views/App";
13
+ import { App } from "../views/App";
15
14
  import { Checkout } from "../views/checkout/Checkout";
16
15
  import { CheckoutPaymentModal } from "../views/checkout/components/checkoutPaymentModal/CheckoutPaymentModal";
17
16
  import { Feedback } from "../views/feedback/Feedback";
@@ -23,10 +22,6 @@ import { CheckoutMiddleware } from "./CheckoutMiddleware";
23
22
  import { Routes } from "./routes";
24
23
  import { BasePathProvider } from "./useBasePath";
25
24
 
26
- interface RoutingStyle extends AppStyle {
27
- readonly modal: StyleProp<ViewStyle>;
28
- }
29
-
30
25
  interface RoutingProps {
31
26
  readonly basePath?: string;
32
27
  readonly customer: Customer;
@@ -36,7 +31,6 @@ interface RoutingProps {
36
31
  readonly I18n: I18n;
37
32
  readonly kameleoon: KameleoonEnvironment;
38
33
  readonly layout: Layout;
39
- readonly style?: Partial<RoutingStyle>;
40
34
  readonly getAuthToken: () => Promise<string>;
41
35
  readonly onNotAccessible: () => void;
42
36
  readonly onCheckoutSubmitted?: () => void;
@@ -54,7 +48,6 @@ const Routing: FC<RoutingProps> = ({
54
48
  I18n,
55
49
  kameleoon,
56
50
  layout,
57
- style: customStyle,
58
51
  getAuthToken,
59
52
  onI18nError,
60
53
  onNotAccessible,
@@ -71,7 +64,7 @@ const Routing: FC<RoutingProps> = ({
71
64
  <I18n loader={<Spinner />} locale={locale} onError={onI18nError}>
72
65
  <Kameleoon loader={<Spinner />} siteCode={kameleoon.siteCode}>
73
66
  <CheckoutMiddleware customerId={customer?.customerId as string} onNotAccessible={onNotAccessible}>
74
- <App style={{ container: customStyle?.container, notifications: customStyle?.notifications }}>
67
+ <App>
75
68
  <Outlet />
76
69
  </App>
77
70
  </CheckoutMiddleware>
@@ -85,7 +78,7 @@ const Routing: FC<RoutingProps> = ({
85
78
  path: Routes.ITEM,
86
79
  element: (
87
80
  <Suspense fallback={<Spinner />}>
88
- <Item layout={layout} style={{ modal: customStyle?.modal }} />
81
+ <Item layout={layout} />
89
82
  </Suspense>
90
83
  ),
91
84
  },
@@ -93,7 +86,7 @@ const Routing: FC<RoutingProps> = ({
93
86
  path: Routes.ITEM_DETAIL,
94
87
  element: (
95
88
  <Suspense fallback={<Spinner />}>
96
- <Item layout={layout} style={{ modal: customStyle?.modal }} />
89
+ <Item layout={layout} />
97
90
  </Suspense>
98
91
  ),
99
92
  },
@@ -154,7 +147,7 @@ const Routing: FC<RoutingProps> = ({
154
147
  path: Routes.RETURN,
155
148
  element: (
156
149
  <Suspense fallback={<Spinner />}>
157
- <Return layout={layout} style={{ modal: customStyle?.modal }} />
150
+ <Return layout={layout} />
158
151
  </Suspense>
159
152
  ),
160
153
  },
@@ -175,4 +168,3 @@ const Routing: FC<RoutingProps> = ({
175
168
  */
176
169
  const MemoizedRouting = memo(Routing);
177
170
  export { MemoizedRouting as Routing };
178
- export type { RoutingStyle };
@@ -1,42 +1,32 @@
1
1
  import { PortalProvider } from "@gorhom/portal";
2
2
  import React, { FC } from "react";
3
- import { StatusBar, StyleProp, View, ViewStyle } from "react-native";
3
+ import { StatusBar } from "react-native";
4
4
  import { SafeAreaProvider } from "react-native-safe-area-context";
5
5
  import { PortalProvider as AuroraPortalProvider } from "@lookiero/aurora";
6
- import { Notifications, NotificationsStyle } from "@lookiero/sty-psp-notifications";
6
+ import { Notifications } from "@lookiero/sty-psp-notifications";
7
7
  import { theme } from "@lookiero/sty-psp-ui";
8
8
  import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
9
- import { style } from "./App.style";
10
9
 
11
10
  const { colorBgBase } = theme();
12
11
 
13
- interface AppStyle {
14
- readonly container: StyleProp<ViewStyle>;
15
- readonly notifications: Partial<NotificationsStyle>;
16
- }
17
-
18
12
  interface AppProps {
19
13
  readonly children: JSX.Element;
20
- readonly style?: Partial<AppStyle>;
21
14
  }
22
15
 
23
- const App: FC<AppProps> = ({ children, style: customStyle }) => (
24
- <View style={[style.container, customStyle?.container]}>
25
- <SafeAreaProvider>
26
- <PortalProvider>
27
- <StatusBar backgroundColor={colorBgBase} barStyle="dark-content" translucent />
28
- <Notifications contextId={MESSAGING_CONTEXT_ID} style={customStyle?.notifications} />
29
- {/*
16
+ const App: FC<AppProps> = ({ children }) => (
17
+ <SafeAreaProvider>
18
+ <PortalProvider>
19
+ <StatusBar backgroundColor={colorBgBase} barStyle="dark-content" translucent />
20
+ <Notifications contextId={MESSAGING_CONTEXT_ID} />
21
+ {/*
30
22
  We are using the Aurora's PortalProvider at this level for notifications to work properly.
31
23
 
32
24
  PaymentInstrumentSelect uses Aurora's Portal, and if we rely on UAF's Portal (injected by <Aurora>)
33
25
  notifications would be displayed in a layer below Portal's one (not visible).
34
26
  */}
35
- <AuroraPortalProvider>{children}</AuroraPortalProvider>
36
- </PortalProvider>
37
- </SafeAreaProvider>
38
- </View>
27
+ <AuroraPortalProvider>{children}</AuroraPortalProvider>
28
+ </PortalProvider>
29
+ </SafeAreaProvider>
39
30
  );
40
31
 
41
- export type { AppStyle };
42
32
  export { App };
@@ -1,5 +1,4 @@
1
1
  import React, { FC, useCallback, useEffect, useMemo, useRef } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { generatePath, useMatch, useNavigate, useParams } from "react-router-native";
4
3
  import { Box, Spinner } from "@lookiero/aurora";
5
4
  import { QueryStatus } from "@lookiero/messaging-react";
@@ -55,16 +54,11 @@ interface HandleOnPreviousFunction {
55
54
  (args: HandleOnPreviousFunctionArgs): void;
56
55
  }
57
56
 
58
- interface ItemStyle {
59
- readonly modal: StyleProp<ViewStyle>;
60
- }
61
-
62
57
  interface ItemProps {
63
58
  readonly layout: Layout;
64
- readonly style?: Partial<ItemStyle>;
65
59
  }
66
60
 
67
- const Item: FC<ItemProps> = ({ layout: Layout, style: customStyle }) => {
61
+ const Item: FC<ItemProps> = ({ layout: Layout }) => {
68
62
  const logger = useLogger();
69
63
  const screenSize = useScreenSize();
70
64
  const navigate = useNavigate();
@@ -224,6 +218,7 @@ const Item: FC<ItemProps> = ({ layout: Layout, style: customStyle }) => {
224
218
  return (
225
219
  <ReturnQuestionFeedbackProvider key={checkoutItem.id} feedback={checkoutItem.feedbacks || {}}>
226
220
  <Layout
221
+ footer={null}
227
222
  header={header}
228
223
  scrollEnabled={!itemWithoutCustomerDecission}
229
224
  style={{
@@ -238,7 +233,6 @@ const Item: FC<ItemProps> = ({ layout: Layout, style: customStyle }) => {
238
233
  checkoutId={checkout.id}
239
234
  checkoutItem={checkoutItem as CheckoutItemWithoutCustomerDecission}
240
235
  currentProductVariant={currentProductVariant}
241
- style={customStyle}
242
236
  onReturn={goToReturnPage}
243
237
  />
244
238
  ) : (
@@ -17,7 +17,7 @@ const style = StyleSheet.create({
17
17
  marginVertical: space8,
18
18
  width: "100%",
19
19
  },
20
- modal: {
20
+ modalContent: {
21
21
  paddingHorizontal: space6,
22
22
  },
23
23
  title: {
@@ -1,5 +1,5 @@
1
1
  import React, { FC } from "react";
2
- import { StyleProp, View, ViewStyle } from "react-native";
2
+ import { View } from "react-native";
3
3
  import { ALIGN, Button, BUTTON_VARIANT, Text } from "@lookiero/aurora";
4
4
  import { useI18nMessage } from "@lookiero/i18n-react";
5
5
  import { Modal } from "@lookiero/sty-psp-ui";
@@ -8,16 +8,10 @@ import { style } from "./GetOutOfCheckoutModal.style";
8
8
 
9
9
  interface GetOutOfCheckoutModalProps {
10
10
  readonly visible: boolean;
11
- readonly style?: StyleProp<ViewStyle>;
12
11
  readonly onDismiss: () => void;
13
12
  readonly onConfirm: () => void;
14
13
  }
15
- const GetOutOfCheckoutModal: FC<GetOutOfCheckoutModalProps> = ({
16
- visible,
17
- style: customStyle,
18
- onDismiss,
19
- onConfirm,
20
- }) => {
14
+ const GetOutOfCheckoutModal: FC<GetOutOfCheckoutModalProps> = ({ visible, onDismiss, onConfirm }) => {
21
15
  const titleText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_TITLE });
22
16
  const descriptionText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_DESCRIPTION });
23
17
  const dismissButtonText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_DISMISS_BUTTON });
@@ -25,7 +19,7 @@ const GetOutOfCheckoutModal: FC<GetOutOfCheckoutModalProps> = ({
25
19
 
26
20
  return (
27
21
  <Modal visible={visible} onClose={onDismiss}>
28
- <View style={[style.modal, customStyle]}>
22
+ <View style={style.modalContent}>
29
23
  <Text align={ALIGN.CENTER} level={1} style={style.title}>
30
24
  {titleText}
31
25
  </Text>
@@ -76,6 +76,7 @@ exports[`GetOutOfCheckoutModal component matches the snapshot 1`] = `
76
76
  "zIndex": 1,
77
77
  }
78
78
  }
79
+ testID="modal-close-button"
79
80
  />
80
81
  <View
81
82
  pointerEvents="box-none"
@@ -132,6 +133,12 @@ exports[`GetOutOfCheckoutModal component matches the snapshot 1`] = `
132
133
  }
133
134
  >
134
135
  <View
136
+ contentInset={
137
+ {
138
+ "bottom": 0,
139
+ "top": 0,
140
+ }
141
+ }
135
142
  keyboardShouldPersistTaps="handled"
136
143
  showsVerticalScrollIndicator={false}
137
144
  >
@@ -1,5 +1,5 @@
1
1
  import React, { FC, useCallback, useMemo, useState } from "react";
2
- import { LayoutRectangle, StyleProp, View, ViewStyle } from "react-native";
2
+ import { LayoutRectangle, View } from "react-native";
3
3
  import { Button, BUTTON_VARIANT } from "@lookiero/aurora";
4
4
  import { useI18nMessage } from "@lookiero/i18n-react";
5
5
  import { Country } from "@lookiero/sty-psp-locale";
@@ -11,15 +11,10 @@ import { I18nMessages } from "../../../../i18n/i18n";
11
11
  import { SelectModal } from "../selectModal/SelectModal";
12
12
  import { style } from "./ItemActions.style";
13
13
 
14
- interface ItemActionsStyle {
15
- readonly modal: StyleProp<ViewStyle>;
16
- }
17
-
18
14
  interface ItemActionsProps {
19
15
  readonly productVariants?: ProductVariantProjection[];
20
16
  readonly currentProductVariant: ProductVariantProjection;
21
17
  readonly country: Country;
22
- readonly style?: Partial<ItemActionsStyle>;
23
18
  readonly onShowSizeWithoutStockModal?: () => void;
24
19
  readonly onKeep: () => void;
25
20
  readonly onReturn: () => void;
@@ -30,7 +25,6 @@ const ItemActions: FC<ItemActionsProps> = ({
30
25
  productVariants,
31
26
  currentProductVariant,
32
27
  country,
33
- style: customStyle,
34
28
  onShowSizeWithoutStockModal = () => void 0,
35
29
  onKeep,
36
30
  onReplace,
@@ -102,7 +96,6 @@ const ItemActions: FC<ItemActionsProps> = ({
102
96
  <SelectModal
103
97
  modalVisible={modalVisible}
104
98
  options={sizeSelectorOptions}
105
- style={{ modal: customStyle?.modal }}
106
99
  testID="select-field-modal"
107
100
  title={changeSizeButtonText}
108
101
  value={currentProductVariant.id}
@@ -1,11 +1,9 @@
1
1
  import React, { FC } from "react";
2
- import { StyleProp, View, ViewStyle } from "react-native";
2
+ import { View } from "react-native";
3
3
  import { ButtonIcon, Text } from "@lookiero/aurora";
4
4
  import { useI18nMessage } from "@lookiero/i18n-react";
5
- import {
6
- ReturnQuestionProjection,
7
- ReturnQuestionType,
8
- } from "../../../../../../projection/returnQuestion/returnQuestion";
5
+ import { ReturnQuestionProjection } from "../../../../../../projection/returnQuestion/returnQuestion";
6
+ import { ReturnQuestionType } from "../../../../../../projection/returnQuestion/returnQuestion.constants";
9
7
  import { ReturnQuestions } from "../../../../components/organisms/returnQuestions/ReturnQuestions";
10
8
  import {
11
9
  ReturnQuestionItemProvider,
@@ -25,21 +23,12 @@ const returnQuestionItems: ReturnQuestionItems = {
25
23
  [ReturnQuestionType.OPTION]: ReturnQuestionFeedbackItem,
26
24
  };
27
25
 
28
- interface ReturnQuestionsFeedbackStyle {
29
- readonly modal: StyleProp<ViewStyle>;
30
- }
31
-
32
26
  interface ReturnQuestionsFeedbackProps {
33
27
  readonly returnQuestions: ReturnQuestionProjection[];
34
- readonly style?: Partial<ReturnQuestionsFeedbackStyle>;
35
28
  readonly onEditFeedback: () => void;
36
29
  }
37
30
 
38
- const ReturnQuestionsFeedback: FC<ReturnQuestionsFeedbackProps> = ({
39
- returnQuestions,
40
- style: customStyle,
41
- onEditFeedback,
42
- }) => {
31
+ const ReturnQuestionsFeedback: FC<ReturnQuestionsFeedbackProps> = ({ returnQuestions, onEditFeedback }) => {
43
32
  const titleText = useI18nMessage({ id: I18nMessages.FEEDBACK_TITLE });
44
33
 
45
34
  return (
@@ -50,7 +39,7 @@ const ReturnQuestionsFeedback: FC<ReturnQuestionsFeedbackProps> = ({
50
39
  </View>
51
40
 
52
41
  <ReturnQuestionItemProvider returnQuestionItems={returnQuestionItems}>
53
- <ReturnQuestions returnQuestions={returnQuestions} style={customStyle} />
42
+ <ReturnQuestions returnQuestions={returnQuestions} />
54
43
  </ReturnQuestionItemProvider>
55
44
  </View>
56
45
  );
@@ -4,7 +4,7 @@ import { theme } from "@lookiero/sty-psp-ui";
4
4
  const { borderWidth1, colorBorderInteractive, space1, space5, space6 } = theme();
5
5
 
6
6
  const style = StyleSheet.create({
7
- modal: {
7
+ modalContent: {
8
8
  paddingBottom: space6,
9
9
  paddingHorizontal: space6,
10
10
  },
@@ -7,7 +7,7 @@ import { style } from "./SelectModal.style";
7
7
  const { colorBgPrimaryLight } = theme();
8
8
 
9
9
  interface SelectModalStyle {
10
- readonly modal: StyleProp<ViewStyle>;
10
+ readonly modalContent: StyleProp<ViewStyle>;
11
11
  readonly option: StyleProp<ViewStyle>;
12
12
  readonly optionText: StyleProp<TextStyle>;
13
13
  }
@@ -22,21 +22,21 @@ interface SelectModalProps {
22
22
  readonly value: string | undefined;
23
23
  readonly options: Option[];
24
24
  readonly style?: Partial<SelectModalStyle>;
25
- readonly modalVisible: boolean;
26
- readonly testID?: string;
27
25
  readonly onChange?: (value: string) => void;
28
26
  readonly onClose?: () => void;
27
+ readonly modalVisible: boolean;
28
+ readonly testID?: string;
29
29
  }
30
30
 
31
31
  const SelectModal: FC<SelectModalProps> = ({
32
32
  modalVisible,
33
+ onChange = () => void 0,
34
+ onClose = () => void 0,
33
35
  options,
34
36
  style: customStyle,
35
37
  testID,
36
38
  title,
37
39
  value,
38
- onChange = () => void 0,
39
- onClose = () => void 0,
40
40
  }) => {
41
41
  const handleOnPressOption = useCallback(
42
42
  (value: string) => {
@@ -48,7 +48,7 @@ const SelectModal: FC<SelectModalProps> = ({
48
48
 
49
49
  return (
50
50
  <Modal testID={testID} visible={modalVisible} scroll showCloseButton onClose={onClose}>
51
- <View style={[style.modal, customStyle?.modal]}>
51
+ <View style={[style.modalContent, customStyle?.modalContent]}>
52
52
  {title && (
53
53
  <Text level={3} style={style.modalTitle} heading>
54
54
  {title}
@@ -76,6 +76,7 @@ exports[`SelectField component matches the snapshot 1`] = `
76
76
  "zIndex": 1,
77
77
  }
78
78
  }
79
+ testID="modal-close-button"
79
80
  />
80
81
  <View
81
82
  pointerEvents="box-none"
@@ -206,6 +207,12 @@ exports[`SelectField component matches the snapshot 1`] = `
206
207
  </View>
207
208
  </View>
208
209
  <RCTScrollView
210
+ contentInset={
211
+ {
212
+ "bottom": 0,
213
+ "top": 0,
214
+ }
215
+ }
209
216
  keyboardShouldPersistTaps="handled"
210
217
  showsVerticalScrollIndicator={false}
211
218
  >
@@ -1,5 +1,5 @@
1
1
  import React, { FC } from "react";
2
- import { StyleProp, View, ViewStyle } from "react-native";
2
+ import { View } from "react-native";
3
3
  import { Button, Text } from "@lookiero/aurora";
4
4
  import { useI18nMessage } from "@lookiero/i18n-react";
5
5
  import { Modal } from "@lookiero/sty-psp-ui";
@@ -8,17 +8,16 @@ import { style } from "./SizeWithoutStockModal.style";
8
8
 
9
9
  interface SizeWithoutStockModalProps {
10
10
  readonly visible: boolean;
11
- readonly style?: StyleProp<ViewStyle>;
12
11
  readonly onDismiss: () => void;
13
12
  }
14
- const SizeWithoutStockModal: FC<SizeWithoutStockModalProps> = ({ visible, style: customStyle, onDismiss }) => {
13
+ const SizeWithoutStockModal: FC<SizeWithoutStockModalProps> = ({ visible, onDismiss }) => {
15
14
  const titleText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_TITLE });
16
15
  const descriptionText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_DESCRIPTION });
17
16
  const buttonText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_BUTTON });
18
17
 
19
18
  return (
20
19
  <Modal visible={visible} showCloseButton onClose={onDismiss}>
21
- <View style={[style.modalContent, customStyle]}>
20
+ <View style={style.modalContent}>
22
21
  <Text level={3} style={style.title} heading>
23
22
  {titleText}
24
23
  </Text>
@@ -76,6 +76,7 @@ exports[`SizeWithoutStockModal component matches the snapshot 1`] = `
76
76
  "zIndex": 1,
77
77
  }
78
78
  }
79
+ testID="modal-close-button"
79
80
  />
80
81
  <View
81
82
  pointerEvents="box-none"
@@ -206,6 +207,12 @@ exports[`SizeWithoutStockModal component matches the snapshot 1`] = `
206
207
  </View>
207
208
  </View>
208
209
  <View
210
+ contentInset={
211
+ {
212
+ "bottom": 0,
213
+ "top": 0,
214
+ }
215
+ }
209
216
  keyboardShouldPersistTaps="handled"
210
217
  showsVerticalScrollIndicator={false}
211
218
  >
@@ -1,5 +1,5 @@
1
1
  import React, { FC, useCallback } from "react";
2
- import { StyleProp, View, ViewStyle } from "react-native";
2
+ import { View } from "react-native";
3
3
  import { Spinner } from "@lookiero/aurora";
4
4
  import { CommandStatus } from "@lookiero/messaging-react";
5
5
  import { useLogger } from "@lookiero/sty-psp-logging";
@@ -21,10 +21,6 @@ import { ReturnQuestionsFeedback } from "../../components/returnQuestionsFeedbac
21
21
  import { ProductVariant } from "../../views/productVariant/ProductVariant";
22
22
  import { style } from "./ItemWithCustomerDecission.style";
23
23
 
24
- interface ItemWithCustomerDecissionStyle {
25
- readonly modal: StyleProp<ViewStyle>;
26
- }
27
-
28
24
  interface CheckoutItemWithCustomerDecission extends CheckoutItemProjection {
29
25
  readonly status: Exclude<CheckoutItemStatus, CheckoutItemStatus.INITIAL>;
30
26
  }
@@ -34,7 +30,6 @@ interface ItemWithCustomerDecissionProps {
34
30
  readonly checkoutItem: CheckoutItemWithCustomerDecission;
35
31
  readonly returnQuestions: ReturnQuestionProjection[];
36
32
  readonly currentProductVariant: ProductVariantProjection;
37
- readonly style?: Partial<ItemWithCustomerDecissionStyle>;
38
33
  readonly onEditFeedback: () => void;
39
34
  }
40
35
 
@@ -43,7 +38,6 @@ const ItemWithCustomerDecission: FC<ItemWithCustomerDecissionProps> = ({
43
38
  checkoutItem,
44
39
  returnQuestions,
45
40
  currentProductVariant,
46
- style: customStyle,
47
41
  onEditFeedback,
48
42
  }) => {
49
43
  const screenSize = useScreenSize();
@@ -94,11 +88,7 @@ const ItemWithCustomerDecission: FC<ItemWithCustomerDecissionProps> = ({
94
88
  >
95
89
  {checkoutItem.status === CheckoutItemStatus.RETURNED && (
96
90
  <View style={[style.feedbackContainer, isMobile ? style.feedbackContainerMobile : undefined]}>
97
- <ReturnQuestionsFeedback
98
- returnQuestions={returnQuestions}
99
- style={customStyle}
100
- onEditFeedback={onEditFeedback}
101
- />
91
+ <ReturnQuestionsFeedback returnQuestions={returnQuestions} onEditFeedback={onEditFeedback} />
102
92
  </View>
103
93
  )}
104
94
  </ProductVariant>
@@ -1,5 +1,5 @@
1
1
  import React, { FC, useCallback, useState } from "react";
2
- import { LayoutRectangle, Platform, ScrollView, StyleProp, ViewStyle } from "react-native";
2
+ import { LayoutRectangle, Platform, ScrollView } from "react-native";
3
3
  import { Spinner } from "@lookiero/aurora";
4
4
  import { CommandStatus } from "@lookiero/messaging-react";
5
5
  import { useLogger } from "@lookiero/sty-psp-logging";
@@ -23,12 +23,6 @@ import { SizeWithoutStockModal } from "../../components/sizeWithoutStockModal/Si
23
23
  import { ProductVariant } from "../productVariant/ProductVariant";
24
24
  import { style } from "./ItemWithoutCustomerDecission.style";
25
25
 
26
- const { space6 } = theme();
27
-
28
- interface ItemWithoutCustomerDecissionStyle {
29
- readonly modal: StyleProp<ViewStyle>;
30
- }
31
-
32
26
  interface CheckoutItemWithoutCustomerDecission extends CheckoutItemProjection {
33
27
  readonly status: CheckoutItemStatus.INITIAL;
34
28
  }
@@ -38,16 +32,16 @@ interface ItemWithoutCustomerDecissionProps {
38
32
  readonly checkoutItem: CheckoutItemWithoutCustomerDecission;
39
33
  readonly bookedProductsVariants: BookedProductsVariantsProjection;
40
34
  readonly currentProductVariant: ProductVariantProjection;
41
- readonly style?: Partial<ItemWithoutCustomerDecissionStyle>;
42
35
  readonly onReturn: () => void;
43
36
  }
44
37
 
38
+ const { space6 } = theme();
39
+
45
40
  const ItemWithoutCustomerDecission: FC<ItemWithoutCustomerDecissionProps> = ({
46
41
  checkoutId,
47
42
  checkoutItem,
48
43
  bookedProductsVariants,
49
44
  currentProductVariant,
50
- style: customStyle,
51
45
  onReturn,
52
46
  }) => {
53
47
  const logger = useLogger();
@@ -108,11 +102,7 @@ const ItemWithoutCustomerDecission: FC<ItemWithoutCustomerDecissionProps> = ({
108
102
 
109
103
  return (
110
104
  <>
111
- <SizeWithoutStockModal
112
- style={customStyle?.modal}
113
- visible={sizeWithoutStockModalVisible}
114
- onDismiss={handleOnHideSizeWithoutStockModal}
115
- />
105
+ <SizeWithoutStockModal visible={sizeWithoutStockModalVisible} onDismiss={handleOnHideSizeWithoutStockModal} />
116
106
 
117
107
  <ScrollView showsVerticalScrollIndicator={false}>
118
108
  <Body style={{ row: style.container }}>