@sunrise-upc/mobile-prod-card 8.7.0 → 8.9.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 (60) hide show
  1. package/dist/cjs/Analytics/AnalyticsConstants.d.ts +6 -0
  2. package/dist/cjs/components/Accessories/Accessory-card/AccessoryCard.d.ts +10 -0
  3. package/dist/cjs/components/Accessories/Accessory-card/AccessoryErrorModal.d.ts +18 -0
  4. package/dist/cjs/components/Accessories/AccessoryPreviewCardLoader/AccessoryPreviewCardLoader.d.ts +3 -0
  5. package/dist/cjs/components/Accessories/AccessoryPreviewCardSkeletonBody/AccessoryPreviewCardSkeletonBody.d.ts +3 -0
  6. package/dist/cjs/components/Accessories/DeviceCarouselComponent.d.ts +3 -0
  7. package/dist/cjs/components/Accessories/MultiItemAccessories/MultiItemAccessoriesPage.d.ts +5 -0
  8. package/dist/cjs/components/Accessories/MultiItemAccessories/MultiItemAccessoriesSchema.d.ts +41 -0
  9. package/dist/cjs/components/Accessories/PaymentTypeTabs/PaymentTypeTabs.d.ts +14 -0
  10. package/dist/cjs/components/Accessories/ProgressionBar/progressionBar.d.ts +14 -0
  11. package/dist/cjs/components/Accessories/index.d.ts +1 -0
  12. package/dist/cjs/components/Accessories/multiItemAccessoryStore/MultiAccessoryProvider.d.ts +19 -0
  13. package/dist/cjs/components/Accessories/multiItemAccessoryStore/types.d.ts +71 -0
  14. package/dist/cjs/components/Accessories/multiItemAccessoryStore/useMultiAccessoryActions.d.ts +15 -0
  15. package/dist/cjs/components/Accessories/multiItemAccessoryStore/useMultiAccessoryContext.d.ts +32 -0
  16. package/dist/cjs/components/Accessories/multiItemAccessoryStore/useMultiAccessoryUpdateCartActions.d.ts +11 -0
  17. package/dist/cjs/components/Dotloader/Dotloader.d.ts +1 -1
  18. package/dist/cjs/components/StaticLineTable/OttServiceOptions/OttServiceOptionsSmallPopup.d.ts +1 -1
  19. package/dist/cjs/components/index.d.ts +1 -0
  20. package/dist/cjs/components/types.d.ts +34 -0
  21. package/dist/cjs/index.js +3 -3
  22. package/dist/cjs/services/MultiItemAccessories/multiItemAccessoryService.d.ts +8 -0
  23. package/dist/cjs/services/MultiItemAccessories/multiitemAccessoriesUpdateCartService.d.ts +8 -0
  24. package/dist/cjs/services/MultiItemAccessories/storyBlokService.d.ts +10 -0
  25. package/dist/cjs/services/api-constants.d.ts +4 -0
  26. package/dist/cjs/utils/AnalyticsUtils.d.ts +2 -0
  27. package/dist/cjs/utils/constants.d.ts +16 -0
  28. package/dist/cjs/utils/data-source.d.ts +1 -1
  29. package/dist/cjs/utils/utils.d.ts +12 -0
  30. package/dist/esm/Analytics/AnalyticsConstants.d.ts +6 -0
  31. package/dist/esm/components/Accessories/Accessory-card/AccessoryCard.d.ts +10 -0
  32. package/dist/esm/components/Accessories/Accessory-card/AccessoryErrorModal.d.ts +18 -0
  33. package/dist/esm/components/Accessories/AccessoryPreviewCardLoader/AccessoryPreviewCardLoader.d.ts +3 -0
  34. package/dist/esm/components/Accessories/AccessoryPreviewCardSkeletonBody/AccessoryPreviewCardSkeletonBody.d.ts +3 -0
  35. package/dist/esm/components/Accessories/DeviceCarouselComponent.d.ts +3 -0
  36. package/dist/esm/components/Accessories/MultiItemAccessories/MultiItemAccessoriesPage.d.ts +5 -0
  37. package/dist/esm/components/Accessories/MultiItemAccessories/MultiItemAccessoriesSchema.d.ts +41 -0
  38. package/dist/esm/components/Accessories/PaymentTypeTabs/PaymentTypeTabs.d.ts +14 -0
  39. package/dist/esm/components/Accessories/ProgressionBar/progressionBar.d.ts +14 -0
  40. package/dist/esm/components/Accessories/index.d.ts +1 -0
  41. package/dist/esm/components/Accessories/multiItemAccessoryStore/MultiAccessoryProvider.d.ts +19 -0
  42. package/dist/esm/components/Accessories/multiItemAccessoryStore/types.d.ts +71 -0
  43. package/dist/esm/components/Accessories/multiItemAccessoryStore/useMultiAccessoryActions.d.ts +15 -0
  44. package/dist/esm/components/Accessories/multiItemAccessoryStore/useMultiAccessoryContext.d.ts +32 -0
  45. package/dist/esm/components/Accessories/multiItemAccessoryStore/useMultiAccessoryUpdateCartActions.d.ts +11 -0
  46. package/dist/esm/components/Dotloader/Dotloader.d.ts +1 -1
  47. package/dist/esm/components/StaticLineTable/OttServiceOptions/OttServiceOptionsSmallPopup.d.ts +1 -1
  48. package/dist/esm/components/index.d.ts +1 -0
  49. package/dist/esm/components/types.d.ts +34 -0
  50. package/dist/esm/index.js +3 -3
  51. package/dist/esm/services/MultiItemAccessories/multiItemAccessoryService.d.ts +8 -0
  52. package/dist/esm/services/MultiItemAccessories/multiitemAccessoriesUpdateCartService.d.ts +8 -0
  53. package/dist/esm/services/MultiItemAccessories/storyBlokService.d.ts +10 -0
  54. package/dist/esm/services/api-constants.d.ts +4 -0
  55. package/dist/esm/utils/AnalyticsUtils.d.ts +2 -0
  56. package/dist/esm/utils/constants.d.ts +16 -0
  57. package/dist/esm/utils/data-source.d.ts +1 -1
  58. package/dist/esm/utils/utils.d.ts +12 -0
  59. package/dist/index.d.ts +91 -3
  60. package/package.json +1 -1
