@cleartrip/ct-design-header 1.2.0-SNAPSHOT-hide-chips-test.0 → 1.2.0-SNAPSHOT-final-header-test.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 (37) hide show
  1. package/dist/BusinessDropdown/index.d.ts.map +1 -1
  2. package/dist/Header.d.ts.map +1 -1
  3. package/dist/HeaderAnimatedMask /index.d.ts.map +1 -1
  4. package/dist/LobsHeader/index.d.ts +1 -2
  5. package/dist/LobsHeader/index.d.ts.map +1 -1
  6. package/dist/RewardsSection/LoyaltyChips.d.ts +1 -1
  7. package/dist/RewardsSection/LoyaltyChips.d.ts.map +1 -1
  8. package/dist/RewardsSection/index.d.ts +1 -2
  9. package/dist/RewardsSection/index.d.ts.map +1 -1
  10. package/dist/UserAccount/UserAccountDropdown.d.ts.map +1 -1
  11. package/dist/UserAccount/accountOptions.d.ts +1 -0
  12. package/dist/UserAccount/accountOptions.d.ts.map +1 -1
  13. package/dist/UserAccount/index.d.ts +1 -2
  14. package/dist/UserAccount/index.d.ts.map +1 -1
  15. package/dist/constants.d.ts +21 -24
  16. package/dist/constants.d.ts.map +1 -1
  17. package/dist/context/HeaderProvider.d.ts +8 -0
  18. package/dist/context/HeaderProvider.d.ts.map +1 -0
  19. package/dist/ct-design-header.browser.cjs.js +1 -1
  20. package/dist/ct-design-header.browser.cjs.js.map +1 -1
  21. package/dist/ct-design-header.browser.esm.js +1 -1
  22. package/dist/ct-design-header.browser.esm.js.map +1 -1
  23. package/dist/ct-design-header.cjs.js +410 -231
  24. package/dist/ct-design-header.cjs.js.map +1 -1
  25. package/dist/ct-design-header.esm.js +412 -233
  26. package/dist/ct-design-header.esm.js.map +1 -1
  27. package/dist/ct-design-header.umd.js +422 -234
  28. package/dist/ct-design-header.umd.js.map +1 -1
  29. package/dist/hooks/useHoverDropdown.d.ts.map +1 -1
  30. package/dist/index.css +1 -1
  31. package/dist/index.d.ts +1 -0
  32. package/dist/index.d.ts.map +1 -1
  33. package/dist/type.d.ts +5 -6
  34. package/dist/type.d.ts.map +1 -1
  35. package/dist/utils.d.ts +15 -0
  36. package/dist/utils.d.ts.map +1 -0
  37. package/package.json +9 -8
@@ -2,12 +2,12 @@
2
2
 
3
3
  var tslib = require('tslib');
4
4
  var jsxRuntime = require('react/jsx-runtime');
5
+ var react = require('react');
5
6
  var ctDesignContainer = require('@cleartrip/ct-design-container');
6
7
  var ctDesignTypography = require('@cleartrip/ct-design-typography');
7
8
  var ctDesignButton = require('@cleartrip/ct-design-button');
8
9
  var ctDesignDivider = require('@cleartrip/ct-design-divider');
9
10
  var ctDesignIcons = require('@cleartrip/ct-design-icons');
10
- var react = require('react');
11
11
  var ctDesignShimmer = require('@cleartrip/ct-design-shimmer');
12
12
 
13
13
  var OFFERS_URL = 'all-offers/?categories=flights';
