@lookiero/checkout 2.3.0 → 2.4.1-beta.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 (86) hide show
  1. package/dist/domain/checkout/model/checkoutStarted.d.ts +3 -2
  2. package/dist/domain/checkout/model/checkoutStarted.js +2 -1
  3. package/dist/domain/checkout/model/checkoutSubmitted.d.ts +3 -2
  4. package/dist/domain/checkout/model/checkoutSubmitted.js +2 -1
  5. package/dist/domain/checkoutBooking/event/createNotificationWhenCheckoutBookingExpired.d.ts +6 -0
  6. package/dist/domain/checkoutBooking/event/createNotificationWhenCheckoutBookingExpired.js +13 -0
  7. package/dist/domain/checkoutBooking/model/checkoutBookingBooked.d.ts +3 -2
  8. package/dist/domain/checkoutBooking/model/checkoutBookingBooked.js +2 -1
  9. package/dist/domain/checkoutBooking/model/checkoutBookingExpired.d.ts +3 -2
  10. package/dist/domain/checkoutBooking/model/checkoutBookingExpired.js +2 -1
  11. package/dist/domain/checkoutFeedback/model/checkoutFeedbackGiven.d.ts +3 -2
  12. package/dist/domain/checkoutFeedback/model/checkoutFeedbackGiven.js +2 -1
  13. package/dist/domain/checkoutItem/model/checkoutItemKept.d.ts +3 -2
  14. package/dist/domain/checkoutItem/model/checkoutItemKept.js +2 -1
  15. package/dist/domain/checkoutItem/model/checkoutItemReplaced.d.ts +3 -2
  16. package/dist/domain/checkoutItem/model/checkoutItemReplaced.js +2 -1
  17. package/dist/domain/checkoutItem/model/checkoutItemReset.d.ts +3 -2
  18. package/dist/domain/checkoutItem/model/checkoutItemReset.js +2 -1
  19. package/dist/domain/checkoutItem/model/checkoutItemReturned.d.ts +3 -2
  20. package/dist/domain/checkoutItem/model/checkoutItemReturned.js +2 -1
  21. package/dist/domain/uiSetting/model/uiSettingUpdated.d.ts +3 -2
  22. package/dist/domain/uiSetting/model/uiSettingUpdated.js +2 -1
  23. package/dist/infrastructure/domain/uiSetting/react/useIncrementIntroShownCount.d.ts +10 -0
  24. package/dist/infrastructure/domain/uiSetting/react/useIncrementIntroShownCount.js +11 -0
  25. package/dist/infrastructure/projection/bookedProductsVariants/react/useViewBookedProductsVariantsForCheckoutItem.js +2 -4
  26. package/dist/infrastructure/projection/checkout/react/useViewFirstAvailableCheckoutByCustomerId.js +9 -18
  27. package/dist/infrastructure/projection/checkout/react/useViewIsCheckoutAccessibleByCustomerId.js +1 -2
  28. package/dist/infrastructure/projection/payment/react/useViewPaymentFlowPayloadByCheckoutId.js +4 -8
  29. package/dist/infrastructure/projection/pricing/react/useViewPricingByCheckoutId.js +4 -8
  30. package/dist/infrastructure/projection/uiSetting/react/useShouldIntroBeShown.d.ts +6 -0
  31. package/dist/infrastructure/projection/uiSetting/react/useShouldIntroBeShown.js +7 -0
  32. package/dist/infrastructure/projection/uiSetting/react/useViewIntroShownCount.d.ts +6 -0
  33. package/dist/infrastructure/projection/uiSetting/react/useViewIntroShownCount.js +9 -0
  34. package/dist/infrastructure/projection/uiSetting/react/useViewUiSettingByKey.js +1 -2
  35. package/dist/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.d.ts +2 -1
  36. package/dist/infrastructure/ui/components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem.js +1 -1
  37. package/dist/infrastructure/ui/components/templates/SafeAreaScrollView.js +3 -3
  38. package/dist/infrastructure/ui/hooks/usePaymentInstrumentEvents.js +7 -5
  39. package/dist/infrastructure/ui/hooks/usePaymentInstrumentUpdateEvents.d.ts +2 -0
  40. package/dist/infrastructure/ui/hooks/usePaymentInstrumentUpdateEvents.js +28 -0
  41. package/dist/infrastructure/ui/views/App.js +3 -1
  42. package/dist/infrastructure/ui/views/checkout/Checkout.style.d.ts +0 -1
  43. package/dist/infrastructure/ui/views/checkout/Checkout.style.js +0 -1
  44. package/dist/infrastructure/ui/views/checkout/components/checkoutSuccessModal/CheckoutSuccessModal.d.ts +7 -0
  45. package/dist/infrastructure/ui/views/checkout/components/checkoutSuccessModal/CheckoutSuccessModal.js +25 -0
  46. package/dist/infrastructure/ui/views/checkout/components/checkoutSuccessModal/CheckoutSuccessModal.style.d.ts +16 -0
  47. package/dist/infrastructure/ui/views/checkout/components/checkoutSuccessModal/CheckoutSuccessModal.style.js +19 -0
  48. package/dist/infrastructure/ui/views/intro/Intro.d.ts +6 -0
  49. package/dist/infrastructure/ui/views/intro/Intro.js +52 -0
  50. package/dist/infrastructure/ui/views/intro/Intro.style.d.ts +52 -0
  51. package/dist/infrastructure/ui/views/intro/Intro.style.js +55 -0
  52. package/dist/infrastructure/ui/views/item/Item.style.d.ts +15 -0
  53. package/dist/infrastructure/ui/views/item/Item.style.js +18 -0
  54. package/dist/infrastructure/ui/views/item/components/productVariant/ProductVariant.d.ts +26 -0
  55. package/dist/infrastructure/ui/views/item/components/productVariant/ProductVariant.js +44 -0
  56. package/dist/infrastructure/ui/views/item/components/productVariant/ProductVariant.style.d.ts +45 -0
  57. package/dist/infrastructure/ui/views/item/components/productVariant/ProductVariant.style.js +53 -0
  58. package/dist/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.js +2 -2
  59. package/dist/infrastructure/ui/views/item/components/sizeChangeModal/SizeChangeModal.d.ts +7 -0
  60. package/dist/infrastructure/ui/views/item/components/sizeChangeModal/SizeChangeModal.js +25 -0
  61. package/dist/infrastructure/ui/views/item/components/sizeChangeModal/SizeChangeModal.style.d.ts +16 -0
  62. package/dist/infrastructure/ui/views/item/components/sizeChangeModal/SizeChangeModal.style.js +19 -0
  63. package/dist/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.js +1 -3
  64. package/dist/infrastructure/ui/views/summary/Summary.js +1 -3
  65. package/dist/shared/notifications/domain/notification/command/createNotification.d.ts +17 -0
  66. package/dist/shared/notifications/domain/notification/command/createNotification.js +7 -0
  67. package/dist/shared/notifications/domain/notification/model/notificationCreated.d.ts +3 -2
  68. package/dist/shared/notifications/domain/notification/model/notificationCreated.js +2 -1
  69. package/dist/shared/notifications/domain/notification/model/notificationRemoved.d.ts +3 -2
  70. package/dist/shared/notifications/domain/notification/model/notificationRemoved.js +2 -1
  71. package/dist/shared/notifications/infrastructure/domain/notification/react/useCreateNotification.d.ts +21 -0
  72. package/dist/shared/notifications/infrastructure/domain/notification/react/useCreateNotification.js +22 -0
  73. package/dist/shared/notifications/infrastructure/ui/components/NotificationItem.d.ts +12 -0
  74. package/dist/shared/notifications/infrastructure/ui/components/NotificationItem.js +24 -0
  75. package/dist/shared/notifications/infrastructure/ui/components/Notifications.d.ts +9 -0
  76. package/dist/shared/notifications/infrastructure/ui/components/Notifications.js +20 -0
  77. package/dist/shared/notifications/infrastructure/ui/components/Notifications.style.d.ts +36 -0
  78. package/dist/shared/notifications/infrastructure/ui/components/Notifications.style.js +31 -0
  79. package/dist/shared/notifications/projection/notification/react/useListNotifications.js +2 -4
  80. package/dist/shared/tracking/infrastructure/usePageView.d.ts +13 -0
  81. package/dist/shared/tracking/infrastructure/usePageView.js +27 -0
  82. package/dist/shared/ui/components/atoms/error/Error.style.d.ts +6 -0
  83. package/dist/shared/ui/components/atoms/error/Error.style.js +9 -0
  84. package/dist/shared/ui/components/layouts/modal/Modal.d.ts +1 -0
  85. package/dist/shared/ui/components/layouts/modal/Modal.js +2 -2
  86. package/package.json +3 -3
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_STARTED = "checkout_started";
3
3
  interface CheckoutStartedPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutStartedFunction {
9
9
  (payload: CheckoutStartedPayload): CheckoutStarted;
10
10
  }