@@ -0,0 +1,8 @@
1
+ import { ApiServiceV2 } from '@sunrise-upc/ajax-lib';
2
+ declare class multiItemAccessoryService {
3
+ apiServiceInstance: ApiServiceV2;
4
+ constructor();
5
+ getRecommendedAccessoryData: (cartId: string) => Promise<any>;
6
+ }
7
+ declare const multiItemAccessoryServices: multiItemAccessoryService;
8
+ export default multiItemAccessoryServices;
@@ -0,0 +1,8 @@
1
+ import { ApiServiceV2 } from '@sunrise-upc/ajax-lib';
2
+ declare class multiItemAccessoryUpdateCartService {
3
+ apiServiceInstance: ApiServiceV2;
4
+ constructor();
5
+ getUpdateCartData: (cartId: any, payload: any) => Promise<any>;
6
+ }
7
+ declare const multiItemAccessoryUpdateCartServices: multiItemAccessoryUpdateCartService;
8
+ export default multiItemAccessoryUpdateCartServices;
@@ -0,0 +1,10 @@
1
+ import { ApiServiceV2 } from '@sunrise-upc/ajax-lib';
2
+ declare class storyBlokServices {
3
+ apiServiceInstance: ApiServiceV2;
4
+ constructor();
5
+ getStoryBlokData: (lang: string | undefined, prodName: any, accessoryPath: string) => Promise<{
6
+ sbStory: any;
7
+ }>;
8
+ }
9
+ declare const storyBlokService: storyBlokServices;
10
+ export default storyBlokService;
@@ -11,5 +11,9 @@ export declare const APIResourceConstants: {
11
11
  HARDWARE_DEVICES: string;
12
12
  TV_SERVICE_OPTIONS_V2: string;
13
13
  CUSTOMER_EVENTS: string;
14
+ THREE_SCALE_API_KEY: string;
15
+ STORIES: string;
16
+ RECOMMENDED_ACCESSORIES: string;
17
+ UPDATE_CART: string;
14
18
  };
15
19
  export declare const SBENDPOINT: any;
@@ -37,3 +37,5 @@ export interface UserInterface {
37
37
  existingUser?: boolean;
38
38
  }
39
39
  export declare const trackUser: (loginType: string, accountID?: string, language?: string, lastLoginDate?: string, type?: string, existingUser?: boolean) => void;
