@lookiero/checkout 8.14.0-beta.2 → 8.14.0-beta.3

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 (125) hide show
  1. package/dist/src/infrastructure/projection/checkout/react/useViewIsCheckoutAccessibleByCustomerId.d.ts +10 -0
  2. package/dist/src/infrastructure/projection/checkout/react/useViewIsCheckoutAccessibleByCustomerId.js +17 -0
  3. package/dist/src/infrastructure/ui/Root.d.ts +2 -3
  4. package/dist/src/infrastructure/ui/Root.js +4 -2
  5. package/dist/src/infrastructure/ui/components/layouts/layout/Layout.d.ts +21 -0
  6. package/dist/src/infrastructure/ui/components/layouts/layout/Layout.js +1 -0
  7. package/dist/src/infrastructure/ui/components/layouts/layout/components/footer/Footer.d.ts +6 -0
  8. package/dist/src/infrastructure/ui/components/layouts/layout/components/footer/Footer.js +4 -0
  9. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.d.ts +6 -0
  10. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.js +5 -0
  11. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.style.d.ts +4 -0
  12. package/dist/src/infrastructure/ui/components/layouts/layout/components/header/Header.style.js +19 -0
  13. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.d.ts +3 -0
  14. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.js +18 -0
  15. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.style.d.ts +12 -0
  16. package/dist/src/infrastructure/ui/components/layouts/layout/dummyLayout/DummyLayout.style.js +13 -0
  17. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.d.ts +0 -5
  18. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.js +3 -3
  19. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.d.ts +0 -5
  20. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.js +1 -1
  21. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/ReturnQuestionItem.d.ts +0 -5
  22. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.js +4 -3
  23. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/form/HostStackReturnQuestionItem.js +1 -1
  24. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.js +2 -2
  25. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.d.ts +1 -3
  26. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.js +5 -4
  27. package/dist/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.js +4 -4
  28. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.d.ts +6 -0
  29. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.js +11 -0
  30. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.style.d.ts +8 -0
  31. package/dist/src/infrastructure/ui/components/templates/header/defaultHeader/DefaultHeader.style.js +11 -0
  32. package/dist/src/infrastructure/ui/hooks/useNewFeedbackExperiment.d.ts +11 -0
  33. package/dist/src/infrastructure/ui/hooks/useNewFeedbackExperiment.js +49 -0
  34. package/dist/src/infrastructure/ui/i18n/fetchTranslations.d.ts +9 -0
  35. package/dist/src/infrastructure/ui/i18n/fetchTranslations.js +9 -0
  36. package/dist/src/infrastructure/ui/i18n/translationEndpoint.d.ts +19 -0
  37. package/dist/src/infrastructure/ui/i18n/translationEndpoint.js +21 -0
  38. package/dist/src/infrastructure/ui/routing/CheckoutAccessibilityMiddleware.d.ts +9 -0
  39. package/dist/src/infrastructure/ui/routing/CheckoutAccessibilityMiddleware.js +21 -0
  40. package/dist/src/infrastructure/ui/routing/Routing.d.ts +0 -7
  41. package/dist/src/infrastructure/ui/routing/Routing.js +5 -5
  42. package/dist/src/infrastructure/ui/test/render.js +3 -1
  43. package/dist/src/infrastructure/ui/views/App.d.ts +0 -8
  44. package/dist/src/infrastructure/ui/views/App.js +10 -7
  45. package/dist/src/infrastructure/ui/views/feedback/components/checkoutQuestionsForm/CheckoutQuestionsForm.style.d.ts +7 -0
  46. package/dist/src/infrastructure/ui/views/feedback/components/checkoutQuestionsForm/CheckoutQuestionsForm.style.js +10 -0
  47. package/dist/src/infrastructure/ui/views/item/Item.d.ts +0 -5
  48. package/dist/src/infrastructure/ui/views/item/Item.js +3 -3
  49. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.d.ts +0 -2
  50. package/dist/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.js +4 -3
  51. package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.d.ts +1 -5
  52. package/dist/src/infrastructure/ui/views/item/components/itemActions/ItemActions.js +2 -2
  53. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.d.ts +0 -5
  54. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.js +2 -2
  55. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.d.ts +11 -0
  56. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.js +40 -0
  57. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +12 -0
  58. package/dist/src/infrastructure/ui/views/item/components/returnQuestionsForm/ReturnQuestionsForm.style.js +15 -0
  59. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.d.ts +0 -7
  60. package/dist/src/infrastructure/ui/views/item/components/selectModal/SelectModal.js +6 -5
  61. package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.d.ts +0 -2
  62. package/dist/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.js +4 -3
  63. package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.d.ts +0 -5
  64. package/dist/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.js +2 -2
  65. package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.d.ts +0 -5
  66. package/dist/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.js +2 -2
  67. package/dist/src/infrastructure/ui/views/return/Return.d.ts +0 -5
  68. package/dist/src/infrastructure/ui/views/return/Return.js +2 -2
  69. package/dist/src/infrastructure/ui/views/return/Return.style.d.ts +40 -0
  70. package/dist/src/infrastructure/ui/views/return/Return.style.js +43 -0
  71. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.d.ts +0 -5
  72. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.js +11 -10
  73. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.d.ts +6 -2
  74. package/dist/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.js +6 -2
  75. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.d.ts +13 -0
  76. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.js +9 -0
  77. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.style.d.ts +7 -0
  78. package/dist/src/infrastructure/ui/views/summary/components/stickyPricing/StickyPricing.style.js +10 -0
  79. package/dist/src/projection/checkout/viewIsCheckoutAccessibleByCustomerId.d.ts +17 -0
  80. package/dist/src/projection/checkout/viewIsCheckoutAccessibleByCustomerId.js +13 -0
  81. package/dist/src/projection/shared/country.d.ts +14 -0
  82. package/dist/src/projection/shared/country.js +15 -0
  83. package/dist/src/projection/shared/customer.d.ts +8 -0
  84. package/dist/src/projection/shared/customer.js +1 -0
  85. package/dist/src/projection/shared/locale.d.ts +12 -0
  86. package/dist/src/projection/shared/locale.js +13 -0
  87. package/dist/src/projection/shared/order.d.ts +6 -0
  88. package/dist/src/projection/shared/order.js +1 -0
  89. package/dist/src/projection/shared/price.d.ts +10 -0
  90. package/dist/src/projection/shared/price.js +1 -0
  91. package/dist/src/projection/shared/size.d.ts +20 -0
  92. package/dist/src/projection/shared/size.js +3 -0
  93. package/dist/src/projection/shared/subscription.d.ts +2 -0
  94. package/dist/src/projection/shared/subscription.js +1 -0
  95. package/dist/src/shared/ui/components/atoms/error/Error.d.ts +10 -0
  96. package/dist/src/shared/ui/components/atoms/error/Error.js +4 -0
  97. package/dist/src/version.d.ts +1 -1
  98. package/dist/src/version.js +1 -1
  99. package/package.json +2 -2
  100. package/src/infrastructure/ui/Root.tsx +22 -21
  101. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestion.tsx +1 -14
  102. package/src/infrastructure/ui/components/organisms/returnQuestions/ReturnQuestions.tsx +1 -8
  103. package/src/infrastructure/ui/components/organisms/returnQuestions/components/ReturnQuestionItem.ts +0 -6
  104. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem.tsx +3 -3
  105. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/form/HostStackReturnQuestionItem.tsx +0 -2
  106. package/src/infrastructure/ui/components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem.tsx +0 -2
  107. package/src/infrastructure/ui/components/organisms/returnQuestions/components/modalOptionReturnQuestionItems/ModalOptionReturnQuestionItems.tsx +4 -6
  108. package/src/infrastructure/ui/components/organisms/returnQuestions/components/radioReturnQuestionItem/RadioReturnQuestionItem.tsx +2 -3
  109. package/src/infrastructure/ui/routing/Routing.tsx +5 -13
  110. package/src/infrastructure/ui/test/render.tsx +4 -1
  111. package/src/infrastructure/ui/views/App.tsx +23 -26
  112. package/src/infrastructure/ui/views/item/Item.tsx +2 -8
  113. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/GetOutOfCheckoutModal.tsx +5 -10
  114. package/src/infrastructure/ui/views/item/components/getOutOfCheckoutModal/__snapshots__/GetOutOfCheckoutModal.test.tsx.snap +6 -3
  115. package/src/infrastructure/ui/views/item/components/itemActions/ItemActions.tsx +2 -8
  116. package/src/infrastructure/ui/views/item/components/returnQuestionsFeedback/ReturnQuestionsFeedback.tsx +3 -12
  117. package/src/infrastructure/ui/views/item/components/selectModal/SelectModal.tsx +6 -17
  118. package/src/infrastructure/ui/views/item/components/selectModal/__snapshots__/SelecModal.test.tsx.snap +5 -8
  119. package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/SizeWithoutStockModal.tsx +6 -5
  120. package/src/infrastructure/ui/views/item/components/sizeWithoutStockModal/__snapshots__/SizeWithoutStockModal.test.tsx.snap +6 -3
  121. package/src/infrastructure/ui/views/item/views/itemWithCustomerDecission/ItemWithCustomerDecission.tsx +2 -12
  122. package/src/infrastructure/ui/views/item/views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission.tsx +2 -12
  123. package/src/infrastructure/ui/views/return/Return.tsx +1 -8
  124. package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.style.ts +6 -2
  125. package/src/infrastructure/ui/views/return/components/returnQuestionsForm/ReturnQuestionsForm.tsx +30 -31