11
11
  declare const checkoutStarted: CheckoutStartedFunction;
12
+ declare const isCheckoutStarted: (event: DomainEvent<MessageName>) => event is CheckoutStarted;
12
13
  export type { CheckoutStarted };
13
- export { CHECKOUT_STARTED, checkoutStarted };
14
+ export { CHECKOUT_STARTED, checkoutStarted, isCheckoutStarted };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_STARTED = "checkout_started";
3
3
  const checkoutStarted = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_STARTED });
4
- export { CHECKOUT_STARTED, checkoutStarted };
4
+ const isCheckoutStarted = (event) => event.name === CHECKOUT_STARTED;
5
+ export { CHECKOUT_STARTED, checkoutStarted, isCheckoutStarted };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_SUBMITTED = "checkout_submitted";
3
3
  interface CheckoutSubmittedPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutSubmittedFunction {
9
9
  (payload: CheckoutSubmittedPayload): CheckoutSubmitted;
10
10
  }
11
11
  declare const checkoutSubmitted: CheckoutSubmittedFunction;
12
+ declare const isCheckoutSubmitted: (event: DomainEvent<MessageName>) => event is CheckoutSubmitted;
12
13
  export type { CheckoutSubmitted };
13
- export { CHECKOUT_SUBMITTED, checkoutSubmitted };
14
+ export { CHECKOUT_SUBMITTED, checkoutSubmitted, isCheckoutSubmitted };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_SUBMITTED = "checkout_submitted";
3
3
  const checkoutSubmitted = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_SUBMITTED });