@@ -16,23 +16,27 @@ var SUPPORT_URL = '/support';
16
16
  var NAVBAR_OPTIONS = [{
17
17
  lefticon: ctDesignIcons.Offers,
18
18
  text: 'Offers',
19
+ ravenActionName: 'offers',
19
20
  isHoverable: false,
20
21
  isClickable: true,
21
22
  link: OFFERS_URL
22
23
  }, {
23
24
  lefticon: ctDesignIcons.BusinessBag,
24
25
  text: 'Business',
26
+ ravenActionName: 'business',
25
27
  rightIcon: ctDesignIcons.ChevronDown,
26
28
  isHoverable: true
27
29
  }, {
28
30
  lefticon: ctDesignIcons.MyTrips,
29
31
  text: 'My Trips',
32
+ ravenActionName: 'mytrips',
30
33
  isHoverable: false,
31
34
  isClickable: true,
32
35
  link: MY_TRIPS_URL
33
36
  }, {
34
37
  lefticon: ctDesignIcons.SupportIcon,
35
38
  text: 'Support',
39
+ ravenActionName: 'support',
36
40
  isHoverable: false,
37
41
  isClickable: true,
38
42
  link: SUPPORT_URL
@@ -68,24 +72,57 @@ var LOB_DATA = [{
68
72
  var bdConfig = [{
69
73
  title: 'AgentBox',
70
74
  subtitle: 'For travel agents',
71
- details: 'One-stop travel solution offering the best deals to our travel agency partners'
75
+ details: 'One-stop travel solution offering the best deals to our travel agency partners',
76
+ link: 'https://agency.cleartrip.com'
72
77
  }, {
73
78
  title: 'OutOfOffice',
74
79
  subtitle: 'For startups, corporates and SMEs',
75
- details: 'Manage corporate business travel, smartly'
80
+ details: 'Manage corporate business travel, smartly',
81
+ link: 'https://ooo.cleartrip.com/',
82
+ ravenActionName: 'ooo'
76
83
  }, {
77
84
  title: 'MICE',
78
85
  subtitle: 'For corporate events',
79
- details: 'An end-to-end management solution for all your corporate events'
86
+ details: 'An end-to-end management solution for all your corporate events',
87
+ link: '/mice'
80
88
  }, {
81
89
  title: 'API',
82
90
  subtitle: 'For developers',
83
- details: 'Unlock seamless integration and scale with our powerful, reliable APIs'
91
+ details: 'Unlock seamless integration and scale with our powerful, reliable APIs',
92
+ link: '/api'
84
93
  }];
85
94
  var BUSINESS_DROPDOWN_HEADING = 'Other business services';
95
+ exports.RAVEN_PAGE_NAMES = void 0;
96
+ (function (RAVEN_PAGE_NAMES) {
97
+ RAVEN_PAGE_NAMES["UNIFIED_HOME"] = "unified_homepage";
98
+ RAVEN_PAGE_NAMES["HOTELS_HOME"] = "hotels_homepage";
99
+ RAVEN_PAGE_NAMES["FLIGHTS_HOME"] = "flights_homepage";
100
+ })(exports.RAVEN_PAGE_NAMES || (exports.RAVEN_PAGE_NAMES = {}));
101
+ var RAVEN_PLATFORMS;
102
+ (function (RAVEN_PLATFORMS) {
103
+ RAVEN_PLATFORMS["DESKTOP"] = "desktop";
104
+ })(RAVEN_PLATFORMS || (RAVEN_PLATFORMS = {}));
105
+
106
+ var HeaderContext = react.createContext(undefined);
107
+ var useHeaderContext = function () {
108
+ var context = react.useContext(HeaderContext);
109
+ if (!context) {
110
+ throw new Error('useHeaderContext must be used within a HeaderProvider');
111
+ }
112
+ return context;
113
+ };
114
+ var HeaderProvider = function (_a) {
115
+ var value = _a.value,
116
+ children = _a.children;
117
+ return jsxRuntime.jsx(HeaderContext.Provider, tslib.__assign({
118
+ value: value
119
+ }, {
120
+ children: children
121
+ }));
122
+ };
86
123
 
87
- var LobsHeader = function (_a) {
88
- var selectedLOB = _a.selectedLOB;
124
+ var LobsHeader = function () {
125
+ var selectedLOB = useHeaderContext().selectedLOB;
89
126
  return jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
90
127
  className: 'flex p-4 flex-middle flex-center p-sticky',
91
128
  css: {
@@ -189,7 +226,6 @@ function HeaderAnimatedMask(_a) {
189
226
  var showFlagProxy = useDelayedUnmount(show, 300);
190
227
  var triggerTransition = useMountTransition(show, 100);
191
228
  var triggerOpenTransition = triggerTransition;
192
- console.log(show, showFlagProxy, 'custom hook');
193
229
  return jsxRuntime.jsxs(jsxRuntime.Fragment, {
194
230
  children: [showFlagProxy && jsxRuntime.jsx(ctDesignContainer.Container, {
195
231
  id: 'mask-container',
@@ -218,7 +254,7 @@ var MIN_CLOSE_DELAY = 150;
218
254
  var useHoverDropdown = function (_a) {
219
255
  var _b = _a === void 0 ? {} : _a,
220
256
  _c = _b.closeDelay,
221
- closeDelayArg = _c === void 0 ? 300 : _c,
257
+ closeDelayArg = _c === void 0 ? 0 : _c,
222
258
  _d = _b.openDelay,
223
259
  openDelay = _d === void 0 ? 500 : _d;
224
260
  var closeDelay = Math.max(closeDelayArg, MIN_CLOSE_DELAY);
@@ -323,18 +359,83 @@ var useDropdownAnimation = function (isOpen) {
323
359
  };
324
360
  };
325
361
 
362
+ var stringifyPayload = function (payload) {
363
+ var keys = Object.keys(payload);
364
+ var numericValues = [];
365
+ keys.forEach(function (key) {
366
+ if (numericValues.includes(key)) {
367
+ payload[key] = Number(payload[key]);
368
+ } else {
369
+ payload[key] = '' + payload[key];
370
+ }
371
+ });
372
+ return payload;
373
+ };
374
+ var isServer = function () {
375
+ return typeof window === 'undefined' || !window;
376
+ };
377
+ var getQueryParam = function (queryParam) {
378
+ if (isServer()) {
379
+ return '';
380
+ }
381
+ var urlParams = new URLSearchParams(window.location.search);
382
+ return urlParams.get(queryParam);
383
+ };
384
+ var ravenLoyaltyTypes = function (loyaltyType) {
385
+ switch (loyaltyType) {
386
+ case 'FkVip':
387
+ return 'fk_vip';
388
+ case 'FkPremium':
389
+ return 'fk_plus_premium';
390
+ case 'InsiderIcon':
391
+ return 'myntra_insidericon';
392
+ case 'InsiderElite':
393
+ return 'myntra_insiderelite';
394
+ default:
395
+ return '';
396
+ }
397
+ };
398
+ var ravenSDKTrigger = function (isUserLoggedIn, eventName, ravenPayload, customRavenPayload, ravenPushCallback, pageName) {
399
+ var _a;
400
+ var commonPayload = {
401
+ page_name: pageName,
402
+ platform: RAVEN_PLATFORMS.DESKTOP,
403
+ login_status: isUserLoggedIn ? 'yes' : 'no',
404
+ domain: (_a = window === null || window === void 0 ? void 0 : window.location) === null || _a === void 0 ? void 0 : _a.host
405
+ };
406
+ var newRavenPayload = stringifyPayload(ravenPayload);
407
+ var parsedCustomRavenPayload = stringifyPayload(customRavenPayload);
408
+ try {
409
+ ravenPushCallback(eventName, tslib.__assign(tslib.__assign(tslib.__assign({}, commonPayload), newRavenPayload), parsedCustomRavenPayload));
410
+ } catch (err) {
411
+ console.log(err);
412
+ return;
413
+ }
414
+ };
415
+
326
416
  var BusinessDropdownContent = function (_a) {
327
417
  var isOpen = _a.isOpen;
328
- var _b = react.useState(0),
329
- leftPosition = _b[0],
330
- setLeftPosition = _b[1];
418
+ var _b = useHeaderContext(),
419
+ isUserLoggedIn = _b.isUserLoggedIn,
420
+ ravenPushCallback = _b.ravenPushCallback,
421
+ ravenPageName = _b.ravenPageName,
422
+ ravenEventName = _b.ravenEventName,
423
+ loyaltyType = _b.loyaltyType,
424
+ _c = _b.ravenPayload,
425
+ ravenPayload = _c === void 0 ? {} : _c;
426
+ var _d = react.useState(0),
427
+ leftPosition = _d[0],
428
+ setLeftPosition = _d[1];
331
429
  var containerRef = useDropdownAnimation(isOpen).containerRef;
332
430
  react.useEffect(function () {
333
431
  var updatePosition = function () {
334
432
  if (containerRef.current) {
335
433
  var screenWidth = window.innerWidth;
336
434
  var containerWidth = containerRef.current.offsetWidth || 0;
337
- setLeftPosition((screenWidth - containerWidth) / 2);
435
+ var newLeft = (screenWidth - containerWidth) / 2;
436
+ if (newLeft !== leftPosition) {
437
+ setLeftPosition(newLeft);
438
+ }
338
439
  }
339
440
  };
340
441
  updatePosition();
@@ -342,7 +443,22 @@ var BusinessDropdownContent = function (_a) {
342
443
  return function () {
343
444
  return window.removeEventListener('resize', updatePosition);
344
445
  };
345
- }, []);
446
+ }, [containerRef, leftPosition]);
447
+ var handleBusinessDropdownClick = react.useCallback(function (link, title, ravenActionName) {
448
+ var _a;
449
+ var utmSource = (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic';
450
+ var actionName = ravenActionName ? "".concat(ravenActionName, "_business_click") : title ? "".concat(title.toLowerCase(), "_business_click") : '';
451
+ var defaultPayload = {
452
+ action_name: actionName,
453
+ action_type: 'click',
454
+ u_utm_source: utmSource,
455
+ loyalty_type: ravenLoyaltyTypes(loyaltyType)
456
+ };
457
+ if (link) {
458
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, defaultPayload, ravenPayload, ravenPushCallback, ravenPageName);
459
+ window.location.href = link;
460
+ }
461
+ }, [isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName, loyaltyType]);
346
462
  return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
347
463
  ref: containerRef,
348
464
  className: 'bg-neutral-100 o-hidden',
@@ -379,11 +495,16 @@ var BusinessDropdownContent = function (_a) {
379
495
  children: bdConfig.map(function (_a) {
380
496
  var title = _a.title,
381
497
  subtitle = _a.subtitle,
382
- details = _a.details;
498
+ details = _a.details,
499
+ link = _a.link,
500
+ ravenActionName = _a.ravenActionName;
383
501
  return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
384
502
  css: {
385
503
  width: '200px'
386
504
  },
505
+ onClick: function () {
506
+ return handleBusinessDropdownClick(link, title, ravenActionName);
507
+ },
387
508
  className: 'bd-hover-container c-pointer'
388
509
  }, {
389
510
  children: [jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
@@ -419,22 +540,16 @@ var BusinessDropdownContent = function (_a) {
419
540
  }));
420
541
  };
421
542
  var AnimatedArrow = function () {
422
- return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
543
+ return jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
423
544
  className: 'bd-arrow-container'
424
545
  }, {
425
- children: [jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
426
- className: 'bd-arrow-wrapper'
427
- }, {
428
- children: jsxRuntime.jsx(ctDesignIcons.ArrowRight, {})
429
- })), jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
430
- className: 'bd-arrow-wrapper'
431
- }, {
432
- children: jsxRuntime.jsx(ctDesignIcons.ArrowRight, {})
433
- })), jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
434
- className: 'bd-arrow-wrapper'
435
- }, {
436
- children: jsxRuntime.jsx(ctDesignIcons.ArrowRight, {})
437
- }))]
546
+ children: tslib.__spreadArray([], Array(3), true).map(function (_, index) {
547
+ return jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
548
+ className: 'bd-arrow-wrapper'
549
+ }, {
550
+ children: jsxRuntime.jsx(ctDesignIcons.ArrowRight, {})
551
+ }), index);
552
+ })
438
553
  }));