40
+ export declare const trackViewItem: (event: string, eventName: string, product: any) => void;
41
+ export declare const setMmcItemTracker: (productList: any) => void;
@@ -38,6 +38,8 @@ export declare const EXCLUSIVE_BENEFIT_COLOR = "#008187";
38
38
  export declare const ULTIMATEBUNDLE = "ultimateBundle";
39
39
  export declare const ONE_ECOMMERCE_INTERNET_SUMMARY = "one-ecommerce-internetSummary";
40
40
  export declare const ONE_ECOMMERCE_SUMMARY = "one-ecommerce-summary";
41
+ export declare const WIN = "WIN";
42
+ export declare const HARDWAREGROUPNAME = "hardwareGroupName";
41
43
  export declare const MOBILE = "mobile";
42
44
  export declare const DESKTOP = "desktop";
43
45
  export declare const LARGE_DESKTOP = "large-desktop";
@@ -74,3 +76,17 @@ export declare const OTP_NR_CHANGE = "OTP_NR_CHANGE";
74
76
  export declare const OTP_CONTINUE = "OTP_CONTINUE";
75
77
  export declare const OTP_RESEND = "OTP_RESEND";
76
78
  export declare const PW_FORGOT = "PW_FORGOT";
79
+ export declare const MONTHLY = "monthly_24";
80
+ export declare const ACCESSORY = "ACCESSORY";
81
+ export declare const ADD = "ADD";
82
+ export declare const FLOWINTITIATED = "flowInitiated";
83
+ export declare const MONTHLYFLASHDISCOUNT = "monthlyFlashDiscount";
84
+ export declare const REMOVE = "REMOVE";
85
+ export declare const TOTALFLASHDISCOUNT = "totalFlashDiscount";
86
+ export declare const MOBILEACCESSORIES = "mobileaccessories";
87
+ export declare const ONETIME = "none";
88
+ export declare const LAZYLOAD = "lazy";
89
+ export declare const CONTAIN = "contain";
90
+ export declare const COVER = "cover";
91
+ export declare const ACCESSORYLABEL = "accessoriesLabel";
92
+ export declare const MULTIPLEITEMACCESSORIES = "MULTIPLE_ITEM_ACCESSORIES";
@@ -2,7 +2,7 @@ export type LocaleID = 'en' | 'de' | 'fr' | 'it' | 'default';
2
2
  export type LinkTarget = '_blank' | '_parent' | '_self' | '_top';
3
3
  export type Alignment = 'left' | 'center' | 'right';
4
4
  export type AuraButtonTypes = 'Primary-V1' | 'Secondary-V1' | 'Secondary-V4';
5
- export type FalconButtonTypes = 'Primary-V1' | 'Secondary-V1' | 'Secondary-V4' | 'Secondary-Dark';
5
+ export type FalconButtonTypes = 'Primary-V1' | 'Secondary-V1' | 'Secondary-V4' | 'Secondary-Dark' | 'Secondary-V5';
6
6
  export type QuoteBackgroundColor = 'pink' | 'blue' | 'grey' | 'iceWhite' | 'transparent';
7
7
  export type FalconGradientTypes = 'rubyglow-diagonal' | 'rubyglow-vertical' | 'pinksky-diagonal' | 'pinksky-vertical' | 'bluehaze-diagonal' | 'bluehaze-vertical' | 'greencloud-diagonal' | 'greencloud-vertical' | 'peachfog-diagonal' | 'peachfog-vertical' | 'black' | 'skyfuel-vertical' | 'black-friday' | 'none';
8
8
  export type ElementPosition = 'top-left' | 'top-right' | 'bottom-right' | 'bottom-left';
@@ -16,3 +16,15 @@ export declare const iconHandler: (type: string) => string;
16
16
  export declare const checkLinkWithLang: (url: string) => string | undefined;
17
17
  export declare const getSBAssetUrl: (wafIdentifier: any, image?: string) => string;
18
18
  export declare const getNoteValues: (hardwareProducts: any, key: string) => undefined;