4
- export { CHECKOUT_SUBMITTED, checkoutSubmitted };
4
+ const isCheckoutSubmitted = (event) => event.name === CHECKOUT_SUBMITTED;
5
+ export { CHECKOUT_SUBMITTED, checkoutSubmitted, isCheckoutSubmitted };
@@ -0,0 +1,6 @@
1
+ import { ProcessManagerFunction } from "@lookiero/messaging";
2
+ import { CheckoutBookingExpired } from "../model/checkoutBookingExpired";
3
+ interface CreateNotificationWhenCheckoutBookingExpiredFunction extends ProcessManagerFunction<CheckoutBookingExpired> {
4
+ }
5
+ declare const createNotificationWhenCheckoutBookingExpired: CreateNotificationWhenCheckoutBookingExpiredFunction;
6
+ export { createNotificationWhenCheckoutBookingExpired };
@@ -0,0 +1,13 @@
1
+ import { v4 as uuid } from "uuid";
2
+ import { I18nMessages } from "../../../infrastructure/ui/i18n/i18n";
3
+ import { createNotification } from "../../../shared/notifications/domain/notification/command/createNotification";
4
+ import { NotificationLevel } from "../../../shared/notifications/domain/notification/model/notification";
5
+ const createNotificationWhenCheckoutBookingExpired = ({ commandBus }) => async () => {
6
+ await commandBus(createNotification({
7
+ aggregateId: uuid(),
8
+ level: NotificationLevel.ERROR,
9
+ titleI18nKey: undefined,
10
+ bodyI18nKey: I18nMessages.CHECKOUT_TOAST_BOOKING_EXPIRED,
11
+ }));
12
+ };
13
+ export { createNotificationWhenCheckoutBookingExpired };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_BOOKING_BOOKED = "checkout_booking_booked";
3
3
  interface CheckoutBookingBookedPayload {
4
4
  readonly aggregateId: string;
@@ -10,5 +10,6 @@ interface CheckoutBookingBookedFunction {
10
10
  (payload: CheckoutBookingBookedPayload): CheckoutBookingBooked;
11
11
  }
12
12
  declare const checkoutBookingBooked: CheckoutBookingBookedFunction;
13
+ declare const isCheckoutBookingBooked: (event: DomainEvent<MessageName>) => event is CheckoutBookingBooked;
13
14
  export type { CheckoutBookingBooked };
14
- export { CHECKOUT_BOOKING_BOOKED, checkoutBookingBooked };
15
+ export { CHECKOUT_BOOKING_BOOKED, checkoutBookingBooked, isCheckoutBookingBooked };
@@ -4,4 +4,5 @@ const checkoutBookingBooked = ({ aggregateId, ...payload }) => ({
4
4
  ...domainEvent({ aggregateId, name: CHECKOUT_BOOKING_BOOKED }),
5
5
  ...payload,
6
6
  });
7
- export { CHECKOUT_BOOKING_BOOKED, checkoutBookingBooked };
7
+ const isCheckoutBookingBooked = (event) => event.name === CHECKOUT_BOOKING_BOOKED;
8
+ export { CHECKOUT_BOOKING_BOOKED, checkoutBookingBooked, isCheckoutBookingBooked };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_BOOKING_EXPIRED = "checkout_booking_expired";
3
3
  interface CheckoutBookingExpiredPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutBookingExpiredFunction {
9
9
  (payload: CheckoutBookingExpiredPayload): CheckoutBookingExpired;
10
10
  }
11
11
  declare const checkoutBookingExpired: CheckoutBookingExpiredFunction;
12
+ declare const isCheckoutBookingExpired: (event: DomainEvent<MessageName>) => event is CheckoutBookingExpired;
12
13
  export type { CheckoutBookingExpired };
13
- export { CHECKOUT_BOOKING_EXPIRED, checkoutBookingExpired };
14
+ export { CHECKOUT_BOOKING_EXPIRED, checkoutBookingExpired, isCheckoutBookingExpired };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_BOOKING_EXPIRED = "checkout_booking_expired";
3
3
  const checkoutBookingExpired = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_BOOKING_EXPIRED });
4
- export { CHECKOUT_BOOKING_EXPIRED, checkoutBookingExpired };
4
+ const isCheckoutBookingExpired = (event) => event.name === CHECKOUT_BOOKING_EXPIRED;
5
+ export { CHECKOUT_BOOKING_EXPIRED, checkoutBookingExpired, isCheckoutBookingExpired };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_FEEDBACK_GIVEN = "checkout_feedback_given";
3
3
  interface CheckoutFeedbackGivenPayload {
4
4
  readonly aggregateId: string;
@@ -10,5 +10,6 @@ interface CheckoutFeedbackGivenFunction {
10
10
  (payload: CheckoutFeedbackGivenPayload): CheckoutFeedbackGiven;
11
11
  }
12
12
  declare const checkoutFeedbackGiven: CheckoutFeedbackGivenFunction;
13
+ declare const isCheckoutFeedbackGiven: (event: DomainEvent<MessageName>) => event is CheckoutFeedbackGiven;
13
14
  export type { CheckoutFeedbackGiven };
14
- export { CHECKOUT_FEEDBACK_GIVEN, checkoutFeedbackGiven };
15
+ export { CHECKOUT_FEEDBACK_GIVEN, checkoutFeedbackGiven, isCheckoutFeedbackGiven };
@@ -4,4 +4,5 @@ const checkoutFeedbackGiven = ({ aggregateId, ...payload }) => ({
4
4
  ...domainEvent({ aggregateId, name: CHECKOUT_FEEDBACK_GIVEN }),
5
5
  ...payload,
6
6
  });
7
- export { CHECKOUT_FEEDBACK_GIVEN, checkoutFeedbackGiven };
7
+ const isCheckoutFeedbackGiven = (event) => event.name === CHECKOUT_FEEDBACK_GIVEN;
8
+ export { CHECKOUT_FEEDBACK_GIVEN, checkoutFeedbackGiven, isCheckoutFeedbackGiven };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_ITEM_KEPT = "checkout_item_kept";
3
3
  interface CheckoutItemKeptPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutItemKeptFunction {
9
9
  (payload: CheckoutItemKeptPayload): CheckoutItemKept;
10
10
  }
11
11
  declare const checkoutItemKept: CheckoutItemKeptFunction;
12
+ declare const isCheckoutItemKept: (event: DomainEvent<MessageName>) => event is CheckoutItemKept;
12
13
  export type { CheckoutItemKept };
13
- export { CHECKOUT_ITEM_KEPT, checkoutItemKept };
14
+ export { CHECKOUT_ITEM_KEPT, checkoutItemKept, isCheckoutItemKept };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_ITEM_KEPT = "checkout_item_kept";
3
3
  const checkoutItemKept = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_ITEM_KEPT });