@@ -1,5 +1,4 @@
1
1
  import React from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { useRoutes as reactRouterUseRoutes } from "react-router-native";
4
3
  import { I18n } from "@lookiero/i18n-react";
5
4
  import { Locale } from "@lookiero/sty-psp-locale";
@@ -8,10 +7,6 @@ import { Customer } from "../../../projection/customer/customer";
8
7
  import { Order } from "../../../projection/order/order";
9
8
  import { Subscription } from "../../../projection/subscription/subscription";
10
9
  import { KameleoonEnvironment } from "../../ab-testing/kameleoonEnvironment";
11
- import { AppStyle } from "../views/App";
12
- interface RoutingStyle extends AppStyle {
13
- readonly modal: StyleProp<ViewStyle>;
14
- }
15
10
  interface RoutingProps {
16
11
  readonly basePath?: string;
17
12
  readonly customer: Customer;
@@ -21,7 +16,6 @@ interface RoutingProps {
21
16
  readonly I18n: I18n;
22
17
  readonly kameleoon: KameleoonEnvironment;
23
18
  readonly layout: Layout;
24
- readonly style?: Partial<RoutingStyle>;
25
19
  readonly getAuthToken: () => Promise<string>;
26
20
  readonly onNotAccessible: () => void;
27
21
  readonly onCheckoutSubmitted?: () => void;
@@ -37,4 +31,3 @@ interface RoutingProps {
37
31
  */
38
32
  declare const MemoizedRouting: React.NamedExoticComponent<RoutingProps>;
39
33
  export { MemoizedRouting as Routing };
40
- export type { RoutingStyle };
@@ -14,7 +14,7 @@ import { SummaryTabs } from "../views/summaryTabs/SummaryTabs";
14
14
  import { CheckoutMiddleware } from "./CheckoutMiddleware";
15
15
  import { Routes } from "./routes";
16
16
  import { BasePathProvider } from "./useBasePath";
17
- const Routing = ({ basePath = "", customer, order, subscription, locale, I18n, kameleoon, layout, style: customStyle, getAuthToken, onI18nError, onNotAccessible, onCheckoutSubmitted, useRedirect, useRoutes = reactRouterUseRoutes, }) => {
17
+ const Routing = ({ basePath = "", customer, order, subscription, locale, I18n, kameleoon, layout, getAuthToken, onI18nError, onNotAccessible, onCheckoutSubmitted, useRedirect, useRoutes = reactRouterUseRoutes, }) => {
18
18
  return useRoutes([
19
19
  {
20
20
  path: "",
@@ -23,18 +23,18 @@ const Routing = ({ basePath = "", customer, order, subscription, locale, I18n, k
23
23
  React.createElement(I18n, { loader: React.createElement(Spinner, null), locale: locale, onError: onI18nError },
24
24
  React.createElement(Kameleoon, { loader: React.createElement(Spinner, null), siteCode: kameleoon.siteCode },
25
25
  React.createElement(CheckoutMiddleware, { customerId: customer?.customerId, onNotAccessible: onNotAccessible },
26
- React.createElement(App, { style: { container: customStyle?.container, notifications: customStyle?.notifications } },
26
+ React.createElement(App, null,
27
27
  React.createElement(Outlet, null)))))))),
28
28
  children: [
29
29
  {
30
30
  path: Routes.ITEM,
31
31
  element: (React.createElement(Suspense, { fallback: React.createElement(Spinner, null) },
32
- React.createElement(Item, { layout: layout, style: { modal: customStyle?.modal } }))),
32
+ React.createElement(Item, { layout: layout }))),
33
33
  },
34
34
  {
35
35
  path: Routes.ITEM_DETAIL,
36
36
  element: (React.createElement(Suspense, { fallback: React.createElement(Spinner, null) },
37
- React.createElement(Item, { layout: layout, style: { modal: customStyle?.modal } }))),
37
+ React.createElement(Item, { layout: layout }))),
38
38
  },
39
39
  {
40
40
  path: Routes.SUMMARY,
@@ -69,7 +69,7 @@ const Routing = ({ basePath = "", customer, order, subscription, locale, I18n, k
69
69
  {
70
70
  path: Routes.RETURN,
71
71
  element: (React.createElement(Suspense, { fallback: React.createElement(Spinner, null) },
72
- React.createElement(Return, { layout: layout, style: { modal: customStyle?.modal } }))),
72
+ React.createElement(Return, { layout: layout }))),
73
73
  },
74
74
  {
75
75
  path: "*",
@@ -4,6 +4,7 @@ import React, { Fragment } from "react";
4
4
  import { IntlProvider } from "react-intl";
5
5
  import { Aurora } from "@lookiero/aurora";
6
6
  import { LoggerProvider } from "@lookiero/sty-psp-logging";
7
+ import { EnvironmentStyleProvider } from "@lookiero/sty-psp-ui";
7
8
  import { BasePathProvider } from "../routing/useBasePath";
8
9
  const renderWrapper = ({ locale, messages = {}, wrapper: Wrapper = Fragment, logger = mock() }) =>
9
10
  // eslint-disable-next-line react/display-name, react/prop-types
@@ -11,6 +12,7 @@ const renderWrapper = ({ locale, messages = {}, wrapper: Wrapper = Fragment, log
11
12
  React.createElement(IntlProvider, { locale: locale, messages: messages, onError: () => void 0 },
12
13
  React.createElement(LoggerProvider, { logger: logger },
13
14
  React.createElement(BasePathProvider, { basePath: "" },
14
- React.createElement(Wrapper, null, children))))));
15
+ React.createElement(EnvironmentStyleProvider, null,
16
+ React.createElement(Wrapper, null, children)))))));
15
17
  const renderWithProviders = (ui, { locale, messages, wrapper } = { locale: "en" }) => render(ui, { wrapper: renderWrapper({ locale, messages, wrapper }) });
16
18
  export { renderWithProviders as render };
@@ -1,14 +1,6 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
- import { NotificationsStyle } from "@lookiero/sty-psp-notifications";
4
- interface AppStyle {
5
- readonly container: StyleProp<ViewStyle>;
6
- readonly notifications: Partial<NotificationsStyle>;
7
- }
8
2
  interface AppProps {
9
3
  readonly children: JSX.Element;
10
- readonly style?: Partial<AppStyle>;
11
4
  }
12
5
  declare const App: FC<AppProps>;
13
- export type { AppStyle };
14
6
  export { App };
@@ -4,14 +4,17 @@ import { StatusBar, View } from "react-native";
4
4
  import { SafeAreaProvider } from "react-native-safe-area-context";
5
5
  import { PortalProvider as AuroraPortalProvider } from "@lookiero/aurora";
6
6
  import { Notifications } from "@lookiero/sty-psp-notifications";
7
- import { theme } from "@lookiero/sty-psp-ui";
7
+ import { theme, useEnvironmentStyle } from "@lookiero/sty-psp-ui";
8
8
  import { MESSAGING_CONTEXT_ID } from "../../delivery/baseBootstrap";
9
9
  import { style } from "./App.style";
10
10
  const { colorBgBase } = theme();
11
- const App = ({ children, style: customStyle }) => (React.createElement(View, { style: [style.container, customStyle?.container] },
12
- React.createElement(SafeAreaProvider, null,
13
- React.createElement(PortalProvider, null,
14
- React.createElement(StatusBar, { backgroundColor: colorBgBase, barStyle: "dark-content", translucent: true }),
15
- React.createElement(Notifications, { contextId: MESSAGING_CONTEXT_ID, style: customStyle?.notifications }),
16
- React.createElement(AuroraPortalProvider, null, children)))));
11
+ const App = ({ children }) => {
12
+ const { container } = useEnvironmentStyle();
13
+ return (React.createElement(View, { style: [style.container, container] },
14
+ React.createElement(SafeAreaProvider, null,
15
+ React.createElement(PortalProvider, null,
16
+ React.createElement(StatusBar, { backgroundColor: colorBgBase, barStyle: "dark-content", translucent: true }),
17
+ React.createElement(Notifications, { contextId: MESSAGING_CONTEXT_ID }),
18
+ React.createElement(AuroraPortalProvider, null, children)))));
19
+ };
17
20
  export { App };
@@ -0,0 +1,7 @@
1
+ declare const style: {
2
+ buttonContainer: {
3
+ paddingHorizontal: number;
4
+ paddingVertical: number;
5
+ };
6
+ };
7
+ export { style };
@@ -0,0 +1,10 @@
1
+ import { StyleSheet } from "react-native";
2
+ import { theme } from "@lookiero/sty-psp-ui";
3
+ const { space6, space8 } = theme();
4
+ const style = StyleSheet.create({
5
+ buttonContainer: {
6
+ paddingHorizontal: space6,
7
+ paddingVertical: space8,
8
+ },
9
+ });
10
+ export { style };
@@ -1,12 +1,7 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { Layout } from "@lookiero/sty-psp-ui";
4
- interface ItemStyle {
5
- readonly modal: StyleProp<ViewStyle>;
6
- }
7
3
  interface ItemProps {
8
4
  readonly layout: Layout;
9
- readonly style?: Partial<ItemStyle>;
10
5
  }
11
6
  declare const Item: FC<ItemProps>;
12
7
  export { Item };
@@ -26,7 +26,7 @@ import { useBasePath } from "../../routing/useBasePath";
26
26
  import { style } from "./Item.style";
27
27
  import { ItemWithCustomerDecission, } from "./views/itemWithCustomerDecission/ItemWithCustomerDecission";
28
28
  import { ItemWithoutCustomerDecission, } from "./views/itemWithoutCustomerDecission/ItemWithoutCustomerDecission";
29
- const Item = ({ layout: Layout, style: customStyle }) => {
29
+ const Item = ({ layout: Layout }) => {
30
30
  const logger = useLogger();
31
31
  const screenSize = useScreenSize();
32
32
  const navigate = useNavigate();
@@ -141,10 +141,10 @@ const Item = ({ layout: Layout, style: customStyle }) => {
141
141
  return React.createElement(Spinner, { testID: "spinner" });
142
142
  }
143
143
  return (React.createElement(ReturnQuestionFeedbackProvider, { key: checkoutItem.id, feedback: checkoutItem.feedbacks || {} },
144
- React.createElement(Layout, { header: header, scrollEnabled: !itemWithoutCustomerDecission, style: {
144
+ React.createElement(Layout, { footer: null, header: header, scrollEnabled: !itemWithoutCustomerDecission, style: {
145
145
  header: fiveItemsDiscount !== 0 ? style.headerWithDoubleHeight : style.header,
146
146
  scrollView: { height: itemWithoutCustomerDecission ? "100%" : "auto" },
147
147
  safeAreaView: isDesktopScreen ? style.safeAreaView : null,
148
- } }, itemWithoutCustomerDecission ? (React.createElement(ItemWithoutCustomerDecission, { bookedProductsVariants: bookedProductsVariants, checkoutId: checkout.id, checkoutItem: checkoutItem, currentProductVariant: currentProductVariant, style: customStyle, onReturn: goToReturnPage })) : (React.createElement(ItemWithCustomerDecission, { checkoutId: checkout.id, checkoutItem: checkoutItem, currentProductVariant: currentProductVariant, returnQuestions: returnQuestions, onEditFeedback: goToReturnPage })))));
148
+ } }, itemWithoutCustomerDecission ? (React.createElement(ItemWithoutCustomerDecission, { bookedProductsVariants: bookedProductsVariants, checkoutId: checkout.id, checkoutItem: checkoutItem, currentProductVariant: currentProductVariant, onReturn: goToReturnPage })) : (React.createElement(ItemWithCustomerDecission, { checkoutId: checkout.id, checkoutItem: checkoutItem, currentProductVariant: currentProductVariant, returnQuestions: returnQuestions, onEditFeedback: goToReturnPage })))));
149
149
  };
150
150
  export { Item };
@@ -1,8 +1,6 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  interface GetOutOfCheckoutModalProps {
4
3
  readonly visible: boolean;
5
- readonly style?: StyleProp<ViewStyle>;
6
4
  readonly onDismiss: () => void;
7
5
  readonly onConfirm: () => void;
8
6
  }
@@ -2,16 +2,17 @@ import React from "react";
2
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
- import { Modal } from "@lookiero/sty-psp-ui";
5
+ import { Modal, useEnvironmentStyle } from "@lookiero/sty-psp-ui";
6
6
  import { I18nMessages } from "../../../../i18n/i18n";
7
7
  import { style } from "./GetOutOfCheckoutModal.style";
8
- const GetOutOfCheckoutModal = ({ visible, style: customStyle, onDismiss, onConfirm, }) => {
8
+ const GetOutOfCheckoutModal = ({ visible, onDismiss, onConfirm }) => {
9
+ const { modal } = useEnvironmentStyle();
9
10
  const titleText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_TITLE });
10
11
  const descriptionText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_DESCRIPTION });