19
+ /**US 349849 - MIA migration
20
+ * price model
21
+ * @param value string | number
22
+ * @returns
23
+ * 2.0 -> 2.00
24
+ * 2.1 -> 2.10
25
+ * 2.15 -> 2.15
26
+ * 0.0 -> 0.00
27
+ * 0.5 -> 0.50
28
+ */
29
+ export declare const countZeros: (value: any) => any;
30
+ export declare const viewportMultiItem: () => string;
package/dist/index.d.ts CHANGED
@@ -25,6 +25,8 @@ interface LoginModalSchema {
25
25
 
26
26
  declare const LoginModal: FC<LoginModalSchema>;
27
27
 
28
+ type FalconButtonTypes = 'Primary-V1' | 'Secondary-V1' | 'Secondary-V4' | 'Secondary-Dark' | 'Secondary-V5';
29
+
28
30
  interface Link {
29
31
  id: number;
30
32
  slug: string;
@@ -47,6 +49,7 @@ interface LinkAlternate {
47
49
  type Links = {
48
50
  [key: string]: Link;
49
51
  };
52
+ type Alignment = "left" | "center" | "right";
50
53
  interface Asset {
51
54
  id: number;
52
55
  alt?: string;
@@ -71,7 +74,44 @@ interface ComponentMetadata {
71
74
  appId?: string;
72
75
  integrationId?: string;
73
76
  }
74
- type FalconGradientTypes = 'rubyglow-diagonal' | 'rubyglow-vertical' | 'pinksky-diagonal' | 'pinksky-vertical' | 'bluehaze-diagonal' | 'bluehaze-vertical' | 'greencloud-diagonal' | 'greencloud-vertical' | 'peachfog-diagonal' | 'peachfog-vertical' | 'darkblue-haze' | 'none';
77
+ type FalconGradientTypes = 'rubyglow-diagonal' | 'rubyglow-vertical' | 'pinksky-diagonal' | 'pinksky-vertical' | 'bluehaze-diagonal' | 'bluehaze-vertical' | 'greencloud-diagonal' | 'greencloud-vertical' | 'peachfog-diagonal' | 'peachfog-vertical' | 'darkblue-haze' | 'none';
78
+ interface ComponentWithContentProps<T extends GenericSBProps = GenericSBProps> {
79
+ content: T;
80
+ metadata?: ComponentMetadata | undefined;
81
+ }
82
+ interface FalconButtonSchema extends GenericSBProps {
83
+ buttonLabel?: string;
84
+ buttonIcon?: Asset;
85
+ buttonHoverIcon?: Asset;
86
+ buttonClickedIcon?: Asset;
87
+ buttonDisabledIcon?: Asset;
88
+ buttonLink: MultiLink;
89
+ linkTarget: LinkTarget;
90
+ buttonType: FalconButtonTypes;
91
+ iconPosition: string;
92
+ buttonAlignment: Alignment;
93
+ asset?: Asset;
94
+ id?: string;
95
+ bloks?: any;
96
+ minWidth: number;
97
+ enableScroll: boolean;
98
+ targetElement: componentsInStory;
99
+ blackFridayThemeIcon: Asset;
100
+ fromTallhero?: boolean;
101
+ }
102
+ interface MultiLink {
103
+ id: string;
104
+ url: string;
105
+ linktype: 'url' | 'story';
106
+ fieldtype: 'multilink';
107
+ cached_url: string;
108
+ }
109
+ type LinkTarget = '_self' | '_blank' | null;
110
+ interface componentsInStory {
111
+ _uid: string;
112
+ plugin: string;
113
+ blockIdentifier: string;
114
+ }
75
115
 
76
116
  interface CardSchema {
77
117
  content: any;
@@ -218,7 +258,7 @@ interface OttServiceOptionsSmallPopupProps {
218
258
  mainContent: any;
219
259
  preSelectedOptions: any[];
220
260
  optionsResponse: any[];
221
- updateResponseList: (list: any) => void;
261
+ updateResponseList?: (list: any) => void;
222
262
  showPrice?: any;
223
263
  productData?: any;
224
264
  offeringData?: any;
@@ -227,6 +267,54 @@ interface OttServiceOptionsSmallPopupProps {
227
267
  }
228
268
  declare const OttServiceOptionsSmallPopup: ({ content, addOptionsCallBack, metadata, constants, mainContent, preSelectedOptions, optionsResponse, updateResponseList, showPrice, productData, offeringData, uniqueId, deviceFlow }: OttServiceOptionsSmallPopupProps) => JSX.Element;
229
269
 
270
+ interface paymentOptionSchema {
271
+ paymentSubText: string;
272
+ paymentText: string;
273
+ type: string;
274
+ }
275
+
276
+ interface MultiItemAccessoriesSchema extends GenericSBProps {
277
+ component: '"AccessoriesRecommendationCards"';
278
+ accessoriesLabel: string;
279
+ addCartBtnIcon: any;
280
+ addCartBtntext: string;
281
+ checkoutBtnText: string;
282
+ checkoutLabel: string;
283
+ compatibleText: string;
284
+ customizeDeviceLabel: string;
285
+ monthlyPaymentLabel: string;
286
+ monthlyDownPaymentLabel: string;
287
+ oneTimePaymentLabel: string;
288
+ pickYourDeviceLabel: string;
289
+ recommendationLabel: any;
290
+ removeCartBtnIcon: any;
291
+ removeCartBtnText: string;
292
+ yourSubscriptionLabel: string;
293
+ progressionBar: any;
294
+ addtocartButton: FalconButtonSchema[];
295
+ removefromcartButton: FalconButtonSchema[];
296
+ proceedtocheckoutButton: FalconButtonSchema[];
297
+ parentSlugUrl: string;
298
+ multiItemCheckoutUrl: any;
299
+ accessoriesLimit: number;
300
+ accessoriesColorLabel: string;
301
+ totalText: string;
302
+ monthlyText: string;
303
+ errorModal: any;
304
+ retryButton: any;
305
+ cancelButtonLinkText: any;
306
+ cartLimitWarningText: any;
307
+ cartLimitModal: any;
308
+ cartLimitBtnText: string;
309
+ paymentOptions: paymentOptionSchema[];
310
+ paymentHeadingText: string;
311
+ winAccessoriesLimit: number;
312
+ winLimitWarningText: any;
313
+ winCheckoutUrl: any;
314
+ }
315
+
316
+ declare const MultiItemAccessoriesWithProvider: (props: ComponentWithContentProps<MultiItemAccessoriesSchema>) => JSX.Element;
317
+
230
318
  interface NotificationToastProps {
231
319
  title: string;
232
320
  message: string;
@@ -325,4 +413,4 @@ declare class LoginBasicPropConfig {
325
413
  getAPIServiceObject: () => ApiServiceV2;
326
414
  }
327
415
 
328
- export { AssetPathPropConfig, AssetPathPropConfigSchema, BenefitWrapper, Breadcrumb, Button, Card, CardEntitlement, CarouselComp, CheckCoverage, CoverageCheckModal, DpLinetableContainer as DpLinetable, HeroLoginBanner as HeroLogin, LineTableBasicPropConfig, LineTableBasicPropConfigSchema, LinecheckBasicPropConfig, LinecheckBasicPropConfigSchema, LincheckModal as LinecheckModal, LoginBasicPropConfig, LoginBasicPropConfigSchema, LoginModal as LoginModalV2, NotificationToast, OttServiceOptionsSmallPopup, PreToPostSubsPopup as PretoPostSubsPopup, ProductTableV3, ProductTeaser, ProductTeaserPropConfig, ProductTeaserPropConfigSchema, ProgressionBar, StaticLineTable, StickyBottomSheet, StickyBottomSheetPropConfig, StickyBottomSheetPropConfigSchema, StickyProductAnchor };
416
+ export { AssetPathPropConfig, AssetPathPropConfigSchema, BenefitWrapper, Breadcrumb, Button, Card, CardEntitlement, CarouselComp, CheckCoverage, CoverageCheckModal, DpLinetableContainer as DpLinetable, HeroLoginBanner as HeroLogin, LineTableBasicPropConfig, LineTableBasicPropConfigSchema, LinecheckBasicPropConfig, LinecheckBasicPropConfigSchema, LincheckModal as LinecheckModal, LoginBasicPropConfig, LoginBasicPropConfigSchema, LoginModal as LoginModalV2, MultiItemAccessoriesWithProvider, NotificationToast, OttServiceOptionsSmallPopup, PreToPostSubsPopup as PretoPostSubsPopup, ProductTableV3, ProductTeaser, ProductTeaserPropConfig, ProductTeaserPropConfigSchema, ProgressionBar, StaticLineTable, StickyBottomSheet, StickyBottomSheetPropConfig, StickyBottomSheetPropConfigSchema, StickyProductAnchor };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sunrise-upc/mobile-prod-card",
3
- "version": "8.7.0",
3
+ "version": "8.9.0",
4
4
  "description": "Starter project to create reusable functional component",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",