@sunrise-upc/sales-static-components 3.8.12 → 3.9.0-beta.1
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.
- package/README.md +8 -8
- package/dist/cjs/components/ButtonGroup/ButtonGroup.css +95 -95
- package/dist/cjs/components/FalconButton/falconButton.js.map +1 -1
- package/dist/cjs/components/FalconMainNavigation/FalconHeader/BusinessCustomerLinkOut/BusinessCustomerLinkOut.js.map +1 -1
- package/dist/cjs/components/FalconMainNavigation/FalconMainNavigation.css +0 -2
- package/dist/cjs/components/FalconMainNavigation/FalconMainNavigation.js +1 -1
- package/dist/cjs/components/FalconMainNavigation/FalconMainNavigation.js.map +1 -1
- package/dist/cjs/components/FalconMainNavigation/FalconMainNavigation.module.scss.css +0 -2
- package/dist/cjs/components/FalconMainNavigation/MobileNavigation/MobileMenuItem/MobileMenuItem.js.map +1 -1
- package/dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js +1 -1
- package/dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js.map +1 -1
- package/dist/cjs/components/InternetAndTvCardsBenefits/InternetAndTvCardItemBenefits.js +1 -1
- package/dist/cjs/components/InternetAndTvCardsBenefits/InternetAndTvCardItemBenefits.js.map +1 -1
- package/dist/cjs/components/RibbonComponent/RibbonComponent.css +389 -389
- package/dist/cjs/components/RibbonComponent/RibbonComponentTimer/RibbonComponentTimer.css +68 -68
- package/dist/cjs/components/RibbonRenderer/RibbonRenderer.js +1 -1
- package/dist/cjs/components/RibbonRenderer/RibbonRenderer.js.map +1 -1
- package/dist/cjs/components/StageTeaserComponent/DoubleGrid/DoubleGridComponent.css +937 -937
- package/dist/cjs/components/StageTeaserComponent/SingleGrid/SingleGridRedefined.js.map +1 -1
- package/dist/cjs/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.css +106 -87
- package/dist/cjs/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.js +1 -1
- package/dist/cjs/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.js.map +1 -1
- package/dist/cjs/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.module.scss.css +19 -0
- package/dist/cjs/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.module.scss.js +1 -1
- package/dist/cjs/components/StageTeaserV3/SingleGrid/SingleGridComponent.css +136 -88
- package/dist/cjs/components/StageTeaserV3/SingleGrid/SingleGridComponent.js +1 -1
- package/dist/cjs/components/StageTeaserV3/SingleGrid/SingleGridComponent.js.map +1 -1
- package/dist/cjs/components/StageTeaserV3/SingleGrid/SingleGridComponent.module.scss.css +49 -1
- package/dist/cjs/components/StageTeaserV3/SingleGrid/SingleGridComponent.module.scss.js +1 -1
- package/dist/cjs/components/StageTeaserV3/StageTeaserV3.css +4 -4
- package/dist/cjs/components/StageTeaserV3/StageTeaserV3.js +1 -1
- package/dist/cjs/components/StageTeaserV3/StageTeaserV3.js.map +1 -1
- package/dist/cjs/components/StageTeaserV3/StageTeaserV3.module.scss.css +4 -4
- package/dist/cjs/components/StageTeaserV3/backgroundPriority.js +2 -0
- package/dist/cjs/components/StageTeaserV3/backgroundPriority.js.map +1 -0
- package/dist/cjs/components/linecheck/AutoComplete.css +484 -484
- package/dist/cjs/components/linecheck/LineCheckV2.css +484 -484
- package/dist/cjs/components/linecheck/Success.css +484 -484
- package/dist/cjs/node_modules/@algolia/client-common/dist/common.js +1 -1
- package/dist/cjs/node_modules/@algolia/client-common/dist/common.js.map +1 -1
- package/dist/cjs/node_modules/@algolia/requester-browser-xhr/dist/requester.xhr.js +1 -1
- package/dist/cjs/node_modules/@algolia/requester-browser-xhr/dist/requester.xhr.js.map +1 -1
- package/dist/cjs/node_modules/algoliasearch/dist/lite/builds/browser.js +1 -1
- package/dist/cjs/node_modules/algoliasearch/dist/lite/builds/browser.js.map +1 -1
- package/dist/cjs/node_modules/immer/dist/immer.js +1 -1
- package/dist/cjs/node_modules/immer/dist/immer.js.map +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/lib/InstantSearch.js +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/lib/InstantSearch.js.map +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/lib/version.js +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/lib/version.js.map +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/widgets/index/index.js +1 -1
- package/dist/cjs/node_modules/instantsearch.js/es/widgets/index/index.js.map +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/hooks/useConnector.js +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/hooks/useConnector.js.map +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/lib/InstantSearchRSCContext.js +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/lib/InstantSearchRSCContext.js.map +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/version.js +1 -1
- package/dist/cjs/node_modules/react-instantsearch-core/dist/es/version.js.map +1 -1
- package/dist/esm/components/ButtonGroup/ButtonGroup.css +95 -95
- package/dist/esm/components/FalconMainNavigation/FalconMainNavigation.css +0 -2
- package/dist/esm/components/FalconMainNavigation/FalconMainNavigation.js +1 -1
- package/dist/esm/components/FalconMainNavigation/FalconMainNavigation.js.map +1 -1
- package/dist/esm/components/FalconMainNavigation/FalconMainNavigation.module.scss.css +0 -2
- package/dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.js +1 -1
- package/dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.js.map +1 -1
- package/dist/esm/components/InternetAndTvCardsBenefits/InternetAndTvCardItemBenefits.js +1 -1
- package/dist/esm/components/InternetAndTvCardsBenefits/InternetAndTvCardItemBenefits.js.map +1 -1
- package/dist/esm/components/RibbonComponent/RibbonComponent.css +389 -389
- package/dist/esm/components/RibbonComponent/RibbonComponentTimer/RibbonComponentTimer.css +68 -68
- package/dist/esm/components/RibbonRenderer/RibbonRenderer.js +1 -1
- package/dist/esm/components/RibbonRenderer/RibbonRenderer.js.map +1 -1
- package/dist/esm/components/StageTeaserComponent/DoubleGrid/DoubleGridComponent.css +937 -937
- package/dist/esm/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.css +106 -87
- package/dist/esm/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.js +1 -1
- package/dist/esm/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.js.map +1 -1
- package/dist/esm/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.module.scss.css +19 -0
- package/dist/esm/components/StageTeaserV3/DoubleGrid/DoubleGridComponent.module.scss.js +1 -1
- package/dist/esm/components/StageTeaserV3/SingleGrid/SingleGridComponent.css +136 -88
- package/dist/esm/components/StageTeaserV3/SingleGrid/SingleGridComponent.js +1 -1
- package/dist/esm/components/StageTeaserV3/SingleGrid/SingleGridComponent.js.map +1 -1
- package/dist/esm/components/StageTeaserV3/SingleGrid/SingleGridComponent.module.scss.css +49 -1
- package/dist/esm/components/StageTeaserV3/SingleGrid/SingleGridComponent.module.scss.js +1 -1
- package/dist/esm/components/StageTeaserV3/StageTeaserV3.css +4 -4
- package/dist/esm/components/StageTeaserV3/StageTeaserV3.js +1 -1
- package/dist/esm/components/StageTeaserV3/StageTeaserV3.js.map +1 -1
- package/dist/esm/components/StageTeaserV3/StageTeaserV3.module.scss.css +4 -4
- package/dist/esm/components/StageTeaserV3/backgroundPriority.js +2 -0
- package/dist/esm/components/StageTeaserV3/backgroundPriority.js.map +1 -0
- package/dist/esm/components/linecheck/AutoComplete.css +484 -484
- package/dist/esm/components/linecheck/LineCheckV2.css +484 -484
- package/dist/esm/components/linecheck/Success.css +484 -484
- package/dist/esm/node_modules/@algolia/client-common/dist/common.js +1 -1
- package/dist/esm/node_modules/@algolia/client-common/dist/common.js.map +1 -1
- package/dist/esm/node_modules/@algolia/requester-browser-xhr/dist/requester.xhr.js +1 -1
- package/dist/esm/node_modules/@algolia/requester-browser-xhr/dist/requester.xhr.js.map +1 -1
- package/dist/esm/node_modules/algoliasearch/dist/lite/builds/browser.js +1 -1
- package/dist/esm/node_modules/algoliasearch/dist/lite/builds/browser.js.map +1 -1
- package/dist/esm/node_modules/immer/dist/immer.js +1 -1
- package/dist/esm/node_modules/immer/dist/immer.js.map +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/lib/InstantSearch.js +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/lib/InstantSearch.js.map +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/lib/version.js +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/lib/version.js.map +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/widgets/index/index.js +1 -1
- package/dist/esm/node_modules/instantsearch.js/es/widgets/index/index.js.map +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/hooks/useConnector.js +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/hooks/useConnector.js.map +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/lib/InstantSearchRSCContext.js +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/lib/InstantSearchRSCContext.js.map +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/version.js +1 -1
- package/dist/esm/node_modules/react-instantsearch-core/dist/es/version.js.map +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/navigation.css +198 -200
- package/package.json +115 -114
|
@@ -1,71 +1,71 @@
|
|
|
1
|
-
/* Mobile only viewport */
|
|
2
|
-
@media all and (max-width: 768px) {
|
|
3
|
-
.timer-wrap {
|
|
4
|
-
text-align: center !important;
|
|
5
|
-
margin-left: -4px !important;
|
|
6
|
-
margin-right: 0 !important;
|
|
7
|
-
}
|
|
8
|
-
.timer-container {
|
|
9
|
-
min-width: fit-content;
|
|
10
|
-
}
|
|
11
|
-
.timer-message {
|
|
12
|
-
margin-bottom: 10px;
|
|
13
|
-
}
|
|
14
|
-
.timer-section {
|
|
15
|
-
justify-content: center;
|
|
16
|
-
margin-top: 4px;
|
|
17
|
-
margin-left: unset !important;
|
|
18
|
-
margin-right: unset !important;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
/* Mobile and tablet viewport */
|
|
22
|
-
@media all and (max-width: 1023px) {
|
|
23
|
-
.timer-message {
|
|
24
|
-
margin-top: unset;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/* Tablet only viewport */
|
|
29
|
-
@media all and (min-width: 768px) and (max-width: 1023px) {
|
|
30
|
-
.timer-section {
|
|
31
|
-
margin-top: unset;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.timer-container {
|
|
36
|
-
color: black;
|
|
37
|
-
display: inline-block;
|
|
38
|
-
max-width: 100%;
|
|
39
|
-
min-width: fit-content;
|
|
40
|
-
}
|
|
41
|
-
.colon {
|
|
42
|
-
font-weight: 700;
|
|
43
|
-
font-size: 28px;
|
|
44
|
-
line-height: 36px;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
.timer-section {
|
|
48
|
-
display: flex;
|
|
49
|
-
padding: 8px 18px 8px 24px;
|
|
50
|
-
}
|
|
51
|
-
.timer-element {
|
|
52
|
-
display: inline-block;
|
|
53
|
-
min-width: 42px;
|
|
54
|
-
padding: 0 6px;
|
|
55
|
-
text-align: center;
|
|
56
|
-
}
|
|
57
|
-
.timer-value {
|
|
58
|
-
font-weight: 700;
|
|
59
|
-
font-size: 32px;
|
|
60
|
-
line-height: 36px;
|
|
61
|
-
}
|
|
62
|
-
.timer-label {
|
|
63
|
-
font-weight: 400;
|
|
64
|
-
font-size: 12px;
|
|
65
|
-
line-height: 16px;
|
|
66
|
-
}
|
|
67
|
-
.transparent-element:first-child {
|
|
68
|
-
padding-left: 0;
|
|
1
|
+
/* Mobile only viewport */
|
|
2
|
+
@media all and (max-width: 768px) {
|
|
3
|
+
.timer-wrap {
|
|
4
|
+
text-align: center !important;
|
|
5
|
+
margin-left: -4px !important;
|
|
6
|
+
margin-right: 0 !important;
|
|
7
|
+
}
|
|
8
|
+
.timer-container {
|
|
9
|
+
min-width: fit-content;
|
|
10
|
+
}
|
|
11
|
+
.timer-message {
|
|
12
|
+
margin-bottom: 10px;
|
|
13
|
+
}
|
|
14
|
+
.timer-section {
|
|
15
|
+
justify-content: center;
|
|
16
|
+
margin-top: 4px;
|
|
17
|
+
margin-left: unset !important;
|
|
18
|
+
margin-right: unset !important;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
/* Mobile and tablet viewport */
|
|
22
|
+
@media all and (max-width: 1023px) {
|
|
23
|
+
.timer-message {
|
|
24
|
+
margin-top: unset;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/* Tablet only viewport */
|
|
29
|
+
@media all and (min-width: 768px) and (max-width: 1023px) {
|
|
30
|
+
.timer-section {
|
|
31
|
+
margin-top: unset;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.timer-container {
|
|
36
|
+
color: black;
|
|
37
|
+
display: inline-block;
|
|
38
|
+
max-width: 100%;
|
|
39
|
+
min-width: fit-content;
|
|
40
|
+
}
|
|
41
|
+
.colon {
|
|
42
|
+
font-weight: 700;
|
|
43
|
+
font-size: 28px;
|
|
44
|
+
line-height: 36px;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.timer-section {
|
|
48
|
+
display: flex;
|
|
49
|
+
padding: 8px 18px 8px 24px;
|
|
50
|
+
}
|
|
51
|
+
.timer-element {
|
|
52
|
+
display: inline-block;
|
|
53
|
+
min-width: 42px;
|
|
54
|
+
padding: 0 6px;
|
|
55
|
+
text-align: center;
|
|
56
|
+
}
|
|
57
|
+
.timer-value {
|
|
58
|
+
font-weight: 700;
|
|
59
|
+
font-size: 32px;
|
|
60
|
+
line-height: 36px;
|
|
61
|
+
}
|
|
62
|
+
.timer-label {
|
|
63
|
+
font-weight: 400;
|
|
64
|
+
font-size: 12px;
|
|
65
|
+
line-height: 16px;
|
|
66
|
+
}
|
|
67
|
+
.transparent-element:first-child {
|
|
68
|
+
padding-left: 0;
|
|
69
69
|
}
|
|
70
70
|
/* center a block element */
|
|
71
71
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../RibbonComponent/utils.js"),r=require("../Constants.js"),i=require("../../services/customerSegmentSync.js");const o=e=>e.trim().toLowerCase(),s=()=>{if("undefined"==typeof window)return new Set;const e=window.localStorage.getItem("tealium_va");if(!e)return new Set;try{const t=JSON.parse(e),n=null==t?void 0:t.audiences;return n&&"object"==typeof n?new Set(Object.keys(n).filter(Boolean).map(e=>String(e).trim().toLowerCase())):new Set}catch(e){return new Set}},u=e=>e?Array.isArray(e)?e:[e]:[],c=e=>e?n.calculateDateTime(new Date(e.trim().replace(/-/g,"/"))):null,
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../RibbonComponent/utils.js"),r=require("../Constants.js"),i=require("../../services/customerSegmentSync.js");const o=e=>e.trim().toLowerCase(),s=()=>{if("undefined"==typeof window)return new Set;const e=window.localStorage.getItem("tealium_va");if(!e)return new Set;try{const t=JSON.parse(e),n=null==t?void 0:t.audiences;return n&&"object"==typeof n?new Set(Object.keys(n).filter(Boolean).map(e=>String(e).trim().toLowerCase())):new Set}catch(e){return new Set}},u=e=>e?Array.isArray(e)?e:[e]:[],a=()=>"undefined"==typeof navigator?"":navigator.userAgent||"",c=e=>e?n.calculateDateTime(new Date(e.trim().replace(/-/g,"/"))):null,l=()=>{if("undefined"==typeof window)return{};const e=window.localStorage.getItem(r.DISMISSED_RIBBONS_STORAGE_KEY);if(!e)return{};try{const t=JSON.parse(e);return t&&"object"==typeof t?Object.entries(t).reduce((e,[t,n])=>("string"==typeof t&&Number.isFinite(n)&&(e[t]=Number(n)),e),{}):{}}catch(e){return{}}},m=(e,t)=>{const n=Object.entries(e).filter(([,e])=>Number.isFinite(e)&&Number(e)>t),i=Object.fromEntries(n);return"undefined"!=typeof window&&(0===n.length?window.localStorage.removeItem(r.DISMISSED_RIBBONS_STORAGE_KEY):n.length!==Object.keys(e).length&&window.localStorage.setItem(r.DISMISSED_RIBBONS_STORAGE_KEY,JSON.stringify(i))),i};exports.default=({ribbonConfig:n,metadata:d,channel:f,renderRibbon:g})=>{const[S,b]=t.useState(null),[w,p]=t.useState(new Set),[h,E]=t.useState(""),[T,_]=t.useState(!1),[v,y]=t.useState(new Date),[I,O]=t.useState(0);t.useEffect(()=>(b(i.getCurrentCustomerSegment()),p(s()),E(a()),_(!0),()=>{}),[]),t.useEffect(()=>{if("undefined"==typeof window)return;const e=()=>{O(e=>e+1),y(new Date)};return window.addEventListener(r.RIBBON_DISMISS_UPDATED_EVENT,e),()=>{window.removeEventListener(r.RIBBON_DISMISS_UPDATED_EVENT,e)}},[]),t.useEffect(()=>{const e=i.subscribeToCustomerSegmentRefresh(()=>{b(i.getCurrentCustomerSegment()),p(s()),E(a()),y(new Date)});return()=>{e()}},[]);const D=n||(null==d?void 0:d.ribbonConfig),N=f||process.env.NEXT_PUBLIC_CHANNEL||"";if(t.useEffect(()=>{var e;if(!(null===(e=null==D?void 0:D.ribbons)||void 0===e?void 0:e.length))return;const t=v.getTime(),n=m(l(),t),r=D.ribbons.flatMap(e=>{const n=[],r=c(e.scheduleStartTime),i=c(e.scheduleEndTime);if(r){const e=r.getTime();e>t&&n.push(e)}if(i){const e=i.getTime();e>t&&n.push(e)}return n}).concat(Object.values(n).filter(e=>e>t)).sort((e,t)=>e-t)[0];if(!r)return;const i=r-t,o=window.setTimeout(()=>{y(new Date)},Math.max(i,0));return()=>{window.clearTimeout(o)}},[null==D?void 0:D.ribbons,v,I]),!T)return null;if(!(null==D?void 0:D.ribbons)||!Array.isArray(D.ribbons)||0===D.ribbons.length)return null;const C=m(l(),v.getTime()),j=D.ribbons.filter(e=>{if(!e.component)return!1;if(e._uid&&C[e._uid]&&C[e._uid]>v.getTime())return!1;if(!((e,t)=>{const n=c(e.scheduleStartTime),r=c(e.scheduleEndTime),i=!n||t.getTime()>=n.getTime(),o=!r||r.getTime()>t.getTime();return i&&o})(e,v))return!1;if(!((e,t)=>{console.log("userAgent",t);const n=u(e).map(e=>String(e).trim()).filter(Boolean);if(!n.length)return!0;if(!t)return!1;const r=t.toLowerCase();return n.some(e=>e.split("|").map(e=>e.trim().toLowerCase()).filter(Boolean).some(e=>r.includes(e)))})(e.customerDeviceSegment,h))return!1;if((null==e?void 0:e.microsites)&&!((e,t)=>{if(!Array.isArray(e.microsites)||0===e.microsites.length)return!1;const n=o(t);return e.microsites.some(e=>"string"==typeof e&&o(e)===n)})(e,N))return!1;if("globalPromoRibbon"!==e.component)return!0;return u(e.tealiumAudiences).length>0?((e,t)=>{const n=u(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!t.size&&n.some(e=>t.has(e))})(e.tealiumAudiences,w):((e,t)=>{const n=u(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!n.includes("all")||!!t&&n.includes(t.toLowerCase())})(e.customerType,S)}),A=j.find(e=>"heroLogin"===e.component),B=j.find(e=>"heroLogin"!==e.component),L=[];return B&&L.push(B),A&&L.push(A),0===L.length?null:e.jsx("div",{className:"ribbons-wrapper",children:L.map((t,n)=>e.jsx("div",{className:"ribbon-item",children:g(Object.assign(Object.assign({},t),{_uid:t._uid||`ribbon-${n}`,component:t.component}),n)},t._uid||n))})};
|
|
2
2
|
//# sourceMappingURL=RibbonRenderer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RibbonRenderer.js","sources":["../../../../../src/components/RibbonRenderer/RibbonRenderer.tsx"],"sourcesContent":[null],"names":["normalizeMicrositeValue","value","trim","toLowerCase","getTealiumAudienceKeys","window","Set","rawValue","localStorage","getItem","parsed","JSON","parse","audiences","Object","keys","filter","Boolean","map","audience","String","_a","normalizeStringArray","Array","isArray","getScheduleDateTime","calculateDateTime","Date","replace","getDismissedRibbonsMap","DISMISSED_RIBBONS_STORAGE_KEY","entries","reduce","acc","uid","expiresAt","Number","isFinite","pruneExpiredDismissedRibbons","dismissedRibbonsMap","nowMs","activeEntries","cleanedMap","fromEntries","length","removeItem","setItem","stringify","ribbonConfig","metadata","channel","renderRibbon","userCustomerGroup","setUserCustomerGroup","useState","tealiumAudiences","setTealiumAudiences","isHydrated","setIsHydrated","currentTime","setCurrentTime","dismissedRibbonVersion","setDismissedRibbonVersion","useEffect","getCurrentCustomerSegment","onDismissedRibbonUpdated","previousVersion","addEventListener","RIBBON_DISMISS_UPDATED_EVENT","removeEventListener","unsubscribe","subscribeToCustomerSegmentRefresh","resolvedRibbonConfig","currentChannel","process","env","NEXT_PUBLIC_CHANNEL","ribbons","presentTimeMs","getTime","nextRecalculationTimeMs","flatMap","ribbon","times","startTime","scheduleStartTime","endTime","scheduleEndTime","startTimeMs","push","endTimeMs","concat","values","timeMs","sort","a","b","delay","timer","setTimeout","Math","max","clearTimeout","eligibleRibbons","component","_uid","hasStarted","notExpired","isRibbonWithinScheduleWindow","
|
|
1
|
+
{"version":3,"file":"RibbonRenderer.js","sources":["../../../../../src/components/RibbonRenderer/RibbonRenderer.tsx"],"sourcesContent":[null],"names":["normalizeMicrositeValue","value","trim","toLowerCase","getTealiumAudienceKeys","window","Set","rawValue","localStorage","getItem","parsed","JSON","parse","audiences","Object","keys","filter","Boolean","map","audience","String","_a","normalizeStringArray","Array","isArray","getUserAgent","navigator","userAgent","getScheduleDateTime","calculateDateTime","Date","replace","getDismissedRibbonsMap","DISMISSED_RIBBONS_STORAGE_KEY","entries","reduce","acc","uid","expiresAt","Number","isFinite","pruneExpiredDismissedRibbons","dismissedRibbonsMap","nowMs","activeEntries","cleanedMap","fromEntries","length","removeItem","setItem","stringify","ribbonConfig","metadata","channel","renderRibbon","userCustomerGroup","setUserCustomerGroup","useState","tealiumAudiences","setTealiumAudiences","setUserAgent","isHydrated","setIsHydrated","currentTime","setCurrentTime","dismissedRibbonVersion","setDismissedRibbonVersion","useEffect","getCurrentCustomerSegment","onDismissedRibbonUpdated","previousVersion","addEventListener","RIBBON_DISMISS_UPDATED_EVENT","removeEventListener","unsubscribe","subscribeToCustomerSegmentRefresh","resolvedRibbonConfig","currentChannel","process","env","NEXT_PUBLIC_CHANNEL","ribbons","presentTimeMs","getTime","nextRecalculationTimeMs","flatMap","ribbon","times","startTime","scheduleStartTime","endTime","scheduleEndTime","startTimeMs","push","endTimeMs","concat","values","timeMs","sort","a","b","delay","timer","setTimeout","Math","max","clearTimeout","eligibleRibbons","component","_uid","hasStarted","notExpired","isRibbonWithinScheduleWindow","ribbonCustomerDeviceSegment","console","log","configuredSegments","segment","normalizedUserAgent","some","split","token","includes","matchesCustomerDeviceSegment","customerDeviceSegment","microsites","normalizedChannel","microsite","isRibbonAllowedForChannel","ribbonAudiences","availableAudiences","normalizedRibbonAudiences","size","has","matchesTealiumAudiences","ribbonCustomerGroup","customerGroups","group","matchesCustomerGroup","customerType","heroLoginRibbon","find","nonHeroLoginRibbon","ribbonsToRender","_jsx","className","children","index","assign"],"mappings":"mPA6CA,MAAMA,EAA2BC,GAA0BA,EAAMC,OAAOC,cAelEC,EAAyB,KAC7B,GAAsB,oBAAXC,OACT,OAAO,IAAIC,IAGb,MAAMC,EAAWF,OAAOG,aAAaC,QAAQ,cAC7C,IAAKF,EACH,OAAO,IAAID,IAGb,IACE,MAAMI,EAASC,KAAKC,MAAML,GACpBM,EAAYH,aAAM,EAANA,EAAQG,UAE1B,OAAKA,GAAkC,iBAAdA,EAIlB,IAAIP,IACTQ,OAAOC,KAAKF,GACTG,OAAOC,SACPC,IAAKC,GAAaC,OAAOD,GAAUjB,OAAOC,gBANtC,IAAIG,GAQf,CAAE,MAAAe,GACA,OAAO,IAAIf,GACb,GAGIgB,EAAwBrB,GACvBA,EACEsB,MAAMC,QAAQvB,GAASA,EAAQ,CAACA,GADpB,GAIfwB,EAAe,IACM,oBAAdC,UACF,GAGFA,UAAUC,WAAa,GA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