@moneylion/react-native-offer-carousel 1.0.5 → 1.0.6

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 (173) hide show
  1. package/lib/commonjs/capabilities/offer-catalog/src/api/offerCatalogApi.js.map +1 -1
  2. package/lib/commonjs/components/Cards/VideosCard/VideosCard.js +3 -3
  3. package/lib/commonjs/components/Common/BaseOfferCard/index.js +5 -5
  4. package/lib/commonjs/components/Common/BaseOfferCard/index.js.map +1 -1
  5. package/lib/commonjs/components/Common/DynamicOfferCard/CallToAction.js.map +1 -1
  6. package/lib/commonjs/components/Common/DynamicOfferCard/SeeMore.js.map +1 -1
  7. package/lib/commonjs/components/Common/DynamicOfferCard/index.js +2 -2
  8. package/lib/commonjs/components/Common/DynamicOfferCard/index.js.map +1 -1
  9. package/lib/commonjs/components/DynamicOffers/DynamicOffers.js +2 -2
  10. package/lib/commonjs/components/DynamicOffers/DynamicOffers.js.map +1 -1
  11. package/lib/commonjs/components/DynamicOffers/DynamicOffersContainer.js +1 -1
  12. package/lib/commonjs/components/DynamicOffers/DynamicOffersContainer.js.map +1 -1
  13. package/lib/commonjs/components/DynamicOffers/Render/DynamicOffersRender.js +5 -5
  14. package/lib/commonjs/components/DynamicOffers/Render/DynamicOffersRender.js.map +1 -1
  15. package/lib/commonjs/components/DynamicOffers/Render/FallbackOfferTemplate.js +2 -2
  16. package/lib/commonjs/components/DynamicOffers/Render/FallbackOfferTemplate.js.map +1 -1
  17. package/lib/commonjs/components/DynamicOffers/Render/Offer.js +5 -4
  18. package/lib/commonjs/components/DynamicOffers/Render/Offer.js.map +1 -1
  19. package/lib/commonjs/components/Layouts/CreditCardOfferCard/index.js +2 -2
  20. package/lib/commonjs/components/Layouts/CreditCardOfferCard/index.js.map +1 -1
  21. package/lib/commonjs/components/Layouts/CreditCardOfferCard/statsBuilder.js +1 -1
  22. package/lib/commonjs/components/Layouts/DefaultOfferCard/index.js +2 -2
  23. package/lib/commonjs/components/Layouts/DefaultOfferCard/index.js.map +1 -1
  24. package/lib/commonjs/components/Layouts/DefaultOfferCard/statsBuilder.js +1 -1
  25. package/lib/commonjs/components/Layouts/HeadlineWithDescriptionCard/index.js +2 -2
  26. package/lib/commonjs/components/Layouts/HeadlineWithDescriptionCard/index.js.map +1 -1
  27. package/lib/commonjs/components/Modal/OfferDetailsModal.js.map +1 -1
  28. package/lib/commonjs/components/MoneyLionOfferCarousel.js +3 -3
  29. package/lib/commonjs/components/MoneyLionOfferCarousel.js.map +1 -1
  30. package/lib/commonjs/components/View/index.js +3 -2
  31. package/lib/commonjs/components/View/index.js.map +1 -1
  32. package/lib/commonjs/pageData.js +4 -3
  33. package/lib/commonjs/pageData.js.map +1 -1
  34. package/lib/commonjs/services/getDynamicOffers.js.map +1 -1
  35. package/lib/commonjs/services/getProductTypesByQuery.js +1 -1
  36. package/lib/commonjs/services/getProductTypesByQuery.js.map +1 -1
  37. package/lib/commonjs/utils/formatOfferUrl.js +1 -1
  38. package/lib/commonjs/utils/getOffersByProductTypes.js +2 -2
  39. package/lib/commonjs/utils/getOffersByProductTypes.js.map +1 -1
  40. package/lib/commonjs/utils/selectDynamicOffers.js.map +1 -1
  41. package/lib/module/capabilities/offer-catalog/src/api/offerCatalogApi.js.map +1 -1
  42. package/lib/module/components/Cards/VideosCard/VideosCard.js +3 -3
  43. package/lib/module/components/Common/BaseOfferCard/index.js +5 -5
  44. package/lib/module/components/Common/BaseOfferCard/index.js.map +1 -1
  45. package/lib/module/components/Common/DynamicOfferCard/CallToAction.js.map +1 -1
  46. package/lib/module/components/Common/DynamicOfferCard/SeeMore.js.map +1 -1
  47. package/lib/module/components/Common/DynamicOfferCard/index.js +2 -2
  48. package/lib/module/components/Common/DynamicOfferCard/index.js.map +1 -1
  49. package/lib/module/components/DynamicOffers/DynamicOffers.js +2 -2
  50. package/lib/module/components/DynamicOffers/DynamicOffers.js.map +1 -1
  51. package/lib/module/components/DynamicOffers/DynamicOffersContainer.js +1 -1
  52. package/lib/module/components/DynamicOffers/DynamicOffersContainer.js.map +1 -1
  53. package/lib/module/components/DynamicOffers/Render/DynamicOffersRender.js +5 -5
  54. package/lib/module/components/DynamicOffers/Render/DynamicOffersRender.js.map +1 -1
  55. package/lib/module/components/DynamicOffers/Render/FallbackOfferTemplate.js +2 -2
  56. package/lib/module/components/DynamicOffers/Render/FallbackOfferTemplate.js.map +1 -1
  57. package/lib/module/components/DynamicOffers/Render/Offer.js +5 -4
  58. package/lib/module/components/DynamicOffers/Render/Offer.js.map +1 -1
  59. package/lib/module/components/Layouts/CreditCardOfferCard/index.js +2 -2
  60. package/lib/module/components/Layouts/CreditCardOfferCard/index.js.map +1 -1
  61. package/lib/module/components/Layouts/CreditCardOfferCard/statsBuilder.js +1 -1
  62. package/lib/module/components/Layouts/CreditCardOfferCard/statsBuilder.js.map +1 -1
  63. package/lib/module/components/Layouts/DefaultOfferCard/index.js +2 -2
  64. package/lib/module/components/Layouts/DefaultOfferCard/index.js.map +1 -1
  65. package/lib/module/components/Layouts/DefaultOfferCard/statsBuilder.js +1 -1
  66. package/lib/module/components/Layouts/DefaultOfferCard/statsBuilder.js.map +1 -1
  67. package/lib/module/components/Layouts/HeadlineWithDescriptionCard/index.js +2 -2
  68. package/lib/module/components/Layouts/HeadlineWithDescriptionCard/index.js.map +1 -1
  69. package/lib/module/components/Modal/OfferDetailsModal.js.map +1 -1
  70. package/lib/module/components/MoneyLionOfferCarousel.js +3 -3
  71. package/lib/module/components/MoneyLionOfferCarousel.js.map +1 -1
  72. package/lib/module/components/View/index.js +3 -2
  73. package/lib/module/components/View/index.js.map +1 -1
  74. package/lib/module/pageData.js +4 -3
  75. package/lib/module/pageData.js.map +1 -1
  76. package/lib/module/services/getDynamicOffers.js.map +1 -1
  77. package/lib/module/services/getProductTypesByQuery.js +1 -1
  78. package/lib/module/services/getProductTypesByQuery.js.map +1 -1
  79. package/lib/module/utils/formatOfferUrl.js +1 -1
  80. package/lib/module/utils/formatOfferUrl.js.map +1 -1
  81. package/lib/module/utils/getOffersByProductTypes.js +3 -2
  82. package/lib/module/utils/getOffersByProductTypes.js.map +1 -1
  83. package/lib/module/utils/selectDynamicOffers.js.map +1 -1
  84. package/lib/typescript/src/capabilities/offer-catalog/src/api/offerCatalogApi.d.ts +1 -1
  85. package/lib/typescript/src/capabilities/offer-catalog/src/api/offerCatalogApi.d.ts.map +1 -1
  86. package/lib/typescript/src/components/Common/BaseOfferCard/index.d.ts +3 -3
  87. package/lib/typescript/src/components/Common/BaseOfferCard/index.d.ts.map +1 -1
  88. package/lib/typescript/src/components/Common/DynamicOfferCard/CallToAction.d.ts +1 -1
  89. package/lib/typescript/src/components/Common/DynamicOfferCard/CallToAction.d.ts.map +1 -1
  90. package/lib/typescript/src/components/Common/DynamicOfferCard/SeeMore.d.ts +1 -1
  91. package/lib/typescript/src/components/Common/DynamicOfferCard/SeeMore.d.ts.map +1 -1
  92. package/lib/typescript/src/components/Common/DynamicOfferCard/index.d.ts +3 -3
  93. package/lib/typescript/src/components/Common/DynamicOfferCard/index.d.ts.map +1 -1
  94. package/lib/typescript/src/components/DynamicOffers/DynamicOffers.d.ts +2 -2
  95. package/lib/typescript/src/components/DynamicOffers/DynamicOffers.d.ts.map +1 -1
  96. package/lib/typescript/src/components/DynamicOffers/Render/DynamicOffersRender.d.ts +3 -3
  97. package/lib/typescript/src/components/DynamicOffers/Render/DynamicOffersRender.d.ts.map +1 -1
  98. package/lib/typescript/src/components/DynamicOffers/Render/FallbackOfferTemplate.d.ts +3 -3
  99. package/lib/typescript/src/components/DynamicOffers/Render/FallbackOfferTemplate.d.ts.map +1 -1
  100. package/lib/typescript/src/components/DynamicOffers/Render/Offer.d.ts +5 -4
  101. package/lib/typescript/src/components/DynamicOffers/Render/Offer.d.ts.map +1 -1
  102. package/lib/typescript/src/components/Layouts/CreditCardOfferCard/index.d.ts +3 -3
  103. package/lib/typescript/src/components/Layouts/CreditCardOfferCard/index.d.ts.map +1 -1
  104. package/lib/typescript/src/components/Layouts/CreditCardOfferCard/statsBuilder.d.ts +2 -2
  105. package/lib/typescript/src/components/Layouts/CreditCardOfferCard/statsBuilder.d.ts.map +1 -1
  106. package/lib/typescript/src/components/Layouts/DefaultOfferCard/index.d.ts +3 -3
  107. package/lib/typescript/src/components/Layouts/DefaultOfferCard/index.d.ts.map +1 -1
  108. package/lib/typescript/src/components/Layouts/DefaultOfferCard/statsBuilder.d.ts +3 -3
  109. package/lib/typescript/src/components/Layouts/DefaultOfferCard/statsBuilder.d.ts.map +1 -1
  110. package/lib/typescript/src/components/Layouts/HeadlineWithDescriptionCard/index.d.ts +3 -3
  111. package/lib/typescript/src/components/Layouts/HeadlineWithDescriptionCard/index.d.ts.map +1 -1
  112. package/lib/typescript/src/components/Modal/OfferDetailsModal.d.ts +1 -1
  113. package/lib/typescript/src/components/Modal/OfferDetailsModal.d.ts.map +1 -1
  114. package/lib/typescript/src/components/MoneyLionOfferCarousel.d.ts +1 -0
  115. package/lib/typescript/src/components/MoneyLionOfferCarousel.d.ts.map +1 -1
  116. package/lib/typescript/src/components/View/index.d.ts.map +1 -1
  117. package/lib/typescript/src/context/EventHandlerProvider.d.ts +1 -1
  118. package/lib/typescript/src/context/EventHandlerProvider.d.ts.map +1 -1
  119. package/lib/typescript/src/pageData.d.ts +2 -1
  120. package/lib/typescript/src/pageData.d.ts.map +1 -1
  121. package/lib/typescript/src/services/getDynamicOffers.d.ts +3 -3
  122. package/lib/typescript/src/services/getDynamicOffers.d.ts.map +1 -1
  123. package/lib/typescript/src/utils/addClientTagsToOfferLinks.d.ts +1 -1
  124. package/lib/typescript/src/utils/addClientTagsToOfferLinks.d.ts.map +1 -1
  125. package/lib/typescript/src/utils/formatOfferUrl.d.ts +6 -1
  126. package/lib/typescript/src/utils/formatOfferUrl.d.ts.map +1 -1
  127. package/lib/typescript/src/utils/getDefaultProductType.d.ts +1 -1
  128. package/lib/typescript/src/utils/getDefaultProductType.d.ts.map +1 -1
  129. package/lib/typescript/src/utils/getEnableUseCachedOffers.d.ts +1 -1
  130. package/lib/typescript/src/utils/getEnableUseCachedOffers.d.ts.map +1 -1
  131. package/lib/typescript/src/utils/getOffersBasedOnLayout.d.ts +1 -1
  132. package/lib/typescript/src/utils/getOffersBasedOnLayout.d.ts.map +1 -1
  133. package/lib/typescript/src/utils/getOffersByProductTypes.d.ts +1 -1
  134. package/lib/typescript/src/utils/getOffersByProductTypes.d.ts.map +1 -1
  135. package/lib/typescript/src/utils/getProductTypesDefinition.d.ts +1 -1
  136. package/lib/typescript/src/utils/getProductTypesDefinition.d.ts.map +1 -1
  137. package/lib/typescript/src/utils/selectDynamicOffers.d.ts +1 -1
  138. package/lib/typescript/src/utils/selectDynamicOffers.d.ts.map +1 -1
  139. package/lib/typescript/src/utils/sortOffersByRecommendationScore.d.ts +1 -1
  140. package/lib/typescript/src/utils/sortOffersByRecommendationScore.d.ts.map +1 -1
  141. package/package.json +1 -1
  142. package/src/capabilities/offer-catalog/src/api/offerCatalogApi.ts +1 -1
  143. package/src/components/Cards/VideosCard/VideosCard.tsx +3 -3
  144. package/src/components/Common/BaseOfferCard/index.tsx +6 -6
  145. package/src/components/Common/DynamicOfferCard/CallToAction.tsx +1 -1
  146. package/src/components/Common/DynamicOfferCard/SeeMore.tsx +1 -1
  147. package/src/components/Common/DynamicOfferCard/index.tsx +4 -4
  148. package/src/components/DynamicOffers/DynamicOffers.tsx +3 -3
  149. package/src/components/DynamicOffers/DynamicOffersContainer.tsx +1 -1
  150. package/src/components/DynamicOffers/Render/DynamicOffersRender.tsx +7 -7
  151. package/src/components/DynamicOffers/Render/FallbackOfferTemplate.tsx +4 -4
  152. package/src/components/DynamicOffers/Render/Offer.tsx +9 -6
  153. package/src/components/Layouts/CreditCardOfferCard/index.tsx +4 -5
  154. package/src/components/Layouts/CreditCardOfferCard/statsBuilder.tsx +2 -2
  155. package/src/components/Layouts/DefaultOfferCard/index.tsx +4 -5
  156. package/src/components/Layouts/DefaultOfferCard/statsBuilder.tsx +2 -2
  157. package/src/components/Layouts/HeadlineWithDescriptionCard/index.tsx +4 -4
  158. package/src/components/Modal/OfferDetailsModal.tsx +1 -1
  159. package/src/components/MoneyLionOfferCarousel.tsx +5 -4
  160. package/src/components/View/index.tsx +2 -7
  161. package/src/context/EventHandlerProvider.tsx +1 -1
  162. package/src/pageData.ts +5 -3
  163. package/src/services/getDynamicOffers.ts +5 -5
  164. package/src/services/getProductTypesByQuery.ts +1 -1
  165. package/src/utils/addClientTagsToOfferLinks.ts +1 -1
  166. package/src/utils/formatOfferUrl.ts +1 -1
  167. package/src/utils/getDefaultProductType.ts +1 -1
  168. package/src/utils/getEnableUseCachedOffers.ts +1 -1
  169. package/src/utils/getOffersBasedOnLayout.ts +1 -1
  170. package/src/utils/getOffersByProductTypes.ts +4 -3
  171. package/src/utils/getProductTypesDefinition.ts +1 -1
  172. package/src/utils/selectDynamicOffers.ts +1 -2
  173. package/src/utils/sortOffersByRecommendationScore.ts +1 -1