11
12
  const dismissButtonText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_DISMISS_BUTTON });
12
13
  const confirmButtonText = useI18nMessage({ id: I18nMessages.GET_OUT_OF_CHECKOUT_MODAL_CONFIRM_BUTTON });
13
14
  return (React.createElement(Modal, { visible: visible, onClose: onDismiss },
14
- React.createElement(View, { style: [style.modal, customStyle] },
15
+ React.createElement(View, { style: [style.modal, modal?.content] },
15
16
  React.createElement(Text, { align: ALIGN.CENTER, level: 1, style: style.title }, titleText),
16
17
  React.createElement(Text, { level: 3, style: style.description }, descriptionText),
17
18
  React.createElement(Button, { style: style.button, onPress: onDismiss },
@@ -1,15 +1,11 @@
1
1
  import { FC } from "react";
2
- import { LayoutRectangle, StyleProp, ViewStyle } from "react-native";
2
+ import { LayoutRectangle } from "react-native";
3
3
  import { Country } from "@lookiero/sty-psp-locale";
4
4
  import { ProductVariantProjection } from "../../../../../../projection/bookedProductsVariants/bookedProductsVariants";
5
- interface ItemActionsStyle {
6
- readonly modal: StyleProp<ViewStyle>;
7
- }
8
5
  interface ItemActionsProps {
9
6
  readonly productVariants?: ProductVariantProjection[];
10
7
  readonly currentProductVariant: ProductVariantProjection;
11
8
  readonly country: Country;
12
- readonly style?: Partial<ItemActionsStyle>;
13
9
  readonly onShowSizeWithoutStockModal?: () => void;
14
10
  readonly onKeep: () => void;
15
11
  readonly onReturn: () => void;
@@ -8,7 +8,7 @@ import { Body } from "../../../../components/layouts/body/Body";
8
8
  import { I18nMessages } from "../../../../i18n/i18n";
9
9
  import { SelectModal } from "../selectModal/SelectModal";
10
10
  import { style } from "./ItemActions.style";
11
- const ItemActions = ({ productVariants, currentProductVariant, country, style: customStyle, onShowSizeWithoutStockModal = () => void 0, onKeep, onReplace, onReturn, onLayout, }) => {
11
+ const ItemActions = ({ productVariants, currentProductVariant, country, onShowSizeWithoutStockModal = () => void 0, onKeep, onReplace, onReturn, onLayout, }) => {
12
12
  const [modalVisible, setModalVisible] = useState(false);
13
13
  const changeSizeButtonText = useI18nMessage({ id: I18nMessages.ITEM_CHANGE_SIZE_BUTTON });
14
14
  const keepButtonText = useI18nMessage({ id: I18nMessages.ITEM_KEEP_BUTTON });
@@ -34,6 +34,6 @@ const ItemActions = ({ productVariants, currentProductVariant, country, style: c
34
34
  !currentProductVariant.size.unique && productVariants ? (React.createElement(Button, { style: style.sizeSelector, testID: "size-selector", variant: BUTTON_VARIANT.SECONDARY, small: true, onPress: handleOnPressSelectField }, changeSizeButtonText)) : null,
35
35
  React.createElement(Button, { style: style.returnButton, testID: "return-button", variant: BUTTON_VARIANT.SECONDARY, small: true, onPress: onReturn }, returnButtonText)),
36
36
  React.createElement(Button, { testID: "keep-button", small: true, onPress: onKeep }, keepButtonText)),
37
- React.createElement(SelectModal, { modalVisible: modalVisible, options: sizeSelectorOptions, style: { modal: customStyle?.modal }, testID: "select-field-modal", title: changeSizeButtonText, value: currentProductVariant.id, onChange: onReplace, onClose: handleOnModalClose })));
37
+ React.createElement(SelectModal, { modalVisible: modalVisible, options: sizeSelectorOptions, testID: "select-field-modal", title: changeSizeButtonText, value: currentProductVariant.id, onChange: onReplace, onClose: handleOnModalClose })));
38
38
  };
39
39
  export { ItemActions };
@@ -1,12 +1,7 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { ReturnQuestionProjection } from "../../../../../../projection/returnQuestion/returnQuestion";
4
- interface ReturnQuestionsFeedbackStyle {
5
- readonly modal: StyleProp<ViewStyle>;
6
- }
7
3
  interface ReturnQuestionsFeedbackProps {
8
4
  readonly returnQuestions: ReturnQuestionProjection[];
9
- readonly style?: Partial<ReturnQuestionsFeedbackStyle>;
10
5
  readonly onEditFeedback: () => void;
11
6
  }
12
7
  declare const ReturnQuestionsFeedback: FC<ReturnQuestionsFeedbackProps>;
@@ -17,13 +17,13 @@ const returnQuestionItems = {
17
17
  [ReturnQuestionType.TEXTAREA]: ReturnQuestionFeedbackItem,
18
18
  [ReturnQuestionType.OPTION]: ReturnQuestionFeedbackItem,
19
19
  };
20
- const ReturnQuestionsFeedback = ({ returnQuestions, style: customStyle, onEditFeedback, }) => {
20
+ const ReturnQuestionsFeedback = ({ returnQuestions, onEditFeedback }) => {
21
21
  const titleText = useI18nMessage({ id: I18nMessages.FEEDBACK_TITLE });
22
22
  return (React.createElement(View, null,
23
23
  React.createElement(View, { style: style.titleContainer },
24
24
  React.createElement(Text, { level: 2 }, titleText),
25
25
  React.createElement(ButtonIcon, { name: "pencil", testID: "edit-feedback", onPress: onEditFeedback })),
26
26
  React.createElement(ReturnQuestionItemProvider, { returnQuestionItems: returnQuestionItems },
27
- React.createElement(ReturnQuestions, { returnQuestions: returnQuestions, style: customStyle }))));
27
+ React.createElement(ReturnQuestions, { returnQuestions: returnQuestions }))));
28
28
  };
29
29
  export { ReturnQuestionsFeedback };
@@ -0,0 +1,11 @@
1
+ import { FC } from "react";
2
+ import { FeedbackProjection } from "../../../../../../projection/feedback/feedback";
3
+ import { ReturnQuestionProjection } from "../../../../../../projection/returnQuestion/returnQuestion";
4
+ interface ReturnQuestionsFormProps {
5
+ readonly visible: boolean;
6
+ readonly returnQuestions: ReturnQuestionProjection[];
7
+ readonly onSubmit: (feedback: FeedbackProjection) => void;
8
+ readonly onClose: () => void;
9
+ }
10
+ declare const ReturnQuestionsForm: FC<ReturnQuestionsFormProps>;
11
+ export { ReturnQuestionsForm };
@@ -0,0 +1,40 @@
1
+ import { PortalHost } from "@gorhom/portal";
2
+ import React, { useCallback } from "react";
3
+ import { View } from "react-native";
4
+ import { Button, Text } from "@lookiero/aurora";
5
+ import { useI18nMessage } from "@lookiero/i18n-react";
6
+ import { Modal } from "@lookiero/sty-psp-ui";
7
+ import { ReturnQuestionType, } from "../../../../../../projection/returnQuestion/returnQuestion";
8
+ import { ReturnQuestions } from "../../../../components/organisms/returnQuestions/ReturnQuestions";
9
+ import { useReturnQuestionFeedback } from "../../../../components/organisms/returnQuestions/behaviors/useReturnQuestionFeedback";
10
+ import { ReturnQuestionItemProvider, } from "../../../../components/organisms/returnQuestions/behaviors/useReturnQuestionItem";
11
+ import { HostDefaultReturnQuestionItem } from "../../../../components/organisms/returnQuestions/components/hostDefaultReturnQuestionItem/HostDefaultReturnQuestionItem";
12
+ import { HostSelectReturnQuestionItem } from "../../../../components/organisms/returnQuestions/components/hostSelectReturnQuestionItem/HostSelectReturnQuestionItem";
13
+ import { HostStackReturnQuestionItem } from "../../../../components/organisms/returnQuestions/components/hostStackReturnQuestionItem/modal/HostStackReturnQuestionItem";
14
+ import { OptionReturnQuestionItem } from "../../../../components/organisms/returnQuestions/components/optionReturnQuestionItem/OptionReturnQuestionItem";
15
+ import { TextareaReturnQuestionItem } from "../../../../components/organisms/returnQuestions/components/textareaReturnQuestionItem/TextareaReturnQuestionItem";
16
+ import { I18nMessages } from "../../../../i18n/i18n";
17
+ import { style } from "./ReturnQuestionsForm.style";
18
+ const RETURN_QUESTION_FORM_PORTAL_HOST_NAME = "return-question-form-portal";
19
+ const returnQuestionItems = {
20
+ [ReturnQuestionType.HOST_DEFAULT]: HostDefaultReturnQuestionItem,
21
+ [ReturnQuestionType.HOST_TEXTAREA]: HostDefaultReturnQuestionItem,
22
+ [ReturnQuestionType.HOST_SELECT]: HostSelectReturnQuestionItem,
23
+ [ReturnQuestionType.HOST_STACK]: HostStackReturnQuestionItem,
24
+ [ReturnQuestionType.TEXTAREA]: TextareaReturnQuestionItem,
25
+ [ReturnQuestionType.OPTION]: OptionReturnQuestionItem,
26
+ };
27
+ const ReturnQuestionsForm = ({ returnQuestions, visible, onSubmit, onClose }) => {
28
+ const titleText = useI18nMessage({ id: I18nMessages.RETURN_QUESTIONS_TITLE });
29
+ const submitButtonText = useI18nMessage({ id: I18nMessages.RETURN_QUESTIONS_SUBMIT_BUTTON });
30
+ const feedback = useReturnQuestionFeedback();
31
+ const handleOnSubmit = useCallback(() => onSubmit(feedback), [feedback, onSubmit]);
32
+ return (React.createElement(ReturnQuestionItemProvider, { returnQuestionItems: returnQuestionItems },
33
+ React.createElement(PortalHost, { name: RETURN_QUESTION_FORM_PORTAL_HOST_NAME }),
34
+ React.createElement(Modal, { portalHostName: RETURN_QUESTION_FORM_PORTAL_HOST_NAME, testID: "return-questions-form-modal", visible: visible, scroll: true, showCloseButton: true, onClose: onClose },
35
+ React.createElement(View, { style: style.modalContent },
36
+ React.createElement(Text, { level: 3, style: style.title, heading: true }, titleText),
37
+ React.createElement(ReturnQuestions, { portalHostName: RETURN_QUESTION_FORM_PORTAL_HOST_NAME, returnQuestions: returnQuestions }),
38
+ React.createElement(Button, { style: style.submit, testID: "return-questions-button", onPress: handleOnSubmit }, submitButtonText)))));
39
+ };
40
+ export { ReturnQuestionsForm };
@@ -0,0 +1,12 @@
1
+ declare const style: {
2
+ modalContent: {
3
+ paddingHorizontal: number;
4
+ };
5
+ submit: {
6
+ marginTop: number;
7
+ };
8
+ title: {
9
+ marginBottom: number;
10
+ };
11
+ };
12
+ export { style };
@@ -0,0 +1,15 @@
1
+ import { StyleSheet } from "react-native";
2
+ import { theme } from "@lookiero/sty-psp-ui";
3
+ const { space6, space8 } = theme();
4
+ const style = StyleSheet.create({
5
+ modalContent: {
6
+ paddingHorizontal: space6,
7
+ },
8
+ submit: {
9
+ marginTop: space8,
10
+ },
11
+ title: {
12
+ marginBottom: space6,
13
+ },
14
+ });
15
+ export { style };
@@ -1,10 +1,4 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, TextStyle, ViewStyle } from "react-native";
3
- interface SelectModalStyle {
4
- readonly modal: StyleProp<ViewStyle>;
5
- readonly option: StyleProp<ViewStyle>;
6
- readonly optionText: StyleProp<TextStyle>;
7
- }
8
2
  interface Option {
9
3
  readonly label: string;
10
4
  readonly value: string;
@@ -13,7 +7,6 @@ interface SelectModalProps {
13
7
  readonly title?: string;
14
8
  readonly value: string | undefined;
15
9
  readonly options: Option[];
16
- readonly style?: Partial<SelectModalStyle>;
17
10
  readonly modalVisible: boolean;
18
11
  readonly testID?: string;
19
12
  readonly onChange?: (value: string) => void;
@@ -1,18 +1,19 @@
1
1
  import React, { useCallback } from "react";
2
2
  import { TouchableHighlight, View } from "react-native";
3
3
  import { COLOR, Text } from "@lookiero/aurora";
4
- import { Modal, theme } from "@lookiero/sty-psp-ui";
4
+ import { Modal, theme, useEnvironmentStyle } from "@lookiero/sty-psp-ui";
5
5
  import { style } from "./SelectModal.style";
6
6
  const { colorBgPrimaryLight } = theme();
7
- const SelectModal = ({ modalVisible, options, style: customStyle, testID, title, value, onChange = () => void 0, onClose = () => void 0, }) => {
7
+ const SelectModal = ({ modalVisible, options, testID, title, value, onChange = () => void 0, onClose = () => void 0, }) => {
8
+ const { modal } = useEnvironmentStyle();
8
9
  const handleOnPressOption = useCallback((value) => {
9
10
  onChange(value);
10
11
  onClose();
11
12
  }, [onClose, onChange]);
12
13
  return (React.createElement(Modal, { testID: testID, visible: modalVisible, scroll: true, showCloseButton: true, onClose: onClose },
13
- React.createElement(View, { style: [style.modal, customStyle?.modal] },
14
+ React.createElement(View, { style: [style.modal, modal?.content] },
14
15
  title && (React.createElement(Text, { level: 3, style: style.modalTitle, heading: true }, title)),
15
- options.map(({ label, value: optionValue }) => (React.createElement(TouchableHighlight, { key: optionValue, accessibilityLabel: optionValue, disabled: value === optionValue, style: [style.option, customStyle?.option], testID: optionValue, underlayColor: colorBgPrimaryLight, accessible: true, onPress: value !== optionValue ? () => handleOnPressOption(optionValue) : undefined },
16
- React.createElement(Text, { color: value === optionValue ? COLOR.TEXT_MEDIUM : COLOR.TEXT, level: 3, style: [style.optionText, customStyle?.optionText] }, label)))))));
16
+ options.map(({ label, value: optionValue }) => (React.createElement(TouchableHighlight, { key: optionValue, accessibilityLabel: optionValue, disabled: value === optionValue, style: style.option, testID: optionValue, underlayColor: colorBgPrimaryLight, accessible: true, onPress: value !== optionValue ? () => handleOnPressOption(optionValue) : undefined },
17
+ React.createElement(Text, { color: value === optionValue ? COLOR.TEXT_MEDIUM : COLOR.TEXT, level: 3, style: style.optionText }, label)))))));
17
18
  };
18
19
  export { SelectModal };
@@ -1,8 +1,6 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  interface SizeWithoutStockModalProps {
4
3
  readonly visible: boolean;
5
- readonly style?: StyleProp<ViewStyle>;
6
4
  readonly onDismiss: () => void;
7
5
  }
8
6
  declare const SizeWithoutStockModal: FC<SizeWithoutStockModalProps>;
@@ -2,15 +2,16 @@ import React from "react";
2
2
  import { View } from "react-native";
3
3
  import { Button, Text } from "@lookiero/aurora";
4
4
  import { useI18nMessage } from "@lookiero/i18n-react";
5
- import { Modal } from "@lookiero/sty-psp-ui";
5
+ import { Modal, useEnvironmentStyle } from "@lookiero/sty-psp-ui";
6
6
  import { I18nMessages } from "../../../../i18n/i18n";
7
7
  import { style } from "./SizeWithoutStockModal.style";
8
- const SizeWithoutStockModal = ({ visible, style: customStyle, onDismiss }) => {
8
+ const SizeWithoutStockModal = ({ visible, onDismiss }) => {
9
+ const { modal } = useEnvironmentStyle();
9
10
  const titleText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_TITLE });
10
11
  const descriptionText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_DESCRIPTION });