439
554
  };
440
555
 
@@ -487,6 +602,7 @@ var ACCOUNT_OPTIONS_POPUP_CONFIG = [{
487
602
  redirectionLink: 'accounts/personal-data-dashboard'
488
603
  }];
489
604
  var SIGN_OUT_TEXT = 'Logout';
605
+ var MY_ACCOUNT_TEXT = 'My Account';
490
606
  var LOGGEDIN_USER_TEXT = 'You are logged in with';
491
607
  var HEADER_ACCOUNTS_OPTIONS_OPEN_BTN_ID = 'header-acc-btn';
492
608
  var ACCOUNT_OPTIONS_CONTAINER_ID = 'account-options';
@@ -497,13 +613,33 @@ var LoyaltyChip = function (_a) {
497
613
  borderGradient = _a.borderGradient,
498
614
  backgroundGradient = _a.backgroundGradient,
499
615
  handleChipClick = _a.handleChipClick;
500
- var _b = react.useState(false),
501
- isHovered = _b[0],
502
- setIsHovered = _b[1];
503
- var handleClick = function () {
504
- window.location.href = '/';
505
- handleChipClick && handleChipClick();
506
- };
616
+ var _b = useHeaderContext(),
617
+ loyaltyType = _b.loyaltyType,
618
+ isUserLoggedIn = _b.isUserLoggedIn,
619
+ ravenPushCallback = _b.ravenPushCallback,
620
+ ravenPageName = _b.ravenPageName,
621
+ _c = _b.ravenPayload,
622
+ ravenPayload = _c === void 0 ? {} : _c,
623
+ ravenEventName = _b.ravenEventName;
624
+ var _d = react.useState(false),
625
+ isHovered = _d[0],
626
+ setIsHovered = _d[1];
627
+ var handleClick = react.useCallback(function () {
628
+ var _a;
629
+ if (handleChipClick) {
630
+ handleChipClick();
631
+ } else {
632
+ var utmSource = (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic';
633
+ var defaultPayload = {
634
+ action_name: "loyalty_account_click",
635
+ action_type: 'click',
636
+ u_utm_source: utmSource,
637
+ loyaltyType: ravenLoyaltyTypes(loyaltyType)
638
+ };
639
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, defaultPayload, ravenPayload, ravenPushCallback, ravenPageName);
640
+ window.location.href = '/all-offers/loyalty-october';
641
+ }
642
+ }, [handleChipClick, loyaltyType, isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
507
643
  return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
508
644
  className: 'flex p-relative flex-middle flex-center br-8 o-hidden c-pointer',
509
645
  style: {
@@ -602,17 +738,39 @@ var ExpandableItem = function (_a) {
602
738
  handleChipClick = _a.handleChipClick,
603
739
  value = _a.value,
604
740
  type = _a.type;
605
- var _b = react.useState(false),
606
- isHovered = _b[0],
607
- setIsHovered = _b[1];
608
- var handleDefaultClick = function () {
609
- if (type === 'supercoins') {
610
- window.location.href = '/supercoins';
611
- } else if (type === 'wallet') {
612
- window.location.href = '/wallet';
741
+ var _b = useHeaderContext(),
742
+ loyaltyType = _b.loyaltyType,
743
+ isUserLoggedIn = _b.isUserLoggedIn,
744
+ ravenPushCallback = _b.ravenPushCallback,
745
+ ravenPageName = _b.ravenPageName,
746
+ ravenEventName = _b.ravenEventName,
747
+ _c = _b.ravenPayload,
748
+ ravenPayload = _c === void 0 ? {} : _c;
749
+ var _d = react.useState(false),
750
+ isHovered = _d[0],
751
+ setIsHovered = _d[1];
752
+ var handleDefaultClick = react.useCallback(function () {
753
+ var _a;
754
+ if (handleChipClick) {
755
+ handleChipClick();
756
+ } else {
757
+ var utmSource = (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic';
758
+ var defaultPayload = {
759
+ action_name: "".concat(type, "_account_click"),
760
+ action_type: 'click',
761
+ u_utm_source: utmSource,
762
+ loyaltyType: ravenLoyaltyTypes(loyaltyType)
763
+ };
764
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, defaultPayload, ravenPayload, ravenPushCallback, ravenPageName);
765
+ var redirectUrls = {
766
+ supercoin: '/all-offers/supercoins/',
767
+ wallet: '/accounts/wallet'
768
+ };
769
+ if (redirectUrls[type]) {
770
+ window.location.href = redirectUrls[type];
771
+ }
613
772
  }
614
- handleChipClick && handleChipClick();
615
- };
773
+ }, [handleChipClick, type, loyaltyType, isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
616
774
  return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
617
775
  className: "flex flex-middle justify-center br-8 c-pointer",
618
776
  style: {
@@ -652,21 +810,22 @@ var ExpandableItem = function (_a) {
652
810
  }))]
653
811
  }));
654
812
  };
655
- var RewardsSection = function (props) {
656
- var selectedLoyaltyType = props.loyaltyType,
657
- _a = props.fkSupercoinBurnBalance,
658
- superCoinBalance = _a === void 0 ? 0 : _a,
659
- _b = props.walletBalance,
660
- walletBalance = _b === void 0 ? 0 : _b,
661
- loyaltyLoading = props.loyaltyLoading,
662
- superCoinsLoading = props.superCoinsLoading,
663
- walletLoading = props.walletLoading,
664
- walletChipClick = props.walletChipClick,
665
- supercoinsChipClick = props.supercoinsChipClick,
666
- loyaltyChipClick = props.loyaltyChipClick,
667
- hideWalletChip = props.hideWalletChip,
668
- hideSupercoinsChip = props.hideSupercoinsChip,
669
- hideLoyaltyChip = props.hideLoyaltyChip;
813
+ var RewardsSection = function () {
814
+ var _a = useHeaderContext(),
815
+ selectedLoyaltyType = _a.loyaltyType,
816
+ _b = _a.fkSupercoinBurnBalance,
817
+ superCoinBalance = _b === void 0 ? 0 : _b,
818
+ _c = _a.walletBalance,
819
+ walletBalance = _c === void 0 ? 0 : _c,
820
+ loyaltyLoading = _a.loyaltyLoading,
821
+ superCoinsLoading = _a.superCoinsLoading,
822
+ walletLoading = _a.walletLoading,
823
+ walletChipClick = _a.walletChipClick,
824
+ supercoinsChipClick = _a.supercoinsChipClick,
825
+ loyaltyChipClick = _a.loyaltyChipClick,
826
+ hideWalletChip = _a.hideWalletChip,
827
+ hideSupercoinsChip = _a.hideSupercoinsChip,
828
+ hideLoyaltyChip = _a.hideLoyaltyChip;
670
829
  return jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
671
830
  className: 'flex p-4 pt-0 flex-start flex-gap-1',
672
831
  style: {
@@ -693,7 +852,7 @@ var RewardsSection = function (props) {
693
852
  }),
694
853
  value: superCoinBalance,
695
854
  handleChipClick: supercoinsChipClick,
696
- type: 'supercoins'
855
+ type: 'supercoin'
697
856
  }), walletLoading ? jsxRuntime.jsx(ctDesignShimmer.Shimmer, {
698
857
  width: '50px',
699
858
  height: '32px',
@@ -710,53 +869,58 @@ var RewardsSection = function (props) {
710
869
  }));
711
870
  };
712
871
 
713
- var AccountDropdownContent = function (props) {
714
- var _a = props || {},
715
- handleLogout = _a.handleLogout,
716
- userName = _a.userName,
717
- userMobileNumber = _a.userMobileNumber,
718
- countryCode = _a.countryCode,
719
- userDetailsLoading = _a.userDetailsLoading,
720
- superCoinBalance = _a.fkSupercoinBurnBalance,
721
- walletBalance = _a.walletBalance,
722
- loyaltyType = _a.loyaltyType,
723
- loyaltyLoading = _a.loyaltyLoading,
724
- walletLoading = _a.walletLoading,
725
- superCoinsLoading = _a.superCoinsLoading,
726
- walletChipClick = _a.walletChipClick,
727
- supercoinsChipClick = _a.supercoinsChipClick,
728
- loyaltyChipClick = _a.loyaltyChipClick,
729
- hideLoyaltyChip = _a.hideLoyaltyChip,
730
- hideSupercoinsChip = _a.hideSupercoinsChip,
731
- hideWalletChip = _a.hideWalletChip,
732
- isOpen = _a.isOpen;
872
+ var AccountDropdownContent = function (_a) {
873
+ var isOpen = _a.isOpen;
874
+ var _b = useHeaderContext(),
875
+ handleLogoutClick = _b.handleLogoutClick,
876
+ userName = _b.userName,
877
+ userMobileNumber = _b.userMobileNumber,
878
+ countryCode = _b.countryCode,
879
+ userDetailsLoading = _b.userDetailsLoading,
880
+ loyaltyType = _b.loyaltyType,
881
+ isUserLoggedIn = _b.isUserLoggedIn,
882
+ ravenEventName = _b.ravenEventName,
883
+ ravenPageName = _b.ravenPageName,
884
+ _c = _b.ravenPayload,
885
+ ravenPayload = _c === void 0 ? {} : _c,
886
+ ravenPushCallback = _b.ravenPushCallback;
733
887
  var containerRef = useDropdownAnimation(isOpen).containerRef;
734
- var _b = react.useMemo(function () {
735
- var userGreeting = userName && "Hello ".concat(userName, "!");
736
- var phoneNumber = countryCode && userMobileNumber ? "".concat(countryCode, " ").concat(userMobileNumber) : '';
888
+ var _d = react.useMemo(function () {
737
889
  return {
738
- userGreeting: userGreeting,
739
- phoneNumber: phoneNumber
890
+ userGreeting: userName ? "Hello ".concat(userName, "!") : '',
891
+ phoneNumber: countryCode && userMobileNumber ? "".concat(countryCode, " ").concat(userMobileNumber) : ''
740
892
  };
741
893
  }, [userName, userMobileNumber, countryCode]),
742
- userGreeting = _b.userGreeting,
743
- phoneNumber = _b.phoneNumber;
744
- var handleRedirectClick = function (redirectLink) {
745
- return function () {
746
- window.location.href = redirectLink;
894
+ userGreeting = _d.userGreeting,
895
+ phoneNumber = _d.phoneNumber;
896
+ var generateRavenPayload = function (actionName) {
897
+ var _a;
898
+ return {
899
+ action_name: actionName.toLowerCase().replace(/[\s-]/g, '') + '_account_click',
900
+ action_type: 'click',
901
+ u_utm_source: (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic',
902
+ loyalty_type: ravenLoyaltyTypes(loyaltyType)
747
903
  };
748
904
  };
749
- react.useEffect(function () {
905
+ var handleAccountOptionsClick = react.useCallback(function (text, redirectLink) {
906
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, generateRavenPayload(text), ravenPayload, ravenPushCallback, ravenPageName);
907
+ window.location.href = redirectLink;
908
+ }, [isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
909
+ var handleLogout = react.useCallback(function () {
910
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, generateRavenPayload(SIGN_OUT_TEXT), ravenPayload, ravenPushCallback, ravenPageName);
911
+ handleLogoutClick();
912
+ }, [isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName, handleLogoutClick]);
913
+ var positionAccountOptionsDiv = react.useCallback(function () {
750
914
  var headerAccBtn = document.getElementById(HEADER_ACCOUNTS_OPTIONS_OPEN_BTN_ID);
751
915
  var accountOptionsElem = document.getElementById(ACCOUNT_OPTIONS_CONTAINER_ID);
752
- var positionAccountOptionsDiv = function () {
753
- var headerBtnRight = headerAccBtn === null || headerAccBtn === void 0 ? void 0 : headerAccBtn.getBoundingClientRect().right;
754
- if (accountOptionsElem && headerBtnRight) {
755
- accountOptionsElem.style.left = "".concat(headerBtnRight - ACCOUNT_OPTIONS_CONTAINER_WIDTH, "px");
756
- }
757
- };
758
- positionAccountOptionsDiv();
916
+ if (headerAccBtn && accountOptionsElem) {
917
+ var headerBtnRight = headerAccBtn.getBoundingClientRect().right;
918
+ accountOptionsElem.style.left = "".concat(headerBtnRight - ACCOUNT_OPTIONS_CONTAINER_WIDTH, "px");
919
+ }
759
920
  }, []);
921
+ react.useEffect(function () {
922
+ positionAccountOptionsDiv();
923
+ }, [positionAccountOptionsDiv]);
760
924
  var renderUserData = function () {
761
925
  var renderContent = function (loading, content, variant, color) {
762
926
  return jsxRuntime.jsx(ctDesignTypography.Typography, tslib.__assign({
@@ -797,20 +961,7 @@ var AccountDropdownContent = function (props) {
797
961
  height: '72px'
798
962
  }, {
799
963
  children: renderUserData()
800
- })), jsxRuntime.jsx(RewardsSection, {
801
- fkSupercoinBurnBalance: superCoinBalance,
802
- walletBalance: walletBalance,
803
- loyaltyType: loyaltyType,
804
- loyaltyLoading: loyaltyLoading,
805
- superCoinsLoading: superCoinsLoading,
806
- walletLoading: walletLoading,
807
- walletChipClick: walletChipClick,
808
- supercoinsChipClick: supercoinsChipClick,
809
- loyaltyChipClick: loyaltyChipClick,
810
- hideLoyaltyChip: hideLoyaltyChip,
811
- hideSupercoinsChip: hideSupercoinsChip,
812
- hideWalletChip: hideWalletChip
813
- }), jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
964
+ })), jsxRuntime.jsx(RewardsSection, {}), jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
814
965
  className: 'p-2 flex flex-column',
815
966
  backgroundColor: 'white',
816
967
  style: {
@@ -825,7 +976,9 @@ var AccountDropdownContent = function (props) {
825
976
  redirectionLink = _a.redirectionLink;
826
977
  return jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
827
978
  className: 'p-2 br-8 c-pointer hoverable-container',
828
- onClick: handleRedirectClick(redirectionLink)
979
+ onClick: function () {
980
+ return handleAccountOptionsClick(text, redirectionLink);
981
+ }
829
982
  }, {
830
983
  children: jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
831
984
  className: 'flex c-pointer',
@@ -864,32 +1017,48 @@ var AccountDropdownContent = function (props) {
864
1017
  }));
865
1018
  };
866
1019
 
867
- var UserAccount = function (props) {
868
- var handleLogout = props.handleLogout,
869
- userDetailsLoading = props.userDetailsLoading,
870
- userName = props.userName,
871
- userMobileNumber = props.userMobileNumber,
872
- countryCode = props.countryCode,
873
- fkSupercoinBurnBalance = props.fkSupercoinBurnBalance,
874
- walletBalance = props.walletBalance,
875
- loyaltyType = props.loyaltyType,
876
- walletLoading = props.walletLoading,
877
- superCoinsLoading = props.superCoinsLoading,
878
- loyaltyLoading = props.loyaltyLoading,
879
- loyaltyChipClick = props.loyaltyChipClick,
880
- supercoinsChipClick = props.supercoinsChipClick,
881
- walletChipClick = props.walletChipClick,
882
- hideLoyaltyChip = props.hideLoyaltyChip,
883
- hideSupercoinsChip = props.hideSupercoinsChip,
884
- hideWalletChip = props.hideWalletChip;
885
- var _a = useHoverDropdown({
886
- openDelay: 500
1020
+ var UserAccount = function () {
1021
+ var _a = useHeaderContext(),
1022
+ isNovacThemeEnabled = _a.isNovacThemeEnabled,
1023
+ ravenEventName = _a.ravenEventName,
1024
+ _b = _a.ravenPayload,
1025
+ ravenPayload = _b === void 0 ? {} : _b,
1026
+ ravenPushCallback = _a.ravenPushCallback,
1027
+ isUserLoggedIn = _a.isUserLoggedIn,
1028
+ loyaltyType = _a.loyaltyType,
1029
+ ravenPageName = _a.ravenPageName;
1030
+ var _c = useHoverDropdown({
1031
+ openDelay: 0
887
1032
  }),
888
- isDropdownVisible = _a.isDropdownVisible,
889
- handleOnMouseEnter = _a.handleOnMouseEnter,
890
- handleOnMouseLeave = _a.handleOnMouseLeave,
891
- handleDropdownMouseEnter = _a.handleDropdownMouseEnter,
892
- handleDropdownMouseLeave = _a.handleDropdownMouseLeave;
1033
+ isDropdownVisible = _c.isDropdownVisible,
1034
+ handleOnMouseEnter = _c.handleOnMouseEnter,
1035
+ handleOnMouseLeave = _c.handleOnMouseLeave,
1036
+ handleDropdownMouseEnter = _c.handleDropdownMouseEnter,
1037
+ handleDropdownMouseLeave = _c.handleDropdownMouseLeave;
1038
+ var _d = react.useState(false),
1039
+ scrolled = _d[0],
1040
+ setScrolled = _d[1];
1041
+ react.useEffect(function () {
1042
+ var handleScroll = function () {
1043
+ setScrolled(window.scrollY >= 100);
1044
+ };
1045
+ window.addEventListener('scroll', handleScroll);
1046
+ return function () {
1047
+ return window.removeEventListener('scroll', handleScroll);
1048
+ };
1049
+ }, []);
1050
+ var effectiveNovacThemeEnabled = isNovacThemeEnabled && !scrolled;
1051
+ var triggerRavenEventOnHover = react.useCallback(function () {
1052
+ var _a;
1053
+ var utmSource = (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic';
1054
+ var defaultPayload = {
1055
+ action_name: "".concat(MY_ACCOUNT_TEXT.toLowerCase().replace(/[\s-]/g, ''), "_header_hover"),
1056
+ action_type: 'hover',
1057
+ u_utm_source: utmSource,
1058
+ loyalty_type: ravenLoyaltyTypes(loyaltyType)
1059
+ };
1060
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, defaultPayload, ravenPayload, ravenPushCallback, ravenPageName);
1061
+ }, [isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName, loyaltyType]);
893
1062
  return jsxRuntime.jsxs(ctDesignContainer.Container, {
894
1063
  children: [jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
895
1064
  className: "flex px-3 py-2 flex-middle br-12 h-100p c-pointer",
@@ -898,26 +1067,27 @@ var UserAccount = function (props) {
898
1067
  height: 64
899
1068
  },
900
1069
  onMouseEnter: function () {
901
- return handleOnMouseEnter(0);
1070
+ handleOnMouseEnter(0);
1071
+ triggerRavenEventOnHover();
902
1072
  },
903
1073
  onMouseLeave: handleOnMouseLeave,
904
1074
  id: HEADER_ACCOUNTS_OPTIONS_OPEN_BTN_ID
905
1075
  }, {
906
1076
  children: [jsxRuntime.jsx(ctDesignIcons.MyAccount, {
907
- color: isDropdownVisible ? '#FF4F17' : '#1A1A1A'
1077
+ color: isDropdownVisible ? '#FF4F17' : effectiveNovacThemeEnabled ? '#FFF' : '#1A1A1A'
908
1078
  }), jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
909
1079
  className: 'flex flex-row flex-middle'
910
1080
  }, {
911
1081
  children: [jsxRuntime.jsx(ctDesignTypography.Typography, tslib.__assign({
912
1082
  variant: 'B2',
913
1083
  className: 'c-pointer',
914
- color: isDropdownVisible ? 'secondary' : 'primary'
1084
+ color: isDropdownVisible ? 'secondary' : effectiveNovacThemeEnabled ? 'neutral' : 'primary'
915
1085
  }, {
916
- children: "My Account"
1086
+ children: MY_ACCOUNT_TEXT
917
1087
  })), jsxRuntime.jsx(ctDesignIcons.ChevronDown, {
918
1088
  width: 20,
919
1089
  height: 20,
920
- fill: isDropdownVisible ? '#FF4F17' : '#1A1A1A'
1090
+ fill: isDropdownVisible ? '#FF4F17' : effectiveNovacThemeEnabled ? '#FFF' : '#1A1A1A'
921
1091
  })]
922
1092
  }))]
923
1093
  })), jsxRuntime.jsx(HeaderAnimatedMask, tslib.__assign({
@@ -928,23 +1098,6 @@ var UserAccount = function (props) {
928
1098
  onMaskClick: handleDropdownMouseLeave
929
1099
  }, {
930
1100
  children: jsxRuntime.jsx(AccountDropdownContent, {
931
- handleLogout: handleLogout,
932
- userDetailsLoading: userDetailsLoading,
933
- userName: userName,
934
- userMobileNumber: userMobileNumber,
935
- countryCode: countryCode,
936
- loyaltyType: loyaltyType,
937
- walletBalance: walletBalance,
938
- fkSupercoinBurnBalance: fkSupercoinBurnBalance,
939
- walletLoading: walletLoading,
940
- superCoinsLoading: superCoinsLoading,
941
- loyaltyLoading: loyaltyLoading,
942
- loyaltyChipClick: loyaltyChipClick,
943
- walletChipClick: walletChipClick,
944
- supercoinsChipClick: supercoinsChipClick,
945
- hideLoyaltyChip: hideLoyaltyChip,
946
- hideSupercoinsChip: hideSupercoinsChip,
947
- hideWalletChip: hideWalletChip,
948
1101
  isOpen: isDropdownVisible
949
1102
  })
950
1103
  }))]
@@ -952,47 +1105,86 @@ var UserAccount = function (props) {
952
1105
  };
953
1106
 
954
1107
  var Header = function (props) {
955
- var superCoinsLoading = props.superCoinsLoading,
956
- fkSupercoinBurnBalance = props.fkSupercoinBurnBalance,
957
- onLoginButtonClick = props.onLoginButtonClick,
958
- _a = props.showAllLobs,
959
- showAllLobs = _a === void 0 ? false : _a,
960
- selectedLOB = props.selectedLOB,
961
- isUserLoggedIn = props.isUserLoggedIn,
962
- handleLogoutClick = props.handleLogoutClick,
963
- walletBalance = props.walletBalance,
964
- walletLoading = props.walletLoading,
965
- loyaltyLoading = props.loyaltyLoading,
966
- loyaltyType = props.loyaltyType,
967
- userDetailsLoading = props.userDetailsLoading,
968
- userName = props.userName,
969
- userMobileNumber = props.userMobileNumber,
970
- countryCode = props.countryCode,
971
- loyaltyChipClick = props.loyaltyChipClick,
972
- supercoinsChipClick = props.supercoinsChipClick,
973
- walletChipClick = props.walletChipClick,
974
- hideLoyaltyChip = props.hideLoyaltyChip,
975
- hideSupercoinsChip = props.hideSupercoinsChip,
976
- hideWalletChip = props.hideWalletChip;
977
- props.ravenPayload;
978
- props.ravenPushCallback;
979
- var _c = useHoverDropdown({
980
- openDelay: 500
1108
+ return jsxRuntime.jsx(HeaderProvider, tslib.__assign({
1109
+ value: props
1110
+ }, {
1111
+ children: jsxRuntime.jsx(HeaderContent, {})
1112
+ }));
1113
+ };
1114
+ var HeaderContent = function () {
1115
+ var _a;
1116
+ var _b = useHeaderContext(),
1117
+ onLoginButtonClick = _b.onLoginButtonClick,
1118
+ _c = _b.showAllLobs,
1119
+ showAllLobs = _c === void 0 ? false : _c,
1120
+ isUserLoggedIn = _b.isUserLoggedIn,
1121
+ loyaltyType = _b.loyaltyType,
1122
+ _d = _b.isNovacThemeEnabled,
1123
+ isNovacThemeEnabled = _d === void 0 ? false : _d,
1124
+ _e = _b.ravenPayload,
1125
+ ravenPayload = _e === void 0 ? {} : _e,
1126
+ ravenPushCallback = _b.ravenPushCallback,
1127
+ ravenPageName = _b.ravenPageName,
1128
+ ravenEventName = _b.ravenEventName;
1129
+ var _f = react.useState(false),
1130
+ scrolled = _f[0],
1131
+ setScrolled = _f[1];
1132
+ react.useEffect(function () {
1133
+ var handleScroll = function () {
1134
+ setScrolled(window.scrollY >= 100);
1135
+ };
1136
+ window.addEventListener('scroll', handleScroll);
1137
+ return function () {
1138
+ return window.removeEventListener('scroll', handleScroll);
1139
+ };
1140
+ }, []);
1141
+ var effectiveNovacThemeEnabled = isNovacThemeEnabled && !scrolled;
1142
+ var headerBackground = effectiveNovacThemeEnabled ? 'transparent' : '#F7FAFF';
1143
+ var _g = useHoverDropdown({
1144
+ openDelay: 0
981
1145
  }),
982
- isDropdownVisible = _c.isDropdownVisible,
983
- hoveredElemIndex = _c.hoveredElemIndex,
984
- handleOnMouseEnter = _c.handleOnMouseEnter,
985
- handleOnMouseLeave = _c.handleOnMouseLeave,
986
- handleDropdownMouseEnter = _c.handleDropdownMouseEnter,
987
- handleDropdownMouseLeave = _c.handleDropdownMouseLeave;
1146
+ isDropdownVisible = _g.isDropdownVisible,
1147
+ hoveredElemIndex = _g.hoveredElemIndex,
1148
+ handleOnMouseEnter = _g.handleOnMouseEnter,
1149
+ handleOnMouseLeave = _g.handleOnMouseLeave,
1150
+ handleDropdownMouseEnter = _g.handleDropdownMouseEnter,
1151
+ handleDropdownMouseLeave = _g.handleDropdownMouseLeave;
1152
+ var utmSource = (_a = getQueryParam('utm_source')) !== null && _a !== void 0 ? _a : 'organic';
1153
+ var createPayload = react.useCallback(function (actionName, actionType) {
1154
+ return {
1155
+ action_name: actionName,
1156
+ action_type: actionType,
1157
+ u_utm_source: utmSource,
1158
+ loyalty_type: ravenLoyaltyTypes(loyaltyType)
1159
+ };
1160
+ }, [utmSource, loyaltyType]);
1161
+ var handleNavbarOptionsClick = react.useCallback(function (option) {
1162
+ if (option.isClickable && option.link) {
1163
+ var actionName = "".concat(option.text.toLowerCase().replace(/\s/g, ''), "_header_click");
1164
+ var payload = createPayload(actionName, 'click');
1165
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, payload, ravenPayload, ravenPushCallback, ravenPageName);
1166
+ window.location.href = option.link;
1167
+ }
1168
+ }, [createPayload, isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
1169
+ var handleHomeClick = react.useCallback(function () {
1170
+ var payload = createPayload('home_header_click', 'click');
1171
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, payload, ravenPayload, ravenPushCallback, ravenPageName);
1172
+ window.location.href = '/';
1173
+ }, [createPayload, isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
1174
+ var triggerRavenEventOnHover = react.useCallback(function (option) {
1175
+ var actionName = "".concat(option.text.toLowerCase().replace(/\s/g, ''), "_header_hover");
1176
+ var payload = createPayload(actionName, 'hover');
1177
+ ravenSDKTrigger(isUserLoggedIn, ravenEventName, payload, ravenPayload, ravenPushCallback, ravenPageName);
1178
+ }, [createPayload, isUserLoggedIn, ravenEventName, ravenPayload, ravenPushCallback, ravenPageName]);
988
1179
  return jsxRuntime.jsxs(jsxRuntime.Fragment, {
989
1180
  children: [jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
990
1181
  className: 'flex t-0 p-sticky w-100p flex-middle flex-center flex-gap-6 flex-no-shrink',
991
1182
  style: {
992
1183
  zIndex: 1000,
993
1184
  height: 64,
994
- borderBottom: '1px solid #E6E6E6',
995
- background: '#F7FAFF'
1185
+ borderBottom: effectiveNovacThemeEnabled ? '' : '1px solid #E6E6E6',
1186
+ background: headerBackground,
1187
+ transition: 'background-color 0.3s ease-in-out, border-bottom 0.3s ease-in-out'
996
1188
  }
997
1189
  }, {
998
1190
  children: jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
@@ -1004,9 +1196,12 @@ var Header = function (props) {
1004
1196
  }
1005
1197
  }, {
1006
1198
  children: [jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
1007
- className: 'flex flex-row flex-center flex-middle'
1199
+ className: 'flex flex-row flex-center flex-middle c-pointer',
1200
+ onClick: handleHomeClick
1008
1201
  }, {
1009
- children: [jsxRuntime.jsx(ctDesignIcons.CTLogo, {}), jsxRuntime.jsx(ctDesignDivider.Divider, {
1202
+ children: [jsxRuntime.jsx(ctDesignIcons.CTLogo, {
1203
+ fillColor: effectiveNovacThemeEnabled ? '#FFF' : '#FF4F17'
1204
+ }), jsxRuntime.jsx(ctDesignDivider.Divider, {
1010
1205
  style: {
1011
1206
  width: 12,
1012
1207
  marginLeft: 2,
@@ -1014,7 +1209,9 @@ var Header = function (props) {
1014
1209
  transform: 'rotate(90deg)',
1015
1210
  borderBottom: '1px solid #e0e0e0'
1016
1211
  }
1017
- }), jsxRuntime.jsx(ctDesignIcons.Fkcompany, {})]
1212
+ }), jsxRuntime.jsx(ctDesignIcons.Fkcompany, {
1213
+ color: effectiveNovacThemeEnabled ? '#FFF' : '#1A1A1A'
1214
+ })]
1018
1215
  })), jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
1019
1216
  className: 'flex flex-row flex-middle flex-center flex-cg-6'
1020
1217
  }, {
@@ -1026,7 +1223,10 @@ var Header = function (props) {
1026
1223
  return jsxRuntime.jsxs(ctDesignContainer.Container, {
1027
1224
  children: [jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
1028
1225
  onMouseEnter: function () {
1029
- return handleOnMouseEnter(index);
1226
+ handleOnMouseEnter(index);
1227
+ if (option.isHoverable) {
1228
+ triggerRavenEventOnHover(option);
1229
+ }
1030
1230
  },
1031
1231
  onMouseLeave: handleOnMouseLeave,
1032
1232
  className: 'flex flex-row flex-middle px-3 py-2 c-pointer p-relative',
@@ -1035,26 +1235,24 @@ var Header = function (props) {
1035
1235
  height: 64
1036
1236
  },
1037
1237
  onClick: function () {
1038
- if (option.isClickable) {
1039
- window.location.href = option.link;
1040
- }
1238
+ return handleNavbarOptionsClick(option);
1041
1239
  }
1042
1240
  }, {
1043
1241
  children: [jsxRuntime.jsx(option.lefticon, {
1044
- color: isHovered ? '#FF4F17' : '#1A1A1A'
1242
+ color: isHovered ? '#FF4F17' : effectiveNovacThemeEnabled ? '#FFF' : '#1A1A1A'
1045
1243
  }), jsxRuntime.jsxs(ctDesignContainer.Container, tslib.__assign({
1046
1244
  className: 'flex flex-row flex-middle'
1047
1245
  }, {
1048
1246
  children: [jsxRuntime.jsx(ctDesignTypography.Typography, tslib.__assign({
1049
1247
  variant: 'B2',
1050
- color: isHovered ? 'secondary' : 'primary',
1248
+ color: isHovered ? 'secondary' : effectiveNovacThemeEnabled ? 'neutral' : 'primary',
1051
1249
  isClickable: true
1052
1250
  }, {
1053
1251
  children: option.text
1054
1252
  })), option.rightIcon && jsxRuntime.jsx(option.rightIcon, {
1055
1253
  width: 20,
1056
1254
  height: 20,
1057
- fill: isHovered ? '#FF4F17' : '#1A1A1A'
1255
+ fill: isHovered ? '#FF4F17' : effectiveNovacThemeEnabled ? '#FFF' : '#1A1A1A'
1058
1256
  })]
1059
1257
  }))]
1060
1258
  }), "nav-option-".concat(index)), jsxRuntime.jsx(HeaderAnimatedMask, tslib.__assign({
@@ -1081,38 +1279,21 @@ var Header = function (props) {
1081
1279
  children: isUserLoggedIn ? jsxRuntime.jsx(ctDesignContainer.Container, tslib.__assign({
1082
1280
  className: 'flex flex-row flex-middle'
1083
1281
  }, {
1084
- children: jsxRuntime.jsx(UserAccount, {
1085
- handleLogout: handleLogoutClick,
1086
- superCoinsLoading: superCoinsLoading,
1087
- fkSupercoinBurnBalance: fkSupercoinBurnBalance,
1088
- walletBalance: walletBalance,
1089
- walletLoading: walletLoading,
1090
- loyaltyLoading: loyaltyLoading,
1091
- loyaltyType: loyaltyType,
1092
- userDetailsLoading: userDetailsLoading,
1093
- userName: userName,
1094
- userMobileNumber: userMobileNumber,
1095
- countryCode: countryCode,
1096
- walletChipClick: walletChipClick,
1097
- supercoinsChipClick: supercoinsChipClick,
1098
- loyaltyChipClick: loyaltyChipClick,
1099
- hideLoyaltyChip: hideLoyaltyChip,
1100
- hideSupercoinsChip: hideSupercoinsChip,
1101
- hideWalletChip: hideWalletChip
1102
- })
1282
+ children: jsxRuntime.jsx(UserAccount, {})
1103
1283
  })) : jsxRuntime.jsx(ctDesignButton.Button, tslib.__assign({
1104
- className: "fw-400 fs-14 login-button",
1284
+ className: "fw-400 fs-14 ".concat(effectiveNovacThemeEnabled ? 'novac-login-button' : 'login-button'),
1105
1285
  onClick: onLoginButtonClick,
1106
1286
  style: {
1107
1287
  width: 153,
1108
1288
  height: 40,
1109
- border: '1px solid #1A1A1A'
1289
+ border: effectiveNovacThemeEnabled ? '1px solid #FFF' : '1px solid #1A1A1A'
1110
1290
  },
1111
1291
  loading: false
1112
1292
  }, {
1113
1293
  children: jsxRuntime.jsx(ctDesignTypography.Typography, tslib.__assign({
1114
1294
  componentNode: 'span',
1115
- variant: 'L2'
1295
+ variant: 'L2',
1296
+ color: effectiveNovacThemeEnabled ? 'neutral' : 'primary'
1116
1297
  }, {
1117
1298
  children: "Login"
1118
1299
  }))
@@ -1120,9 +1301,7 @@ var Header = function (props) {
1120
1301
  })]
1121
1302
  }))]
1122
1303
  }))
1123
- })), showAllLobs && jsxRuntime.jsx(LobsHeader, {
1124
- selectedLOB: selectedLOB
1125
- })]
1304
+ })), showAllLobs && jsxRuntime.jsx(LobsHeader, {})]
1126
1305
  });
1127
1306
  };
1128
1307