@@ -5,7 +5,6 @@ import React, {
5
5
  useRef,
6
6
  useState,
7
7
  } from "react";
8
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src/types/offerCatalogSchema";
9
8
  import type { Layout } from "../../../utils";
10
9
  import { productTypeBuilder as builder } from "../../../builder/builder";
11
10
  import { Offer } from "./Offer";
@@ -19,6 +18,7 @@ import {
19
18
  type NativeSyntheticEvent,
20
19
  } from "react-native";
21
20
  import { useEventHandler } from "../../../context/EventHandlerProvider";
21
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
22
22
 
23
23
  export type DynamicOffersRenderProps = {
24
24
  title: string;
@@ -30,7 +30,7 @@ export type DynamicOffersRenderProps = {
30
30
  offerIndex: number;
31
31
  }>;
32
32
  productTypeBuilder: typeof builder;
33
- showBorder: boolean;
33
+ showCardBorder: boolean;
34
34
  showProductTypeLabel?: boolean;
35
35
  };
36
36
 
@@ -40,7 +40,7 @@ export const DynamicOffersRender = ({
40
40
  displayLayout,
41
41
  productTypeBuilder = builder,
42
42
  fallbackTemplate,
43
- showBorder,
43
+ showCardBorder,
44
44
  showProductTypeLabel,
45
45
  }: DynamicOffersRenderProps) => {
46
46
  // Performance optimization: store card measurements
@@ -178,13 +178,13 @@ export const DynamicOffersRender = ({
178
178
  // Create offer components
179
179
  return displayLayout === "fixed"
180
180
  ? [
181
- // <VideosCard key="videos-card" videosContent={videosContent} showBorder={showBorder} />,
181
+ // <VideosCard key="videos-card" videosContent={videosContent} showCardBorder={showCardBorder} />,
182
182
  ...Offer({
183
183
  productTypeBuilder,
184
184
  offers,
185
185
  showProductTypeLabel,
186
186
  fallbackTemplate,
187
- showBorder,
187
+ showCardBorder,
188
188
  }),
189
189
  ]
190
190
  : Offer({
@@ -192,7 +192,7 @@ export const DynamicOffersRender = ({
192
192
  offers,
193
193
  showProductTypeLabel,
194
194
  fallbackTemplate,
195
- showBorder,
195
+ showCardBorder,
196
196
  });
197
197
  }, [
198
198
  displayLayout,
@@ -200,7 +200,7 @@ export const DynamicOffersRender = ({
200
200
  offers,
201
201
  showProductTypeLabel,
202
202
  fallbackTemplate,
203
- showBorder,
203
+ showCardBorder,
204
204
  ]);
205
205
 
206
206
  // Wrapped offer components with layout measurement
@@ -1,16 +1,16 @@
1
1
  import React from "react";
2
2
  import { HeadlineWithDescriptionCard } from "../../Layouts/HeadlineWithDescriptionCard";
3
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
3
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
4
4
 
5
5
  export function FallbackOfferTemplate({
6
6
  offer,
7
7
  offerIndex,
8
- showBorder = true,
8
+ showCardBorder = true,
9
9
  showProductTypeLabel = true,
10
10
  }: {
11
11
  offer: BaseOffer;
12
12
  offerIndex: number;
13
- showBorder?: boolean;
13
+ showCardBorder?: boolean;
14
14
  showProductTypeLabel?: boolean;
15
15
  }) {
16
16
  return (
@@ -22,7 +22,7 @@ export function FallbackOfferTemplate({
22
22
  productTypes: [],
23
23
  layout: "headlineWithDescriptionCard",
24
24
  }}
25
- showBorder={showBorder}
25
+ showCardBorder={showCardBorder}
26
26
  showProductTypeLabel={showProductTypeLabel}
27
27
  />
28
28
  );
@@ -3,12 +3,12 @@ import React, { Fragment } from "react";
3
3
  import { match } from "ts-pattern";
4
4
 
5
5
  import type { ProductTypeBuilder } from "../../../builder";
6
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
7
6
  import {
8
7
  DefaultOfferCard,
9
8
  CreditCardOfferCard,
10
9
  HeadlineWithDescriptionCard,
11
10
  } from "../../Layouts";
11
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
12
12
 
13
13
  type RenderOfferListProps = {
14
14
  productTypeBuilder: ProductTypeBuilder;
@@ -17,12 +17,14 @@ type RenderOfferListProps = {
17
17
  offer,
18
18
  offerIndex,
19
19
  showProductTypeLabel,
20
+ showCardBorder,
20
21
  }: {
21
22
  offer: BaseOffer;
22
23
  offerIndex: number;
23
24
  showProductTypeLabel?: boolean;
25
+ showCardBorder?: boolean;
24
26
  }) => React.ReactNode;
25
- showBorder?: boolean;
27
+ showCardBorder?: boolean;
26
28
  showProductTypeLabel?: boolean;
27
29
  // featureClient?: CnfFeatureClient; TODO: this is the like split on cnf side it uses growthbook
28
30
  };
@@ -32,7 +34,7 @@ export const Offer = ({
32
34
  offers,
33
35
  showProductTypeLabel = true,
34
36
  fallbackTemplate,
35
- showBorder = true,
37
+ showCardBorder = true,
36
38
  }: RenderOfferListProps) =>
37
39
  offers.map((offer: BaseOffer, offerIndex: number) => {
38
40
  const builder = productTypeBuilder.find(({ productTypes }) =>
@@ -56,7 +58,7 @@ export const Offer = ({
56
58
  key={`${offerIndex}-${offer.uuid}`}
57
59
  offer={offer}
58
60
  productTypeBuilder={layout}
59
- showBorder={showBorder}
61
+ showCardBorder={showCardBorder}
60
62
  showProductTypeLabel={showProductTypeLabel}
61
63
  />
62
64
  ))
@@ -66,7 +68,7 @@ export const Offer = ({
66
68
  key={`${offerIndex}-${offer.uuid}`}
67
69
  offer={offer}
68
70
  productTypeBuilder={layout}
69
- showBorder={showBorder}
71
+ showCardBorder={showCardBorder}
70
72
  showProductTypeLabel={showProductTypeLabel}
71
73
  />
72
74
  ))
@@ -76,7 +78,7 @@ export const Offer = ({
76
78
  key={`${offerIndex}-${offer.uuid}`}
77
79
  offer={offer}
78
80
  productTypeBuilder={layout}
79
- showBorder={showBorder}
81
+ showCardBorder={showCardBorder}
80
82
  showProductTypeLabel={showProductTypeLabel}
81
83
  />
82
84
  ))
@@ -87,6 +89,7 @@ export const Offer = ({
87
89
  const FallbackTemplate = fallbackTemplate;
88
90
  return (
89
91
  <FallbackTemplate
92
+ showCardBorder={showCardBorder}
90
93
  offerIndex={offerIndex}
91
94
  key={`${offerIndex}-${offer.uuid}`}
92
95
  offer={offer}
@@ -1,6 +1,4 @@
1
1
  import { get } from "radash";
2
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
3
-
4
2
  import React from "react";
5
3
 
6
4
  import type { CreditCardOfferCard as CreditCardOfferCardBuilderProps } from "../../../builder";
@@ -10,11 +8,12 @@ import Divider from "../../Divider";
10
8
  import Text from "../../Text";
11
9
  import { CallToAction } from "../../Common/DynamicOfferCard/CallToAction";
12
10
  import { StyleSheet } from "react-native";
11
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
13
12
 
14
13
  type CreditCardOfferCardProps = {
15
14
  productTypeBuilder: CreditCardOfferCardBuilderProps;
16
15
  offer: BaseOffer;
17
- showBorder: boolean;
16
+ showCardBorder: boolean;
18
17
  showProductTypeLabel?: boolean;
19
18
  offerIndex: number;
20
19
  };
@@ -22,7 +21,7 @@ type CreditCardOfferCardProps = {
22
21
  export const CreditCardOfferCard = ({
23
22
  offer,
24
23
  productTypeBuilder,
25
- // showBorder, TODO: this is unused in the cnf-app as well
24
+ showCardBorder,
26
25
  showProductTypeLabel,
27
26
  offerIndex,
28
27
  }: CreditCardOfferCardProps) => {
@@ -34,7 +33,7 @@ export const CreditCardOfferCard = ({
34
33
  const showBadge = badges.length > 0;
35
34
 
36
35
  return (
37
- <BaseOfferCard showBorder={showBadge}>
36
+ <BaseOfferCard showCardBorder={showCardBorder}>
38
37
  {showProductTypeLabel && (
39
38
  <BaseOfferCard.TopBar>
40
39
  <BaseOfferCard.ProductType>
@@ -1,6 +1,6 @@
1
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
2
1
  import type { CreditCardOfferCard } from "../../../builder";
3
- import { statsToElementPropsBuilder } from "../../../../src/capabilities/offer-catalog/src/utils/stats";
2
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
3
+ import { statsToElementPropsBuilder } from "../../../capabilities/offer-catalog/src/utils/stats";
4
4
 
5
5
  export const makeCreditCardOfferStats =
6
6
  (productTypeBuilder: CreditCardOfferCard) => (offer: BaseOffer) => {
@@ -1,18 +1,17 @@
1
1
  import { get } from "radash";
2
-
3
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
4
2
  import React from "react";
5
3
 
6
4
  import { makeDefaultOfferCardStats } from "./statsBuilder";
7
5
  import type { DefaultOfferCard as DefaultOfferCardBuilderProps } from "../../../builder";
8
6
  import { BaseOfferCard, DynamicOfferCard, SeeMore } from "../../Common";
9
7
  import { useConfiguration } from "../../../context/ConfigurationProvider";
8
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
10
9
 
11
10
  type DefaultOfferCardProps = {
12
11
  productTypeBuilder: DefaultOfferCardBuilderProps;
13
12
  offer: BaseOffer;
14
13
  offerIndex: number;
15
- showBorder: boolean;
14
+ showCardBorder: boolean;
16
15
  showProductTypeLabel?: boolean;
17
16
  };
18
17
 
@@ -20,7 +19,7 @@ export const DefaultOfferCard = ({
20
19
  offer,
21
20
  productTypeBuilder,
22
21
  offerIndex,
23
- showBorder,
22
+ showCardBorder,
24
23
  showProductTypeLabel,
25
24
  }: DefaultOfferCardProps) => {
26
25
  const { stats, topStats } =
@@ -40,7 +39,7 @@ export const DefaultOfferCard = ({
40
39
  key={`${offerIndex}-${offer.uuid}`}
41
40
  offer={offer}
42
41
  offerIndex={offerIndex}
43
- showBorder={showBorder}
42
+ showCardBorder={showCardBorder}
44
43
  showProductTypeLabel={showProductTypeLabel}
45
44
  >
46
45
  <BaseOfferCard.TopContainer>
@@ -1,6 +1,6 @@
1
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
2
1
  import type { DefaultOfferCard } from "../../../builder";
3
- import { statsToElementPropsBuilder } from "../../../../src/capabilities/offer-catalog/src/utils/stats";
2
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
3
+ import { statsToElementPropsBuilder } from "../../../capabilities/offer-catalog/src/utils/stats";
4
4
 
5
5
  export const makeDefaultOfferCardStats =
6
6
  (productTypeBuilder: DefaultOfferCard) => (offer: BaseOffer) => {
@@ -2,23 +2,23 @@ import { get } from "radash";
2
2
 
3
3
  import React from "react";
4
4
  import { SeeMore } from "../../Common/DynamicOfferCard/SeeMore";
5
- import type { BaseOffer } from "../../../../src/capabilities/offer-catalog/src";
6
5
  import type { HeadlineWithDescriptionCard as HeadlineWithDescriptionCardBuilderProps } from "../../../builder";
7
6
  import { BaseOfferCard, DynamicOfferCard } from "../../Common";
8
7
  import { useConfiguration } from "../../../context/ConfigurationProvider";
8
+ import type { BaseOffer } from "../../../capabilities/offer-catalog/src";
9
9
 
10
10
  type HeadlineWithDescriptionCardProps = {
11
11
  productTypeBuilder: HeadlineWithDescriptionCardBuilderProps;
12
12
  offer: BaseOffer;
13
13
  offerIndex: number;
14
- showBorder: boolean;
14
+ showCardBorder: boolean;
15
15
  showProductTypeLabel?: boolean;
16
16
  };
17
17
  export const HeadlineWithDescriptionCard = ({
18
18
  offer,
19
19
  productTypeBuilder,
20
20
  offerIndex,
21
- showBorder,
21
+ showCardBorder,
22
22
  showProductTypeLabel,
23
23
  }: HeadlineWithDescriptionCardProps) => {
24
24
  const {
@@ -43,7 +43,7 @@ export const HeadlineWithDescriptionCard = ({
43
43
  key={`${offerIndex}-${offer.uuid}`}
44
44
  offer={offer}
45
45
  offerIndex={offerIndex}
46
- showBorder={showBorder}
46
+ showCardBorder={showCardBorder}
47
47
  showProductTypeLabel={showProductTypeLabel}
48
48
  >
49
49
  <BaseOfferCard.TopContainer>
@@ -10,11 +10,11 @@ import {
10
10
  Platform,
11
11
  } from "react-native";
12
12
  import Text from "../Text";
13
- import type { BaseOffer } from "../../../src/capabilities/offer-catalog/src";
14
13
  import { DescriptionPoints } from "./DescriptionPoints";
15
14
  import { Disclaimer } from "./Disclaimer";
16
15
  import { CallToAction } from "../Common/DynamicOfferCard/CallToAction";
17
16
  import Divider from "../Divider";
17
+ import type { BaseOffer } from "../../capabilities/offer-catalog/src";
18
18
 
19
19
  type OfferDetailsModalProps = {
20
20
  visible: boolean;
@@ -1,7 +1,6 @@
1
1
  import React, { useEffect, useState } from "react";
2
2
  import { localCnfContext } from "../config/mocks/cnfContext";
3
3
  import { Text } from "react-native";
4
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
5
4
  import { getPageData } from "../pageData";
6
5
  import type { Layout } from "../utils";
7
6
  import {
@@ -15,8 +14,9 @@ import {
15
14
  type EventHandlerContextType,
16
15
  } from "../context/EventHandlerProvider";
17
16
  import { getConfigApiBaseUrl } from "../apiEnvironment";
18
- import { getDefaultPaletteColor } from "../utils/getDefaultPaletteColor";
19
17
  import { ConfigurationProvider } from "../context/ConfigurationProvider";
18
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
19
+ import { getDefaultPaletteColor } from "../utils/getDefaultPaletteColor";
20
20
 
21
21
  export type MoneyLionOfferCarouselProps = {
22
22
  channel: string;
@@ -31,6 +31,7 @@ export type MoneyLionOfferCarouselProps = {
31
31
  fontFamily?: Partial<FontFamily>;
32
32
  showProductTypeLabel?: boolean;
33
33
  isDev: boolean;
34
+ showCardBorder?: boolean;
34
35
  };
35
36
 
36
37
  const getConfiguration = async ({
@@ -165,7 +166,7 @@ export const MoneyLionOfferCarousel = (
165
166
  shouldHideFooter,
166
167
  displayLayout,
167
168
  showProductTypeLabel,
168
- showBorder,
169
+ showCardBorder,
169
170
  title,
170
171
  offers,
171
172
  rateTableUuid,
@@ -177,7 +178,7 @@ export const MoneyLionOfferCarousel = (
177
178
  shouldHideFooter,
178
179
  displayLayout,
179
180
  showProductTypeLabel,
180
- showBorder,
181
+ showCardBorder,
181
182
  title,
182
183
  };
183
184
 
@@ -71,13 +71,8 @@ const View: React.FC<ViewProps> = ({
71
71
 
72
72
  // Border color handling
73
73
  ...(borderColor && {
74
- borderColor:
75
- (borderColor in
76
- ["neutral", "positive", "warning", "critical", "primary"]
77
- ? styles[
78
- `border${borderColor as "neutral" | "positive" | "warning" | "critical" | "primary"}`
79
- ]?.borderColor
80
- : undefined) || borderColor,
74
+ borderWidth: 1,
75
+ borderColor: "#bbbbbb", // This will get update in follow up one using themeColors
81
76
  }),
82
77
 
83
78
  // Direction handling
@@ -1,6 +1,6 @@
1
1
  import React, { createContext, useContext } from "react";
2
2
  import type { ResultType } from "../services/getProductTypes";
3
- import type { BaseOffer } from "../../src/capabilities/offer-catalog/src";
3
+ import type { BaseOffer } from "../capabilities/offer-catalog/src";
4
4
 
5
5
  interface onInitializeProps {
6
6
  timestamp: string;
package/src/pageData.ts CHANGED
@@ -1,5 +1,6 @@
1
- import type { CnfContext } from "../src/capabilities/core/src/system/cnfContext/CnfContext";
2
- import { getIsDevEnvironment } from "../src/capabilities/offer-catalog/src/utils/contextUtil";
1
+ import type { CnfContext } from "./capabilities/core/src/system/cnfContext/CnfContext";
2
+ import { getIsDevEnvironment } from "./capabilities/offer-catalog/src/utils/contextUtil";
3
+
3
4
  import type { MoneyLionOfferCarouselProps } from "./components/MoneyLionOfferCarousel";
4
5
  import type { onRateTableSubmitProps } from "./context/EventHandlerProvider";
5
6
  import { getDynamicOffers } from "./services/getDynamicOffers";
@@ -30,6 +31,7 @@ export async function getPageData({
30
31
  displayLayout,
31
32
  searchAPIToken,
32
33
  showProductTypeLabel,
34
+ showCardBorder,
33
35
  } = params;
34
36
 
35
37
  // Resolve Tags
@@ -90,7 +92,7 @@ export async function getPageData({
90
92
  offers,
91
93
  currentCountry,
92
94
  // videosContent,
93
- // showBorder,
95
+ showCardBorder,
94
96
  // shouldHideFooter,
95
97
  showProductTypeLabel,
96
98
  displayLayout: safeDisplayLayout,
@@ -1,9 +1,4 @@
1
1
  import { isEmpty } from "radash";
2
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
3
- import type {
4
- PartnerOverride,
5
- ProductTypeDefinition,
6
- } from "../../src/capabilities/offer-catalog/src";
7
2
  import {
8
3
  addClientTagsToOfferLinks,
9
4
  getOffersByProductTypes,
@@ -18,6 +13,11 @@ import { sortOffersByRecommendationScore } from "../utils/sortOffersByRecommenda
18
13
  import { pipe } from "effect";
19
14
  import { formatOfferUrl } from "../utils/formatOfferUrl";
20
15
  import { getOffersBasedOnLayout } from "../utils/getOffersBasedOnLayout";
16
+ import type {
17
+ PartnerOverride,
18
+ ProductTypeDefinition,
19
+ } from "../capabilities/offer-catalog/src";
20
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
21
21
 
22
22
  export type GetDynamicOffersProps = {
23
23
  tags: string;
@@ -1,6 +1,6 @@
1
1
  import { pipe } from "effect";
2
- import { orderProductTypesByRank } from "../../src/capabilities/core/src/domain/third-party-search";
3
2
  import { getEwsSearchApiBaseUrl } from "../apiEnvironment";
3
+ import { orderProductTypesByRank } from "../capabilities/core/src/domain/third-party-search";
4
4
 
5
5
  type GetProductTypesByQueryProps = {
6
6
  query: string;
@@ -1,4 +1,4 @@
1
- import type { BaseOffer } from "../../src/capabilities/offer-catalog/src";
1
+ import type { BaseOffer } from "../capabilities/offer-catalog/src";
2
2
 
3
3
  /**
4
4
  * Add client tags to offer links
@@ -3,7 +3,7 @@ import {
3
3
  type BaseOffer,
4
4
  type PartnerOverride,
5
5
  type ProductTypeDefinition,
6
- } from "../../src/capabilities/offer-catalog/src";
6
+ } from "../capabilities/offer-catalog/src";
7
7
 
8
8
  /**
9
9
  * Format the offer URL
@@ -1,4 +1,4 @@
1
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
1
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
2
2
 
3
3
  export const getDefaultProductType = (context: CnfContext) =>
4
4
  context.configuration.configuration.defaultProductTypeSlug;
@@ -1,4 +1,4 @@
1
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
1
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
2
2
 
3
3
  /**
4
4
  * Get enabled cache offers request
@@ -1,7 +1,7 @@
1
1
  import { pipe } from "effect";
2
2
  import type { Layout } from "./layouts";
3
3
  import { sortOffersByRecommendationScore } from "./sortOffersByRecommendationScore";
4
- import type { BaseOffer } from "../../src/capabilities/offer-catalog/src";
4
+ import type { BaseOffer } from "../capabilities/offer-catalog/src";
5
5
 
6
6
  const MAX_OFFERS_TO_DISPLAY = 3;
7
7
 
@@ -1,9 +1,10 @@
1
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
1
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
2
2
  import {
3
3
  getCachedOffersByProductTypes,
4
4
  getOffersForProductTypes,
5
- } from "../../src/capabilities/offer-catalog/src/api/offerCatalogApi";
6
- import { parseClientTags } from "../../src/capabilities/offer-catalog/src/utils/contextUtil";
5
+ } from "../capabilities/offer-catalog/src/api/offerCatalogApi";
6
+ import { parseClientTags } from "../capabilities/offer-catalog/src/utils/contextUtil";
7
+
7
8
  /**
8
9
  * Retrieves offers by product types.
9
10
  *
@@ -1,4 +1,4 @@
1
- import type { CnfContext } from "../../src/capabilities/core/src/system/cnfContext/CnfContext";
1
+ import type { CnfContext } from "../capabilities/core/src/system/cnfContext/CnfContext";
2
2
 
3
3
  export const getProductTypesDefinition = (context: CnfContext) => {
4
4
  const offersConfig = context.configuration.configuration;
@@ -1,7 +1,6 @@
1
- import type { BaseOffer } from "../../src/capabilities/offer-catalog/src";
1
+ import type { BaseOffer } from "../capabilities/offer-catalog/src";
2
2
  import { sortOffersByRecommendationScore } from "./sortOffersByRecommendationScore";
3
3
 
4
-
5
4
  export const selectDynamicOffers = (
6
5
  offers: BaseOffer[],
7
6
  productTypes: string[]
@@ -1,5 +1,5 @@
1
1
  import { sort } from "radash";
2
- import type { BaseOffer } from "../../src/capabilities/offer-catalog/src";
2
+ import type { BaseOffer } from "../capabilities/offer-catalog/src";
3
3
 
4
4
  export const sortOffersByRecommendationScore = (offers: BaseOffer[]) => {
5
5
  return sort(offers, (offer) => offer.recommendationScore, true);