11
12
  const buttonText = useI18nMessage({ id: I18nMessages.SIZE_WITHOUT_STOCK_MODAL_BUTTON });
12
13
  return (React.createElement(Modal, { visible: visible, showCloseButton: true, onClose: onDismiss },
13
- React.createElement(View, { style: [style.modalContent, customStyle] },
14
+ React.createElement(View, { style: [style.modalContent, modal?.content] },
14
15
  React.createElement(Text, { level: 3, style: style.title, heading: true }, titleText),
15
16
  React.createElement(Text, { level: 3, style: style.description }, descriptionText),
16
17
  React.createElement(Button, { onPress: onDismiss }, buttonText))));
@@ -1,12 +1,8 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { CheckoutItemStatus } from "../../../../../../domain/checkoutItem/model/checkoutItem";
4
3
  import { ProductVariantProjection } from "../../../../../../projection/bookedProductsVariants/bookedProductsVariants";
5
4
  import { CheckoutItemProjection } from "../../../../../../projection/checkoutItem/checkoutItem";
6
5
  import { ReturnQuestionProjection } from "../../../../../../projection/returnQuestion/returnQuestion";
7
- interface ItemWithCustomerDecissionStyle {
8
- readonly modal: StyleProp<ViewStyle>;
9
- }
10
6
  interface CheckoutItemWithCustomerDecission extends CheckoutItemProjection {
11
7
  readonly status: Exclude<CheckoutItemStatus, CheckoutItemStatus.INITIAL>;
12
8
  }
@@ -15,7 +11,6 @@ interface ItemWithCustomerDecissionProps {
15
11
  readonly checkoutItem: CheckoutItemWithCustomerDecission;
16
12
  readonly returnQuestions: ReturnQuestionProjection[];
17
13
  readonly currentProductVariant: ProductVariantProjection;
18
- readonly style?: Partial<ItemWithCustomerDecissionStyle>;
19
14
  readonly onEditFeedback: () => void;
20
15
  }
21
16
  declare const ItemWithCustomerDecission: FC<ItemWithCustomerDecissionProps>;
@@ -14,7 +14,7 @@ import { CustomerDecissionBanner, } from "../../components/banner/CustomerDeciss
14
14
  import { ReturnQuestionsFeedback } from "../../components/returnQuestionsFeedback/ReturnQuestionsFeedback";
15
15
  import { ProductVariant } from "../../views/productVariant/ProductVariant";
16
16
  import { style } from "./ItemWithCustomerDecission.style";
17
- const ItemWithCustomerDecission = ({ checkoutId, checkoutItem, returnQuestions, currentProductVariant, style: customStyle, onEditFeedback, }) => {
17
+ const ItemWithCustomerDecission = ({ checkoutId, checkoutItem, returnQuestions, currentProductVariant, onEditFeedback, }) => {
18
18
  const screenSize = useScreenSize();
19
19
  const isMobile = screenSize === "S";
20
20
  const logger = useLogger();
@@ -42,6 +42,6 @@ const ItemWithCustomerDecission = ({ checkoutId, checkoutItem, returnQuestions,
42
42
  }
43
43
  return (React.createElement(Body, { style: { row: style.container } },
44
44
  React.createElement(ProductVariant, { checkoutId: checkoutId, checkoutItem: checkoutItem, country: country, currentProductVariant: currentProductVariant, segment: segment, customerDecissionBanner: React.createElement(CustomerDecissionBanner, { checkoutItemStatus: checkoutItem.status, onPress: resetItem }) }, checkoutItem.status === CheckoutItemStatus.RETURNED && (React.createElement(View, { style: [style.feedbackContainer, isMobile ? style.feedbackContainerMobile : undefined] },
45
- React.createElement(ReturnQuestionsFeedback, { returnQuestions: returnQuestions, style: customStyle, onEditFeedback: onEditFeedback }))))));
45
+ React.createElement(ReturnQuestionsFeedback, { returnQuestions: returnQuestions, onEditFeedback: onEditFeedback }))))));
46
46
  };