4
- export { CHECKOUT_ITEM_KEPT, checkoutItemKept };
4
+ const isCheckoutItemKept = (event) => event.name === CHECKOUT_ITEM_KEPT;
5
+ export { CHECKOUT_ITEM_KEPT, checkoutItemKept, isCheckoutItemKept };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_ITEM_REPLACED = "checkout_item_replaced";
3
3
  interface CheckoutItemReplacedPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutItemReplacedFunction {
9
9
  (payload: CheckoutItemReplacedPayload): CheckoutItemReplaced;
10
10
  }
11
11
  declare const checkoutItemReplaced: CheckoutItemReplacedFunction;
12
+ declare const isCheckoutItemReplaced: (event: DomainEvent<MessageName>) => event is CheckoutItemReplaced;
12
13
  export type { CheckoutItemReplaced };
13
- export { CHECKOUT_ITEM_REPLACED, checkoutItemReplaced };
14
+ export { CHECKOUT_ITEM_REPLACED, checkoutItemReplaced, isCheckoutItemReplaced };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_ITEM_REPLACED = "checkout_item_replaced";
3
3
  const checkoutItemReplaced = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_ITEM_REPLACED });
4
- export { CHECKOUT_ITEM_REPLACED, checkoutItemReplaced };
4
+ const isCheckoutItemReplaced = (event) => event.name === CHECKOUT_ITEM_REPLACED;
5
+ export { CHECKOUT_ITEM_REPLACED, checkoutItemReplaced, isCheckoutItemReplaced };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_ITEM_RESET = "checkout_item_reset";
3
3
  interface CheckoutItemResetPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutItemResetFunction {
9
9
  (payload: CheckoutItemResetPayload): CheckoutItemReset;
10
10
  }
11
11
  declare const checkoutItemReset: CheckoutItemResetFunction;
12
+ declare const isCheckoutItemReset: (event: DomainEvent<MessageName>) => event is CheckoutItemReset;
12
13
  export type { CheckoutItemReset };
13
- export { CHECKOUT_ITEM_RESET, checkoutItemReset };
14
+ export { CHECKOUT_ITEM_RESET, checkoutItemReset, isCheckoutItemReset };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_ITEM_RESET = "checkout_item_reset";
3
3
  const checkoutItemReset = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_ITEM_RESET });