47
47
  export { ItemWithCustomerDecission };
@@ -1,12 +1,8 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { CheckoutItemStatus } from "../../../../../../domain/checkoutItem/model/checkoutItem";
4
3
  import { BookedProductsVariantsProjection, ProductVariantProjection } from "../../../../../../projection/bookedProductsVariants/bookedProductsVariants";
5
4
  import "../../../../../../projection/checkout/viewFirstAvailableCheckoutByCustomerId";
6
5
  import { CheckoutItemProjection } from "../../../../../../projection/checkoutItem/checkoutItem";
7
- interface ItemWithoutCustomerDecissionStyle {
8
- readonly modal: StyleProp<ViewStyle>;
9
- }
10
6
  interface CheckoutItemWithoutCustomerDecission extends CheckoutItemProjection {
11
7
  readonly status: CheckoutItemStatus.INITIAL;
12
8
  }
@@ -15,7 +11,6 @@ interface ItemWithoutCustomerDecissionProps {
15
11
  readonly checkoutItem: CheckoutItemWithoutCustomerDecission;
16
12
  readonly bookedProductsVariants: BookedProductsVariantsProjection;
17
13
  readonly currentProductVariant: ProductVariantProjection;
18
- readonly style?: Partial<ItemWithoutCustomerDecissionStyle>;
19
14
  readonly onReturn: () => void;
20
15
  }
21
16
  declare const ItemWithoutCustomerDecission: FC<ItemWithoutCustomerDecissionProps>;
@@ -17,7 +17,7 @@ import { SizeWithoutStockModal } from "../../components/sizeWithoutStockModal/Si
17
17
  import { ProductVariant } from "../productVariant/ProductVariant";
18
18
  import { style } from "./ItemWithoutCustomerDecission.style";
19
19
  const { space6 } = theme();
20
- const ItemWithoutCustomerDecission = ({ checkoutId, checkoutItem, bookedProductsVariants, currentProductVariant, style: customStyle, onReturn, }) => {
20
+ const ItemWithoutCustomerDecission = ({ checkoutId, checkoutItem, bookedProductsVariants, currentProductVariant, onReturn, }) => {
21
21
  const logger = useLogger();
22
22
  const { customer: { country, segment }, } = useStaticInfo();
23
23
  /* KeepCheckoutItem */
@@ -62,7 +62,7 @@ const ItemWithoutCustomerDecission = ({ checkoutId, checkoutItem, bookedProducts
62
62
  return React.createElement(Spinner, { testID: "spinner" });
63
63
  }
64
64
  return (React.createElement(React.Fragment, null,
65
- React.createElement(SizeWithoutStockModal, { style: customStyle?.modal, visible: sizeWithoutStockModalVisible, onDismiss: handleOnHideSizeWithoutStockModal }),
65
+ React.createElement(SizeWithoutStockModal, { visible: sizeWithoutStockModalVisible, onDismiss: handleOnHideSizeWithoutStockModal }),
66
66
  React.createElement(ScrollView, { showsVerticalScrollIndicator: false },
67
67
  React.createElement(Body, { style: { row: style.container } },
68
68
  React.createElement(ProductVariant, { checkoutId: checkoutId, checkoutItem: checkoutItem, country: country, currentProductVariant: currentProductVariant, segment: segment, style: { content: { paddingBottom: Platform.OS === "web" ? space6 : stickyHeight } } }))),
@@ -1,12 +1,7 @@
1
1
  import { FC } from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
2
  import { Layout as UiLayout } from "@lookiero/sty-psp-ui";
4
- interface ReturnStyle {
5
- readonly modal: StyleProp<ViewStyle>;
6
- }
7
3
  interface ReturnProps {
8
4
  readonly layout: UiLayout;
9
- readonly style?: Partial<ReturnStyle>;
10
5
  }
11
6
  declare const Return: FC<ReturnProps>;
12
7
  export { Return };
@@ -6,7 +6,7 @@ import { useViewFirstAvailableCheckoutByCustomerId } from "../../../projection/c
6
6
  import { ReturnQuestionFeedbackProvider } from "../../components/organisms/returnQuestions/behaviors/useReturnQuestionFeedback";
7
7
  import { useStaticInfo } from "../../hooks/useStaticInfo";
8
8
  import { ReturnQuestionsForm } from "./components/returnQuestionsForm/ReturnQuestionsForm";
9
- const Return = ({ layout, style: customStyle }) => {
9
+ const Return = ({ layout }) => {
10
10
  const { id } = useParams();
11
11
  const { customer: { customerId, country, segment }, } = useStaticInfo();
12
12
  const [checkout, checkoutStatus] = useViewFirstAvailableCheckoutByCustomerId({ customerId });
@@ -16,6 +16,6 @@ const Return = ({ layout, style: customStyle }) => {
16
16
  return React.createElement(Spinner, null);
17
17
  }
18
18
  return (React.createElement(ReturnQuestionFeedbackProvider, { key: checkoutItem.id, feedback: checkoutItem.feedbacks || {} },
19
- React.createElement(ReturnQuestionsForm, { checkout: checkout, checkoutItem: checkoutItem, country: country, layout: layout, segment: segment, style: customStyle })));
19
+ React.createElement(ReturnQuestionsForm, { checkout: checkout, checkoutItem: checkoutItem, country: country, layout: layout, segment: segment })));
20
20
  };
21
21
  export { Return };
@@ -0,0 +1,40 @@
1
+ declare const style: {
2
+ description: {
3
+ color: string;
4
+ };
5
+ desktopInfo: {
6
+ borderTopLeftRadius: number;
7
+ borderTopRightRadius: number;
8
+ };
9
+ desktopLayoutSpacing: {
10
+ paddingVertical: number;
11
+ };
12
+ headerWrapper: {
13
+ display: "flex";
14
+ flexDirection: "column";
15
+ };
16
+ info: {
17
+ backgroundColor: string;
18
+ paddingBottom: number;
19
+ paddingHorizontal: number;
20
+ paddingTop: number;
21
+ };
22
+ layout: {
23
+ flex: number;
24
+ justifyContent: "center";
25
+ };
26
+ safeAreaView: {
27
+ backgroundColor: string;
28
+ flex: number;
29
+ };
30
+ scrollView: {
31
+ flex: number;
32
+ };
33
+ submit: {
34
+ backgroundColor: string;
35
+ borderBottomLeftRadius: number;
36
+ borderBottomRightRadius: number;
37
+ padding: number;
38
+ };
39
+ };
40
+ export { style };