4
- export { CHECKOUT_ITEM_RESET, checkoutItemReset };
4
+ const isCheckoutItemReset = (event) => event.name === CHECKOUT_ITEM_RESET;
5
+ export { CHECKOUT_ITEM_RESET, checkoutItemReset, isCheckoutItemReset };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const CHECKOUT_ITEM_RETURNED = "checkout_item_returned";
3
3
  interface CheckoutItemReturnedPayload {
4
4
  readonly aggregateId: string;
@@ -9,5 +9,6 @@ interface CheckoutItemReturnedFunction {
9
9
  (payload: CheckoutItemReturnedPayload): CheckoutItemReturned;
10
10
  }
11
11
  declare const checkoutItemReturned: CheckoutItemReturnedFunction;
12
+ declare const isCheckoutItemReturned: (event: DomainEvent<MessageName>) => event is CheckoutItemReturned;
12
13
  export type { CheckoutItemReturned };
13
- export { CHECKOUT_ITEM_RETURNED, checkoutItemReturned };
14
+ export { CHECKOUT_ITEM_RETURNED, checkoutItemReturned, isCheckoutItemReturned };
@@ -1,4 +1,5 @@
1
1
  import { domainEvent } from "@lookiero/messaging";
2
2
  const CHECKOUT_ITEM_RETURNED = "checkout_item_returned";
3
3
  const checkoutItemReturned = ({ aggregateId }) => domainEvent({ aggregateId, name: CHECKOUT_ITEM_RETURNED });
4
- export { CHECKOUT_ITEM_RETURNED, checkoutItemReturned };
4
+ const isCheckoutItemReturned = (event) => event.name === CHECKOUT_ITEM_RETURNED;
5
+ export { CHECKOUT_ITEM_RETURNED, checkoutItemReturned, isCheckoutItemReturned };
@@ -1,4 +1,4 @@
1
- import { DomainEvent } from "@lookiero/messaging";
1
+ import { DomainEvent, MessageName } from "@lookiero/messaging";
2
2
  declare const UI_SETTING_UPDATED = "ui_setting_updated";
3
3
  interface UiSettingUpdatedPayload {
4
4
  readonly aggregateId: string;
@@ -10,5 +10,6 @@ interface UiSettingUpdatedFunction {
10
10
  (payload: UiSettingUpdatedPayload): UiSettingUpdated;
11
11
  }
12
12
  declare const uiSettingUpdated: UiSettingUpdatedFunction;
13
+ declare const isUiSettingUpdated: (event: DomainEvent<MessageName>) => event is UiSettingUpdated;
13
14
  export type { UiSettingUpdated };
14
- export { UI_SETTING_UPDATED, uiSettingUpdated };
15
+ export { UI_SETTING_UPDATED, uiSettingUpdated, isUiSettingUpdated };
@@ -4,4 +4,5 @@ const uiSettingUpdated = ({ aggregateId, key }) => ({
4
4
  ...domainEvent({ aggregateId, name: UI_SETTING_UPDATED }),
5
5
  key,
6
6
  });
7
- export { UI_SETTING_UPDATED, uiSettingUpdated };
7
+ const isUiSettingUpdated = (event) => event.name === UI_SETTING_UPDATED;
8
+ export { UI_SETTING_UPDATED, uiSettingUpdated, isUiSettingUpdated };
@@ -0,0 +1,10 @@
1
+ import { CommandStatus } from "@lookiero/messaging-react";
2
+ interface IncrementIntroShownCountFunction {
3
+ (): Promise<void>;
4
+ }
5
+ type UseIncrementIntroShownCount = [incrementIntroShownCount: IncrementIntroShownCountFunction, status: CommandStatus];
6
+ interface UseIncrementIntroShownCountFunction {
7
+ (): UseIncrementIntroShownCount;
8
+ }
9
+ declare const useIncrementIntroShownCount: UseIncrementIntroShownCountFunction;
10
+ export { useIncrementIntroShownCount };
@@ -0,0 +1,11 @@
1
+ import { useCallback } from "react";
2
+ import { useViewIntroShownCount } from "../../../projection/uiSetting/react/useViewIntroShownCount";
3
+ import { UISettings } from "../../../ui/settings/UISettings";
4
+ import { useUpdateUiSetting } from "./useUpdateUiSetting";
5
+ const useIncrementIntroShownCount = () => {
6
+ const [update, status] = useUpdateUiSetting();
7
+ const [introShownCount] = useViewIntroShownCount();
8
+ const incrementIntroShownCount = useCallback(() => update({ key: UISettings.INTRO_SHOWN_COUNT, value: introShownCount + 1 }), [introShownCount, update]);
9
+ return [incrementIntroShownCount, status];
10
+ };
11
+ export { useIncrementIntroShownCount };
@@ -1,10 +1,8 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { CHECKOUT_BOOKING_BOOKED, } from "../../../../domain/checkoutBooking/model/checkoutBookingBooked";
3
- import { CHECKOUT_BOOKING_EXPIRED } from "../../../../domain/checkoutBooking/model/checkoutBookingExpired";
2
+ import { isCheckoutBookingBooked } from "../../../../domain/checkoutBooking/model/checkoutBookingBooked";
3
+ import { isCheckoutBookingExpired } from "../../../../domain/checkoutBooking/model/checkoutBookingExpired";
4
4
  import { viewBookedProductsVariantsForCheckoutItem } from "../../../../projection/bookedProductsVariants/viewBookedProductVariantsForCheckoutItem";
5
5
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
6
- const isCheckoutBookingBooked = (event) => event.name === CHECKOUT_BOOKING_BOOKED;
7
- const isCheckoutBookingExpired = (event) => event.name === CHECKOUT_BOOKING_EXPIRED;
8
6
  const shouldInvalidate = (event) => isCheckoutBookingBooked(event) || isCheckoutBookingExpired(event);
9
7
  const useViewBookedProductsVariantsForCheckoutItem = ({ checkoutItemId, }) => useQuery({
10
8
  query: viewBookedProductsVariantsForCheckoutItem({ checkoutItemId }),
@@ -1,24 +1,15 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { CHECKOUT_STARTED } from "../../../../domain/checkout/model/checkoutStarted";
3
- import { CHECKOUT_SUBMITTED } from "../../../../domain/checkout/model/checkoutSubmitted";
4
- import { CHECKOUT_BOOKING_BOOKED } from "../../../../domain/checkoutBooking/model/checkoutBookingBooked";
5
- import { CHECKOUT_BOOKING_EXPIRED, } from "../../../../domain/checkoutBooking/model/checkoutBookingExpired";
6
- import { CHECKOUT_FEEDBACK_GIVEN, } from "../../../../domain/checkoutFeedback/model/checkoutFeedbackGiven";
7
- import { CHECKOUT_ITEM_KEPT } from "../../../../domain/checkoutItem/model/checkoutItemKept";
8
- import { CHECKOUT_ITEM_REPLACED, } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
9
- import { CHECKOUT_ITEM_RESET } from "../../../../domain/checkoutItem/model/checkoutItemReset";
10
- import { CHECKOUT_ITEM_RETURNED, } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
2
+ import { isCheckoutStarted } from "../../../../domain/checkout/model/checkoutStarted";
3
+ import { isCheckoutSubmitted } from "../../../../domain/checkout/model/checkoutSubmitted";
4
+ import { isCheckoutBookingBooked } from "../../../../domain/checkoutBooking/model/checkoutBookingBooked";
5
+ import { isCheckoutBookingExpired } from "../../../../domain/checkoutBooking/model/checkoutBookingExpired";
6
+ import { isCheckoutFeedbackGiven } from "../../../../domain/checkoutFeedback/model/checkoutFeedbackGiven";
7
+ import { isCheckoutItemKept } from "../../../../domain/checkoutItem/model/checkoutItemKept";
8
+ import { isCheckoutItemReplaced } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
9
+ import { isCheckoutItemReset } from "../../../../domain/checkoutItem/model/checkoutItemReset";
10
+ import { isCheckoutItemReturned } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
11
11
  import { viewFirstAvailableCheckoutByCustomerId } from "../../../../projection/checkout/viewFirstAvailableCheckoutByCustomerId";
12
12
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
13
- const isCheckoutItemKept = (event) => event.name === CHECKOUT_ITEM_KEPT;
14
- const isCheckoutItemReturned = (event) => event.name === CHECKOUT_ITEM_RETURNED;
15
- const isCheckoutItemReplaced = (event) => event.name === CHECKOUT_ITEM_REPLACED;
16
- const isCheckoutItemReset = (event) => event.name === CHECKOUT_ITEM_RESET;
17
- const isCheckoutStarted = (event) => event.name === CHECKOUT_STARTED;
18
- const isCheckoutSubmitted = (event) => event.name === CHECKOUT_SUBMITTED;
19
- const isCheckoutFeedbackGiven = (event) => event.name === CHECKOUT_FEEDBACK_GIVEN;
20
- const isCheckoutBookingBooked = (event) => event.name === CHECKOUT_BOOKING_BOOKED;
21
- const isCheckoutBookingExpired = (event) => event.name === CHECKOUT_BOOKING_EXPIRED;
22
13
  const shouldInvalidate = (event) => isCheckoutItemKept(event) ||
23
14
  isCheckoutItemReplaced(event) ||
24
15
  isCheckoutItemReturned(event) ||
@@ -1,8 +1,7 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { CHECKOUT_FEEDBACK_GIVEN, } from "../../../../domain/checkoutFeedback/model/checkoutFeedbackGiven";
2
+ import { isCheckoutFeedbackGiven } from "../../../../domain/checkoutFeedback/model/checkoutFeedbackGiven";
3
3
  import { viewIsCheckoutAccessibleByCustomerId, } from "../../../../projection/checkout/viewIsCheckoutAccessibleByCustomerId";
4
4
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
5
- const isCheckoutFeedbackGiven = (event) => event.name === CHECKOUT_FEEDBACK_GIVEN;
6
5
  const useViewIsCheckoutAccessibleByCustomerId = ({ customerId }) => useQuery({
7
6
  query: viewIsCheckoutAccessibleByCustomerId({ customerId }),
8
7
  contextId: MESSAGING_CONTEXT_ID,
@@ -1,14 +1,10 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { CHECKOUT_ITEM_KEPT } from "../../../../domain/checkoutItem/model/checkoutItemKept";
3
- import { CHECKOUT_ITEM_REPLACED, } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
4
- import { CHECKOUT_ITEM_RESET } from "../../../../domain/checkoutItem/model/checkoutItemReset";
5
- import { CHECKOUT_ITEM_RETURNED, } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
2
+ import { isCheckoutItemKept } from "../../../../domain/checkoutItem/model/checkoutItemKept";
3
+ import { isCheckoutItemReplaced } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
4
+ import { isCheckoutItemReset } from "../../../../domain/checkoutItem/model/checkoutItemReset";
5
+ import { isCheckoutItemReturned } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
6
6
  import { viewPaymentFlowPayloadByCheckoutId } from "../../../../projection/payment/viewPaymentFlowPayloadByCheckoutId";
7
7
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
8
- const isCheckoutItemKept = (event) => event.name === CHECKOUT_ITEM_KEPT;
9
- const isCheckoutItemReturned = (event) => event.name === CHECKOUT_ITEM_RETURNED;
10
- const isCheckoutItemReplaced = (event) => event.name === CHECKOUT_ITEM_REPLACED;
11
- const isCheckoutItemReset = (event) => event.name === CHECKOUT_ITEM_RESET;
12
8
  const shouldInvalidate = (event) => isCheckoutItemKept(event) ||
13
9
  isCheckoutItemReplaced(event) ||
14
10
  isCheckoutItemReturned(event) ||
@@ -1,14 +1,10 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { CHECKOUT_ITEM_KEPT } from "../../../../domain/checkoutItem/model/checkoutItemKept";
3
- import { CHECKOUT_ITEM_REPLACED, } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
4
- import { CHECKOUT_ITEM_RESET } from "../../../../domain/checkoutItem/model/checkoutItemReset";
5
- import { CHECKOUT_ITEM_RETURNED, } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
2
+ import { isCheckoutItemKept } from "../../../../domain/checkoutItem/model/checkoutItemKept";
3
+ import { isCheckoutItemReplaced } from "../../../../domain/checkoutItem/model/checkoutItemReplaced";
4
+ import { isCheckoutItemReset } from "../../../../domain/checkoutItem/model/checkoutItemReset";
5
+ import { isCheckoutItemReturned } from "../../../../domain/checkoutItem/model/checkoutItemReturned";
6
6
  import { viewPricingByCheckoutId } from "../../../../projection/pricing/viewPricingByCheckoutId";
7
7
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
8
- const isCheckoutItemKept = (event) => event.name === CHECKOUT_ITEM_KEPT;
9
- const isCheckoutItemReturned = (event) => event.name === CHECKOUT_ITEM_RETURNED;
10
- const isCheckoutItemReplaced = (event) => event.name === CHECKOUT_ITEM_REPLACED;
11
- const isCheckoutItemReset = (event) => event.name === CHECKOUT_ITEM_RESET;
12
8
  const shouldInvalidate = (event) => isCheckoutItemKept(event) ||
13
9
  isCheckoutItemReplaced(event) ||
14
10
  isCheckoutItemReturned(event) ||
@@ -0,0 +1,6 @@
1
+ import { QueryStatus } from "@lookiero/messaging-react";
2
+ interface UseShouldIntroBeShownFunction {
3
+ (): [boolean, QueryStatus];
4
+ }
5
+ declare const useShouldIntroBeShown: UseShouldIntroBeShownFunction;
6
+ export { useShouldIntroBeShown };
@@ -0,0 +1,7 @@
1
+ import { useViewIntroShownCount } from "./useViewIntroShownCount";
2
+ const MAX_INTRO_SHOWN_COUNT = 2;
3
+ const useShouldIntroBeShown = () => {
4
+ const [introShownCount, introShownCountStatus] = useViewIntroShownCount();
5
+ return [introShownCount < MAX_INTRO_SHOWN_COUNT, introShownCountStatus];
6
+ };
7
+ export { useShouldIntroBeShown };
@@ -0,0 +1,6 @@
1
+ import { QueryStatus } from "@lookiero/messaging-react";
2
+ interface UseViewIntroShownCountFunction {
3
+ (): [number, QueryStatus];
4
+ }
5
+ declare const useViewIntroShownCount: UseViewIntroShownCountFunction;
6
+ export { useViewIntroShownCount };
@@ -0,0 +1,9 @@
1
+ import { UISettings } from "../../../ui/settings/UISettings";
2
+ import { useViewUiSettingByKey } from "./useViewUiSettingByKey";
3
+ const useViewIntroShownCount = () => {
4
+ const [introShownCount, introShownCountStatus] = useViewUiSettingByKey({
5
+ key: UISettings.INTRO_SHOWN_COUNT,
6
+ });
7
+ return [introShownCount?.value || 0, introShownCountStatus];
8
+ };
9
+ export { useViewIntroShownCount };
@@ -1,8 +1,7 @@
1
1
  import { useQuery } from "@lookiero/messaging-react";
2
- import { UI_SETTING_UPDATED } from "../../../../domain/uiSetting/model/uiSettingUpdated";
2
+ import { isUiSettingUpdated } from "../../../../domain/uiSetting/model/uiSettingUpdated";
3
3
  import { viewUiSettingByKey } from "../../../../projection/uiSetting/viewUiSettingByKey";
4
4
  import { MESSAGING_CONTEXT_ID } from "../../../delivery/baseBootstrap";
5
- const isUiSettingUpdated = (event) => event.name === UI_SETTING_UPDATED;
6
5
  const useViewUiSettingByKey = ({ key }) => useQuery({
7
6
  query: viewUiSettingByKey({ key }),
8
7
  contextId: MESSAGING_CONTEXT_ID,
@@ -1,3 +1,4 @@
1
1
  import { ReturnQuestionItem } from "../ReturnQuestionItem";
2
+ declare const TEXTAREA_MIN_HEIGHT = 96;
2
3
  declare const TextareaReturnQuestionItem: ReturnQuestionItem;
3
- export { TextareaReturnQuestionItem };
4
+ export { TextareaReturnQuestionItem, TEXTAREA_MIN_HEIGHT };
@@ -9,4 +9,4 @@ const TextareaReturnQuestionItem = ({ returnQuestion, returnQuestionParentId, })
9
9
  const handleOnChange = useCallback((value) => onChange({ returnQuestionId: returnQuestionParentId, returnQuestionFeedback: value }), [onChange, returnQuestionParentId]);
10
10
  return (React.createElement(InputField, { label: placeholderText, minHeight: TEXTAREA_MIN_HEIGHT, placeholder: placeholderText, value: feedback, multiline: true, onChange: handleOnChange }));
11
11
  };
12
- export { TextareaReturnQuestionItem };
12
+ export { TextareaReturnQuestionItem, TEXTAREA_MIN_HEIGHT };
@@ -1,16 +1,16 @@
1
1
  import React from "react";
2
- import { Platform, ScrollView } from "react-native";
2
+ import { ScrollView } from "react-native";
3
3
  import { SafeAreaView, useSafeAreaInsets } from "react-native-safe-area-context";
4
4
  import { theme } from "../../theme/theme";
5
5
  import { style } from "./SafeAreaScrollView.style.ts";
6
- const { spaceXXXL } = theme();
6
+ const { spaceXXL } = theme();
7
7
  const SafeAreaScrollView = ({ children, footer, edges = ["top", "left", "right"], style: customStyle, scrollerPaddingTop = 0, }) => {
8
8
  const { bottom: safeAreaInsetBottom } = useSafeAreaInsets();
9
9
  return (React.createElement(SafeAreaView, { edges: edges, style: [style.safeAreaView, customStyle?.safeAreaView] },
10
10
  React.createElement(ScrollView, { contentContainerStyle: [
11
11
  {
12
12
  paddingTop: scrollerPaddingTop,
13
- paddingBottom: safeAreaInsetBottom + (Platform.OS === "android" ? spaceXXXL : 0),
13
+ paddingBottom: safeAreaInsetBottom + spaceXXL,
14
14
  },
15
15
  customStyle?.scrollView,
16
16
  ] }, children),
@@ -1,21 +1,23 @@
1
1
  import { useEvent } from "@lookiero/event";
2
2
  import { useCallback, useEffect } from "react";
3
3
  import { useCreateToastNotification } from "../../../shared/notifications";
4
+ import { NotificationLevel } from "../../../shared/notifications/domain/notification/model/notification";
4
5
  import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
5
6
  import { I18nMessages } from "../i18n/i18n";
6
- import { useToast } from "./useToast";
7
7
  const PAYMENT_ERROR = "ERROR";
8
8
  const PAYMENT_SUCCESS = "PAYMENT_INSTRUMENT_UPDATED";
9
9
  const usePaymentInstrumentEvents = ({ logger }) => {
10
10
  const { subscribe, unsubscribe } = useEvent();
11
- const { showError, showSuccess } = useToast();
12
11
  const [createNotification] = useCreateToastNotification({ contextId: MESSAGING_CONTEXT_ID, logger });
13
- const onSuccess = useCallback(({ message }) => showSuccess({ message: message.id }), [showSuccess]);
12
+ const onSuccess = useCallback(({ message }) => createNotification({ bodyI18nKey: message.id, level: NotificationLevel.SUCCESS }), [createNotification]);
14
13
  const onError = useCallback(({ error }) => {
15
14
  if (error.toaster) {
16
- showError({ message: error.toaster.id || I18nMessages.CHECKOUT_TOAST_PAYMENT_ERROR });
15
+ createNotification({
16
+ bodyI18nKey: error.toaster.id || I18nMessages.CHECKOUT_TOAST_PAYMENT_ERROR,
17
+ level: NotificationLevel.ERROR,
18
+ });
17
19
  }
18
- }, [showError]);
20
+ }, [createNotification]);
19
21
  useEffect(() => {
20
22
  subscribe({ event: PAYMENT_ERROR }, onError);
21
23
  subscribe({ event: PAYMENT_SUCCESS }, onSuccess);
@@ -0,0 +1,2 @@
1
+ declare const usePaymentInstrumentUpdateEvents: () => void;
2
+ export { usePaymentInstrumentUpdateEvents };
@@ -0,0 +1,28 @@
1
+ import { useEvent } from "@lookiero/event";
2
+ import { useCallback, useEffect } from "react";
3
+ import { useCreateNotification } from "../../../shared/notifications";
4
+ import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
5
+ import { I18nMessages } from "../i18n/i18n";
6
+ import { useToast } from "./useToast";
7
+ const PAYMENT_ERROR = "ERROR";
8
+ const PAYMENT_SUCCESS = "PAYMENT_INSTRUMENT_UPDATED";
9
+ const usePaymentInstrumentUpdateEvents = () => {
10
+ const { subscribe, unsubscribe } = useEvent();
11
+ const { showError, showSuccess } = useToast();
12
+ const [createNotification] = useCreateNotification({ contextId: MESSAGING_CONTEXT_ID });
13
+ const onSuccess = useCallback(({ message }) => showSuccess({ message: message.id }), [showSuccess]);
14
+ const onError = useCallback(({ error }) => {
15
+ if (error.toaster) {
16
+ showError({ message: error.toaster.id || I18nMessages.CHECKOUT_TOAST_PAYMENT_ERROR });
17
+ }
18
+ }, [showError]);
19
+ useEffect(() => {
20
+ subscribe({ event: PAYMENT_ERROR }, onError);
21
+ subscribe({ event: PAYMENT_SUCCESS }, onSuccess);
22
+ return () => {
23
+ unsubscribe({ event: PAYMENT_ERROR }, onError);
24
+ unsubscribe({ event: PAYMENT_SUCCESS }, onSuccess);
25
+ };
26
+ }, [subscribe, unsubscribe, createNotification, onError, onSuccess]);
27
+ };
28
+ export { usePaymentInstrumentUpdateEvents };
@@ -1,4 +1,5 @@
1
1
  import { PortalProvider } from "@gorhom/portal";
2
+ import { PortalProvider as AuroraPortalProvider } from "@lookiero/aurora";
2
3
  import React from "react";
3
4
  import { StatusBar } from "react-native";
4
5
  import { SafeAreaProvider } from "react-native-safe-area-context";
@@ -11,5 +12,6 @@ const App = ({ children, customerId, country, onOpenMenu }) => (React.createElem
11
12
  React.createElement(PortalProvider, null,
12
13
  React.createElement(StatusBar, { backgroundColor: colorBase, barStyle: "dark-content", translucent: true }),
13
14
  React.createElement(Notifications, { contextId: MESSAGING_CONTEXT_ID }),
14
- React.createElement(Navigation, { country: country, customerId: customerId, onOpenMenu: onOpenMenu }, children))));
15
+ React.createElement(Navigation, { country: country, customerId: customerId, onOpenMenu: onOpenMenu },
16
+ React.createElement(AuroraPortalProvider, null, children)))));
15
17
  export { App };
@@ -10,7 +10,6 @@ declare const style: {
10
10
  };
11
11
  pricingContainer: {
12
12
  marginTop: number;
13
- paddingBottom: number;
14
13
  };
15
14
  title: {
16
15
  marginBottom: number;
@@ -13,7 +13,6 @@ const style = StyleSheet.create({
13
13
  },
14
14
  pricingContainer: {
15
15
  marginTop: spaceXL,
16
- paddingBottom: spaceXL,
17
16
  },
18
17
  title: {
19
18
  marginBottom: spaceM,
@@ -0,0 +1,7 @@
1
+ import { FC } from "react";
2
+ interface CheckoutSuccessModalProps {
3
+ readonly visible: boolean;
4
+ readonly onDismiss: () => void;
5
+ }
6
+ declare const CheckoutSuccessModal: FC<CheckoutSuccessModalProps>;
7
+ export { CheckoutSuccessModal };
@@ -0,0 +1,25 @@
1
+ import { Button } from "@lookiero/aurora-next/build/components/atoms/Button/Button";
2
+ import { Text } from "@lookiero/aurora-next/build/components/primitives/Text/Text";
3
+ import { useI18nMessage } from "@lookiero/i18n-react";
4
+ import React from "react";
5
+ import { View } from "react-native";
6
+ import { Modal } from "../../../../../../shared/ui/components/layouts/modal/Modal";
7
+ import { I18nMessages } from "../../../../i18n/i18n";
8
+ import { style } from "./CheckoutSuccessModal.style";
9
+ const CheckoutSuccessModal = ({ visible, onDismiss }) => {
10
+ const titleText = useI18nMessage({ id: I18nMessages.CHECKOUT_SUCCESS_MODAL_TITLE });
11
+ const descriptionText = useI18nMessage({ id: I18nMessages.CHECKOUT_SUCCESS_MODAL_DESCRIPTION });
12
+ const buttonText = useI18nMessage({ id: I18nMessages.CHECKOUT_SUCCESS_MODAL_BUTTON });
13
+ return (React.createElement(Modal, { visible: visible, onClose: onDismiss },
14
+ React.createElement(View, { style: style.modal },
15
+ React.createElement(Text, { level: 1, style: style.modalTitle, body: true }, titleText),
16
+ React.createElement(Text, { level: 3, style: style.modalDescription, body: true }, descriptionText),
17
+ React.createElement(Button
18
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
19
+ // @ts-ignore
20
+ , {
21
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
22
+ // @ts-ignore
23
+ style: style.button, onPress: onDismiss }, buttonText))));
24
+ };
25
+ export { CheckoutSuccessModal };