@sunrise-upc/sales-static-components 3.8.6-beta.4 → 3.8.6-beta.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.
- package/dist/cjs/components/Constants.js +1 -1
- package/dist/cjs/components/Constants.js.map +1 -1
- package/dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.css +4 -0
- package/dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js +1 -1
- package/dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js.map +1 -1
- package/dist/cjs/components/RibbonRenderer/RibbonRenderer.js +1 -1
- package/dist/cjs/components/RibbonRenderer/RibbonRenderer.js.map +1 -1
- package/dist/esm/components/Constants.js +1 -1
- package/dist/esm/components/Constants.js.map +1 -1
- package/dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.css +4 -0
- package/dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.js +1 -1
- package/dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.js.map +1 -1
- package/dist/esm/components/RibbonRenderer/RibbonRenderer.js +1 -1
- package/dist/esm/components/RibbonRenderer/RibbonRenderer.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/navigation.css +256 -256
- package/package.json +20 -4
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";exports.AFTER="after",exports.AUTHCOOKIE="sunriseAuth",exports.AUTHSTAMP="auth-stamp",exports.BEFORE="before",exports.CENTER="center",exports.COLLG3="col-lg-3",exports.COLLG4="col-lg-4",exports.COLLG6="col-lg-6",exports.COLORWHITE="#ffffff",exports.CUSTOMER_GROUP_STORAGE_KEY="customerGroup",exports.DEFAULTLOCALE="en",exports.EXTRA="extra",exports.FALCONBUTTONCLICKED="clicked",exports.H1="h1",exports.H2="h2",exports.H3="h3",exports.H4="h4",exports.ICON="icon",exports.IMG="img",exports.LEFT="left",exports.LGDESKSTART=1440,exports.MDDESKEND=1439,exports.MDDESKSTART=1024,exports.MOBEND=767,exports.NONE="none",exports.PRE_TO_POST_PROMOTION_ID="PreToPost",exports.PRIMARYCOLORS="#da291c",exports.RIGHT="right",exports.SEMIEXTRA="semiextra",exports.STACK="stack",exports.SVG="svg",exports.TABEND=1023,exports.TABSTART=768,exports.TRANSPARENT="transparent",exports.ZEROES="00";
|
|
1
|
+
"use strict";exports.AFTER="after",exports.AUTHCOOKIE="sunriseAuth",exports.AUTHSTAMP="auth-stamp",exports.BEFORE="before",exports.CENTER="center",exports.COLLG3="col-lg-3",exports.COLLG4="col-lg-4",exports.COLLG6="col-lg-6",exports.COLORWHITE="#ffffff",exports.CUSTOMER_GROUP_STORAGE_KEY="customerGroup",exports.DEFAULTLOCALE="en",exports.DISMISSED_RIBBONS_STORAGE_KEY="dismissedRibbonsByUid",exports.EXTRA="extra",exports.FALCONBUTTONCLICKED="clicked",exports.H1="h1",exports.H2="h2",exports.H3="h3",exports.H4="h4",exports.ICON="icon",exports.IMG="img",exports.LEFT="left",exports.LGDESKSTART=1440,exports.MDDESKEND=1439,exports.MDDESKSTART=1024,exports.MOBEND=767,exports.NONE="none",exports.PRE_TO_POST_PROMOTION_ID="PreToPost",exports.PRIMARYCOLORS="#da291c",exports.RIBBON_DISMISS_UPDATED_EVENT="ribbonDismissUpdated",exports.RIGHT="right",exports.SEMIEXTRA="semiextra",exports.STACK="stack",exports.SVG="svg",exports.TABEND=1023,exports.TABSTART=768,exports.TRANSPARENT="transparent",exports.ZEROES="00";
|
|
2
2
|
//# sourceMappingURL=Constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Constants.js","sources":["../../../../src/components/Constants.ts"],"sourcesContent":[null],"names":[],"mappings":"2BAOqB,2BA8BK,gCA4GD,4BAzIH,wBARA,wBAyBA,0BADA,0BADA,8BAbI,6CAqJgB,sCA3Hb,
|
|
1
|
+
{"version":3,"file":"Constants.js","sources":["../../../../src/components/Constants.ts"],"sourcesContent":[null],"names":[],"mappings":"2BAOqB,2BA8BK,gCA4GD,4BAzIH,wBARA,wBAyBA,0BADA,0BADA,8BAbI,6CAqJgB,sCA3Hb,2CA4HgB,sCAjJxB,oCATc,qBAKjB,gBACA,gBACA,gBACA,kBAwEE,mBADD,mBApFC,2BAoDO,uBAlCF,yBAiCE,oBA/BL,iBAJH,wCA2IqB,kCAvJX,+CA4Je,qCA/JvB,0BAcI,0BAMJ,oBAiEF,qBAnEG,sBA+BE,wBAhDG,6BACL"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
require('./GlobalPromoRibbon.css');
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),o=require("react"),
|
|
2
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),o=require("react"),n=require("../RibbonComponent/RibbonComponentTimer/RibbonComponentTimer.js"),i=require("../RibbonComponent/utils.js"),l=require("../../utils/AnalyticUtils.js"),t=require("../../utils/AnalyticsConstants.js"),r=require("../FalconButtonV3/FalconButtonV3.js"),a=require("../Constants.js");const s=e=>e?(Array.isArray(e)?e:[e]).filter(Boolean).map(e=>String(e).trim().toLowerCase()):[],u=e=>e?i.calculateDateTime(new Date(e.trim().replace(/-/g,"/"))):null,d=e=>{if(!(null==e?void 0:e.endTime))return!1;return i.calculateDateTime(new Date(e.endTime.replace(/-/g,"/"))).getTime()<=Date.now()};exports.default=({content:i})=>{var c,m,v,b,g,S,f,T,p;const[_,w]=o.useState(!1),[h,I]=o.useState(!1),[j,N]=o.useState(!1),[y,R]=o.useState(new Date),x=o.useRef(null),[E,O]=o.useState(!1),[B,C]=o.useState(!1),[P,k]=o.useState(null==i?void 0:i.teaserTimer[0]),[D,L]=o.useState(d(null===(c=null==i?void 0:i.teaserTimer)||void 0===c?void 0:c[0])),A=(null==i?void 0:i.slimVersion)?" globalPromoRibbon_Slim":"";o.useEffect(()=>{w(!0);const e=window.localStorage.getItem(a.CUSTOMER_GROUP_STORAGE_KEY),o=(()=>{var e;if("undefined"==typeof window)return new Set;const o=window.localStorage.getItem("tealium_va");if(!o)return new Set;try{const n=null===(e=JSON.parse(o))||void 0===e?void 0:e.audiences;return n&&"object"==typeof n?new Set(Object.keys(n).map(e=>e.trim().toLowerCase())):new Set}catch(e){return new Set}})(),n=s(null==i?void 0:i.tealiumAudiences).length>0;N(n?((e,o)=>{const n=s(e);return!n.length||n.some(e=>o.has(e))})(null==i?void 0:i.tealiumAudiences,o):((e,o)=>{const n=s(e);return!(n.length&&!n.includes("all"))||Boolean(o&&n.includes(o.trim().toLowerCase()))})(null==i?void 0:i.customerType,e)),I(!0)},[]);const M=()=>{if(!1===E){if("undefined"!=typeof window&&(null==i?void 0:i._uid)&&Number(null==i?void 0:i.expireTime)>0){const e=Date.now()+60*Number(i.expireTime)*1e3,o=(()=>{if("undefined"==typeof window)return{};const e=window.localStorage.getItem(a.DISMISSED_RIBBONS_STORAGE_KEY);if(!e)return{};try{const o=JSON.parse(e);return o&&"object"==typeof o?Object.entries(o).reduce((e,[o,n])=>("string"==typeof o&&Number.isFinite(n)&&(e[o]=Number(n)),e),{}):{}}catch(e){return{}}})();o[i._uid]=e,window.localStorage.setItem(a.DISMISSED_RIBBONS_STORAGE_KEY,JSON.stringify(o)),window.dispatchEvent(new Event(a.RIBBON_DISMISS_UPDATED_EVENT))}O(!0)}};o.useEffect(()=>{var e;if(null===(e=null==i?void 0:i.teaserTimer[0])||void 0===e?void 0:e.startTime){const e=null==i?void 0:i.teaserTimer[0];k(e),L(d(e))}else L(!1);C(!0)},[null==i?void 0:i.teaserTimer]),o.useEffect(()=>{const e=u(null==i?void 0:i.scheduleStartTime),o=u(null==i?void 0:i.scheduleEndTime),n=y.getTime(),l=[e,o].filter(e=>Boolean(e)).map(e=>e.getTime()).filter(e=>e>n).sort((e,o)=>e-o)[0];if(!l)return;const t=l-n,r=window.setTimeout(()=>{R(new Date)},Math.max(t,0));return()=>{window.clearTimeout(r)}},[null==i?void 0:i.scheduleStartTime,null==i?void 0:i.scheduleEndTime,y]),o.useEffect(()=>{var e;const o=new IntersectionObserver(e=>{var o,n;e[0].isIntersecting&&e[0].intersectionRatio>=.5&&!(null===(o=localStorage.getItem("analyticsUids"))||void 0===o?void 0:o.includes(i._uid))&&(l.trackNewDatalayerEvent(t.VIEWPROMOTION,t.VIEWPROMOTION,{banner_promotion_name:null!==(n=null==i?void 0:i.bannerPromotionName)&&void 0!==n?n:null==i?void 0:i.title,banner_source:t.CMS,banner_type:t.RIBBON,banner_location:null==i?void 0:i.bannerLocation,audience_name:t.ALL,promotion_objective:t.ALL}),localStorage.setItem("analyticsUids",JSON.stringify([...localStorage.getItem("analyticsUids")?JSON.parse(localStorage.getItem("analyticsUids")||""):[],i._uid])))},{threshold:.5});return x.current&&!(null===(e=localStorage.getItem("analyticsUids"))||void 0===e?void 0:e.includes(i._uid))&&o.observe(x.current),()=>{o.disconnect()}});const U=u(null==i?void 0:i.scheduleStartTime),V=u(null==i?void 0:i.scheduleEndTime),q=!U||y.getTime()>=U.getTime(),G=!V||V.getTime()>y.getTime(),F=!1===E&&B&&h&&j&&(q&&G),J=(null==i?void 0:i.gradientBackgroundGlobal)&&"none"!==(null==i?void 0:i.gradientBackgroundGlobal)?i.gradientBackgroundGlobal.replace(/;\s*$/,""):null==i?void 0:i.backgroundColor;return e.jsx("div",{className:"body-banner",suppressHydrationWarning:!0,children:_&&F&&e.jsx(e.Fragment,{children:e.jsx("div",{className:`globalPromoRibbon_Wrapper${A}`,style:{background:J},ref:x,children:e.jsxs("div",{className:"globalPromoRibbon_Card",children:[e.jsxs("div",{className:"globalPromoRibbon_descriptionBlockSection",children:[(null===(m=null==i?void 0:i.icon)||void 0===m?void 0:m.filename)&&e.jsx("div",{className:"globalPromoRibbon_Image",children:e.jsx("img",{className:"globalPromoRibbon_Icon",src:null===(v=null==i?void 0:i.icon)||void 0===v?void 0:v.filename})}),(null==i?void 0:i.title)&&e.jsxs("div",{className:"globalPromoRibbon_TextContainer",children:[e.jsx("span",{style:{color:null==i?void 0:i.titleColor},children:null==i?void 0:i.title}),e.jsx("div",{})]})]}),e.jsxs("div",{className:"globalPromoRibbon_ButtonSection",children:[(null===(b=null==i?void 0:i.teaserTimer[0])||void 0===b?void 0:b.startTime)&&!D&&e.jsx("div",{className:"globalPromoRibbon_Timer",children:e.jsx(n.default,{content:P,setTimerExpired:L,isSlimVersion:Boolean(null==i?void 0:i.slimVersion)})}),(null===(g=null==i?void 0:i.buttons)||void 0===g?void 0:g.length)?e.jsx("div",{className:"globalPromoRibbon_Buttons",children:i.buttons.map((o,n)=>{var l,t,a,s,u,d,c,m;return e.jsx(r.default,{wrapperClassName:"globalPromoRibbon_Button",href:o.href||(null===(l=o.buttonLink)||void 0===l?void 0:l.url)||(null===(t=o.buttonLink)||void 0===t?void 0:t.cached_url)||"",label:o.buttonLabel||o.label||"",buttonType:o.buttonType,isSlim:Boolean(null==i?void 0:i.slimVersion),target:null!==(s=null!==(a=o.target)&&void 0!==a?a:o.linkTarget)&&void 0!==s?s:"",rel:null!==(u=o.rel)&&void 0!==u?u:"_blank"===o.linkTarget?"opener":"noopener",iconFilename:o.iconFilename||(null===(d=o.buttonIcon)||void 0===d?void 0:d.filename),iconPosition:o.iconPosition},`${o.href||(null===(c=o.buttonLink)||void 0===c?void 0:c.url)||(null===(m=o.buttonLink)||void 0===m?void 0:m.cached_url)||n}`)})}):null,(null===(S=null==i?void 0:i.closeIcon)||void 0===S?void 0:S.filename)&&(null==i?void 0:i.showCloseIcon)&&e.jsx("div",{className:"globalPromoRibbon_CloseIcon",onClick:()=>M(),children:e.jsx("img",{src:null===(f=null==i?void 0:i.closeIcon)||void 0===f?void 0:f.filename})})]}),(null===(T=null==i?void 0:i.closeIcon)||void 0===T?void 0:T.filename)&&(null==i?void 0:i.showCloseIcon)&&e.jsx("div",{className:"globalPromoRibbon_CloseIcon1",onClick:()=>M(),children:e.jsx("img",{src:null===(p=null==i?void 0:i.closeIcon)||void 0===p?void 0:p.filename})})]})})})})};
|
|
3
3
|
//# sourceMappingURL=GlobalPromoRibbon.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GlobalPromoRibbon.js","sources":["../../../../../src/components/GlobalPromoRibbon/GlobalPromoRibbon.tsx"],"sourcesContent":[null],"names":["normalizeStringArray","value","Array","isArray","filter","Boolean","map","item","String","trim","toLowerCase","getScheduleDateTime","calculateDateTime","Date","replace","isTeaserTimerExpired","timer","endTime","getTime","now","content","isHydrated","setIsHydrated","useState","isTargetingResolved","setIsTargetingResolved","isTargetingAllowed","setIsTargetingAllowed","currentTime","setCurrentTime","elementRef","useRef","closeBanner","setCloseBanner","displayMaintainance","seDisplayMaintainance","teaserContent","setTeaserContent","teaserTimer","isTimerExpired","setIsTimerExpired","_a","slimWrapperClass","slimVersion","useEffect","customerGroup","window","localStorage","getItem","CUSTOMER_GROUP_STORAGE_KEY","tealiumAudiences","Set","rawValue","audiences","JSON","parse","Object","keys","audience","_b","getTealiumAudienceKeys","hasConfiguredTealiumAudiences","length","configuredAudiences","availableAudiences","normalizedAudiences","some","has","matchesTealiumAudiences","customerType","configuredTypes","includes","matchesCustomerType","onClickClose","startTime","tempContent","scheduleStart","scheduleStartTime","scheduleEnd","scheduleEndTime","presentTimeMs","nextRecalculationTimeMs","time","timeMs","sort","a","b","delay","setTimeout","Math","max","clearTimeout","observer","IntersectionObserver","
|
|
1
|
+
{"version":3,"file":"GlobalPromoRibbon.js","sources":["../../../../../src/components/GlobalPromoRibbon/GlobalPromoRibbon.tsx"],"sourcesContent":[null],"names":["normalizeStringArray","value","Array","isArray","filter","Boolean","map","item","String","trim","toLowerCase","getScheduleDateTime","calculateDateTime","Date","replace","isTeaserTimerExpired","timer","endTime","getTime","now","content","isHydrated","setIsHydrated","useState","isTargetingResolved","setIsTargetingResolved","isTargetingAllowed","setIsTargetingAllowed","currentTime","setCurrentTime","elementRef","useRef","closeBanner","setCloseBanner","displayMaintainance","seDisplayMaintainance","teaserContent","setTeaserContent","teaserTimer","isTimerExpired","setIsTimerExpired","_a","slimWrapperClass","slimVersion","useEffect","customerGroup","window","localStorage","getItem","CUSTOMER_GROUP_STORAGE_KEY","tealiumAudiences","Set","rawValue","audiences","JSON","parse","Object","keys","audience","_b","getTealiumAudienceKeys","hasConfiguredTealiumAudiences","length","configuredAudiences","availableAudiences","normalizedAudiences","some","has","matchesTealiumAudiences","customerType","configuredTypes","includes","matchesCustomerType","onClickClose","_uid","Number","expireTime","expiresAt","dismissedRibbonsMap","DISMISSED_RIBBONS_STORAGE_KEY","parsed","entries","reduce","acc","uid","isFinite","getDismissedRibbonsMap","setItem","stringify","dispatchEvent","Event","RIBBON_DISMISS_UPDATED_EVENT","startTime","tempContent","scheduleStart","scheduleStartTime","scheduleEnd","scheduleEndTime","presentTimeMs","nextRecalculationTimeMs","time","timeMs","sort","a","b","delay","setTimeout","Math","max","clearTimeout","observer","IntersectionObserver","isIntersecting","intersectionRatio","trackNewDatalayerEvent","VIEWPROMOTION","banner_promotion_name","bannerPromotionName","title","banner_source","CMS","banner_type","RIBBON","banner_location","bannerLocation","audience_name","ALL","promotion_objective","threshold","current","observe","disconnect","hasStarted","notExpired","shouldRenderRibbon","backgroundStyle","gradientBackgroundGlobal","backgroundColor","_jsx","className","suppressHydrationWarning","children","_Fragment","style","background","ref","_jsxs","icon","filename","src","_c","color","titleColor","_d","RibbonComponentTimer","setTimerExpired","isSlimVersion","_e","buttons","button","index","FalconButtonV3","wrapperClassName","href","buttonLink","url","cached_url","label","buttonLabel","buttonType","isSlim","target","linkTarget","rel","iconFilename","buttonIcon","_f","iconPosition","_g","_h","closeIcon","showCloseIcon","onClick","_j"],"mappings":"uZAkBA,MA2BMA,EAAwBC,GACvBA,GAIGC,MAAMC,QAAQF,GAASA,EAAQ,CAACA,IACrCG,OAAOC,SACPC,IAAKC,GAASC,OAAOD,GAAME,OAAOC,eAL5B,GAwDLC,EAAuBV,GACtBA,EAIEW,EAAAA,kBAAkB,IAAIC,KAAKZ,EAAMQ,OAAOK,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,WAAtBE,EAAOa,WAA0B,SAAW,WAChEE,aAAcf,EAAOe,eAAiC,UAAjBf,EAAOgB,kBAAU,IAAAC,OAAA,EAAAA,EAAE5B,UACxD6B,aAAclB,EAAOkB,cAThB,GAAGlB,EAAOI,OAAyB,UAAjBJ,EAAOK,kBAAU,IAAAc,OAAA,EAAAA,EAAEb,OAAwB,QAAjBc,EAAApB,EAAOK,kBAAU,IAAAe,OAAA,EAAAA,EAAEb,aAAcN,SAatF,MACe,QAAlBgB,EAAA5J,aAAO,EAAPA,EAASgK,iBAAS,IAAAJ,OAAA,EAAAA,EAAE5B,YAAYhI,aAAO,EAAPA,EAASiK,gBACxC3C,EAAAA,IAAA,MAAA,CAAKC,UAAW,8BAA+B2C,QAAS,IAAM7G,IAAcoE,SAC1EH,MAAA,MAAA,CACEW,IAAuB,QAAlB6B,EAAA9J,aAAO,EAAPA,EAASgK,iBAAS,IAAAF,OAAA,EAAAA,EAAE9B,iBAKd,QAAlB+B,EAAA/J,aAAO,EAAPA,EAASgK,iBAAS,IAAAD,OAAA,EAAAA,EAAE/B,YAAYhI,aAAO,EAAPA,EAASiK,gBACxC3C,EAAAA,IAAA,MAAA,CAAKC,UAAW,+BAAgC2C,QAAS,IAAM7G,IAAcoE,SAC3EH,EAAAA,IAAA,MAAA,CACEW,IAAuB,QAAlBkC,EAAAnK,aAAO,EAAPA,EAASgK,iBAAS,IAAAG,OAAA,EAAAA,EAAEnC"}
|
|
@@ -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");const
|
|
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");const i=e=>e.trim().toLowerCase(),o=e=>e?Array.isArray(e)?e:[e]:[],s=e=>e?n.calculateDateTime(new Date(e.trim().replace(/-/g,"/"))):null,u=()=>{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{}}},a=(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:c,channel:l,renderRibbon:d})=>{const[m,f]=t.useState(null),[S,b]=t.useState(new Set),[w,g]=t.useState(!1),[p,_]=t.useState(new Date),[E,h]=t.useState(0);t.useEffect(()=>{if("undefined"==typeof window)return;const e=window.localStorage.getItem(r.CUSTOMER_GROUP_STORAGE_KEY);f(e),b((()=>{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}})()),g(!0)},[]),t.useEffect(()=>{if("undefined"==typeof window)return;const e=()=>{h(e=>e+1),_(new Date)};return window.addEventListener(r.RIBBON_DISMISS_UPDATED_EVENT,e),()=>{window.removeEventListener(r.RIBBON_DISMISS_UPDATED_EVENT,e)}},[]);const T=n||(null==c?void 0:c.ribbonConfig),O=l||process.env.NEXT_PUBLIC_CHANNEL||"";if(t.useEffect(()=>{var e;if(!(null===(e=null==T?void 0:T.ribbons)||void 0===e?void 0:e.length))return;const t=p.getTime(),n=a(u(),t),r=T.ribbons.flatMap(e=>{const n=[],r=s(e.scheduleStartTime),i=s(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(()=>{_(new Date)},Math.max(i,0));return()=>{window.clearTimeout(o)}},[null==T?void 0:T.ribbons,p,E]),!w)return null;if(!(null==T?void 0:T.ribbons)||!Array.isArray(T.ribbons)||0===T.ribbons.length)return null;const y=a(u(),p.getTime()),I=T.ribbons.filter(e=>{if(!e.component)return!1;if(e._uid&&y[e._uid]&&y[e._uid]>p.getTime())return!1;if(!((e,t)=>{const n=s(e.scheduleStartTime),r=s(e.scheduleEndTime),i=!n||t.getTime()>=n.getTime(),o=!r||r.getTime()>t.getTime();return i&&o})(e,p))return!1;if((null==e?void 0:e.microsites)&&!((e,t)=>{if(!Array.isArray(e.microsites)||0===e.microsites.length)return!1;const n=i(t);return e.microsites.some(e=>"string"==typeof e&&i(e)===n)})(e,O))return!1;if("globalPromoRibbon"!==e.component)return!0;return o(e.tealiumAudiences).length>0?((e,t)=>{const n=o(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!t.size&&n.some(e=>t.has(e))})(e.tealiumAudiences,S):((e,t)=>{const n=o(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!n.includes("all")||!!t&&n.includes(t.toLowerCase())})(e.customerType,m)}),v=I.find(e=>"heroLogin"===e.component),N=I.find(e=>"heroLogin"!==e.component),D=[];return N&&D.push(N),v&&D.push(v),0===D.length?null:e.jsx("div",{className:"ribbons-wrapper",children:D.map((t,n)=>e.jsx("div",{className:"ribbon-item",children:d(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","normalizeStringArray","Array","isArray","getScheduleDateTime","calculateDateTime","Date","replace","
|
|
1
|
+
{"version":3,"file":"RibbonRenderer.js","sources":["../../../../../src/components/RibbonRenderer/RibbonRenderer.tsx"],"sourcesContent":[null],"names":["normalizeMicrositeValue","value","trim","toLowerCase","normalizeStringArray","Array","isArray","getScheduleDateTime","calculateDateTime","Date","replace","getDismissedRibbonsMap","window","rawValue","localStorage","getItem","DISMISSED_RIBBONS_STORAGE_KEY","parsed","JSON","parse","Object","entries","reduce","acc","uid","expiresAt","Number","isFinite","_a","pruneExpiredDismissedRibbons","dismissedRibbonsMap","nowMs","activeEntries","filter","cleanedMap","fromEntries","length","removeItem","keys","setItem","stringify","ribbonConfig","metadata","channel","renderRibbon","userCustomerGroup","setUserCustomerGroup","useState","tealiumAudiences","setTealiumAudiences","Set","isHydrated","setIsHydrated","currentTime","setCurrentTime","dismissedRibbonVersion","setDismissedRibbonVersion","useEffect","customerGroup","CUSTOMER_GROUP_STORAGE_KEY","audiences","Boolean","map","audience","String","getTealiumAudienceKeys","onDismissedRibbonUpdated","previousVersion","addEventListener","RIBBON_DISMISS_UPDATED_EVENT","removeEventListener","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","microsites","normalizedChannel","some","microsite","isRibbonAllowedForChannel","ribbonAudiences","availableAudiences","normalizedRibbonAudiences","size","has","matchesTealiumAudiences","ribbonCustomerGroup","customerGroups","group","includes","matchesCustomerGroup","customerType","heroLoginRibbon","find","nonHeroLoginRibbon","ribbonsToRender","_jsx","className","children","index","assign"],"mappings":"gMAyCA,MAAMA,EAA2BC,GAA0BA,EAAMC,OAAOC,cA2ClE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
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e="center",
|
|
1
|
+
const e="center",s="left",t="right",o="transparent",r="00",i="#da291c",c="clicked",n="after",a="before",f="#ffffff",l="h1",d="h2",h="h3",g="h4",m="extra",b="semiextra",p="none",u=1439,x=1023,k=767,P="stack",U="col-lg-6",v="col-lg-4",y="col-lg-3",A="en",B="sunriseAuth",D=768,G=1024,R=1440,T="img",j="icon",q="svg",w="auth-stamp",z="PreToPost",C="customerGroup",E="dismissedRibbonsByUid",F="ribbonDismissUpdated";export{n as AFTER,B as AUTHCOOKIE,w as AUTHSTAMP,a as BEFORE,e as CENTER,y as COLLG3,v as COLLG4,U as COLLG6,f as COLORWHITE,C as CUSTOMER_GROUP_STORAGE_KEY,A as DEFAULTLOCALE,E as DISMISSED_RIBBONS_STORAGE_KEY,m as EXTRA,c as FALCONBUTTONCLICKED,l as H1,d as H2,h as H3,g as H4,j as ICON,T as IMG,s as LEFT,R as LGDESKSTART,u as MDDESKEND,G as MDDESKSTART,k as MOBEND,p as NONE,z as PRE_TO_POST_PROMOTION_ID,i as PRIMARYCOLORS,F as RIBBON_DISMISS_UPDATED_EVENT,t as RIGHT,b as SEMIEXTRA,P as STACK,q as SVG,x as TABEND,D as TABSTART,o as TRANSPARENT,r as ZEROES};
|
|
2
2
|
//# sourceMappingURL=Constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Constants.js","sources":["../../../../src/components/Constants.ts"],"sourcesContent":[null],"names":["CENTER","LEFT","RIGHT","TRANSPARENT","ZEROES","PRIMARYCOLORS","FALCONBUTTONCLICKED","AFTER","BEFORE","COLORWHITE","H1","H2","H3","H4","EXTRA","SEMIEXTRA","NONE","MDDESKEND","TABEND","MOBEND","STACK","COLLG6","COLLG4","COLLG3","DEFAULTLOCALE","AUTHCOOKIE","TABSTART","MDDESKSTART","LGDESKSTART","IMG","ICON","SVG","AUTHSTAMP","PRE_TO_POST_PROMOTION_ID","CUSTOMER_GROUP_STORAGE_KEY"],"mappings":"AAAO,MAAMA,EAAS,SACTC,EAAO,OACPC,EAAQ,QACRC,EAAc,cACdC,EAAS,KACTC,EAAgB,UAChBC,EAAsB,UACtBC,EAAQ,QACRC,EAAS,SAETC,EAAa,UACbC,EAAK,KACLC,EAAK,KACLC,EAAK,KACLC,EAAK,KACLC,EAAQ,QACRC,EAAY,YACZC,EAAM,OAENC,EAAY,KACZC,EAAS,KACTC,EAAS,IACTC,EAAQ,QACRC,EAAS,WACTC,EAAS,WACTC,EAAS,WAWTC,EAAgB,KAChBC,EAAa,cAcbC,EAAW,IACXC,EAAc,KACdC,EAAc,KAgCdC,EAAM,MACNC,EAAO,OACPC,EAAM,MA0DNC,EAAY,aAWZC,EAA2B,YAG3BC,EAA6B"}
|
|
1
|
+
{"version":3,"file":"Constants.js","sources":["../../../../src/components/Constants.ts"],"sourcesContent":[null],"names":["CENTER","LEFT","RIGHT","TRANSPARENT","ZEROES","PRIMARYCOLORS","FALCONBUTTONCLICKED","AFTER","BEFORE","COLORWHITE","H1","H2","H3","H4","EXTRA","SEMIEXTRA","NONE","MDDESKEND","TABEND","MOBEND","STACK","COLLG6","COLLG4","COLLG3","DEFAULTLOCALE","AUTHCOOKIE","TABSTART","MDDESKSTART","LGDESKSTART","IMG","ICON","SVG","AUTHSTAMP","PRE_TO_POST_PROMOTION_ID","CUSTOMER_GROUP_STORAGE_KEY","DISMISSED_RIBBONS_STORAGE_KEY","RIBBON_DISMISS_UPDATED_EVENT"],"mappings":"AAAO,MAAMA,EAAS,SACTC,EAAO,OACPC,EAAQ,QACRC,EAAc,cACdC,EAAS,KACTC,EAAgB,UAChBC,EAAsB,UACtBC,EAAQ,QACRC,EAAS,SAETC,EAAa,UACbC,EAAK,KACLC,EAAK,KACLC,EAAK,KACLC,EAAK,KACLC,EAAQ,QACRC,EAAY,YACZC,EAAM,OAENC,EAAY,KACZC,EAAS,KACTC,EAAS,IACTC,EAAQ,QACRC,EAAS,WACTC,EAAS,WACTC,EAAS,WAWTC,EAAgB,KAChBC,EAAa,cAcbC,EAAW,IACXC,EAAc,KACdC,EAAc,KAgCdC,EAAM,MACNC,EAAO,OACPC,EAAM,MA0DNC,EAAY,aAWZC,EAA2B,YAG3BC,EAA6B,gBAC7BC,EAAgC,wBAChCC,EAA+B"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import './GlobalPromoRibbon.css';
|
|
2
|
-
import{jsx as
|
|
2
|
+
import{jsx as e,Fragment as o,jsxs as n}from"react/jsx-runtime";import{useState as i,useRef as l,useEffect as t}from"react";import r from"../RibbonComponent/RibbonComponentTimer/RibbonComponentTimer.js";import{calculateDateTime as a}from"../RibbonComponent/utils.js";import{trackNewDatalayerEvent as d}from"../../utils/AnalyticUtils.js";import{VIEWPROMOTION as s,ALL as u,RIBBON as c,CMS as m}from"../../utils/AnalyticsConstants.js";import v from"../FalconButtonV3/FalconButtonV3.js";import{CUSTOMER_GROUP_STORAGE_KEY as b,DISMISSED_RIBBONS_STORAGE_KEY as g,RIBBON_DISMISS_UPDATED_EVENT as p}from"../Constants.js";const f=e=>e?(Array.isArray(e)?e:[e]).filter(Boolean).map(e=>String(e).trim().toLowerCase()):[],w=e=>e?a(new Date(e.trim().replace(/-/g,"/"))):null,h=e=>{if(!(null==e?void 0:e.endTime))return!1;return a(new Date(e.endTime.replace(/-/g,"/"))).getTime()<=Date.now()},T=({content:a})=>{var T,_,y,S,N,I,C,R,k;const[P,B]=i(!1),[j,L]=i(!1),[O,x]=i(!1),[A,D]=i(new Date),E=l(null),[U,V]=i(!1),[F,J]=i(!1),[G,$]=i(null==a?void 0:a.teaserTimer[0]),[W,H]=i(h(null===(T=null==a?void 0:a.teaserTimer)||void 0===T?void 0:T[0])),M=(null==a?void 0:a.slimVersion)?" globalPromoRibbon_Slim":"";t(()=>{B(!0);const e=window.localStorage.getItem(b),o=(()=>{var e;if("undefined"==typeof window)return new Set;const o=window.localStorage.getItem("tealium_va");if(!o)return new Set;try{const n=null===(e=JSON.parse(o))||void 0===e?void 0:e.audiences;return n&&"object"==typeof n?new Set(Object.keys(n).map(e=>e.trim().toLowerCase())):new Set}catch(e){return new Set}})(),n=f(null==a?void 0:a.tealiumAudiences).length>0;x(n?((e,o)=>{const n=f(e);return!n.length||n.some(e=>o.has(e))})(null==a?void 0:a.tealiumAudiences,o):((e,o)=>{const n=f(e);return!(n.length&&!n.includes("all"))||Boolean(o&&n.includes(o.trim().toLowerCase()))})(null==a?void 0:a.customerType,e)),L(!0)},[]);const q=()=>{if(!1===U){if("undefined"!=typeof window&&(null==a?void 0:a._uid)&&Number(null==a?void 0:a.expireTime)>0){const e=Date.now()+60*Number(a.expireTime)*1e3,o=(()=>{if("undefined"==typeof window)return{};const e=window.localStorage.getItem(g);if(!e)return{};try{const o=JSON.parse(e);return o&&"object"==typeof o?Object.entries(o).reduce((e,[o,n])=>("string"==typeof o&&Number.isFinite(n)&&(e[o]=Number(n)),e),{}):{}}catch(e){return{}}})();o[a._uid]=e,window.localStorage.setItem(g,JSON.stringify(o)),window.dispatchEvent(new Event(p))}V(!0)}};t(()=>{var e;if(null===(e=null==a?void 0:a.teaserTimer[0])||void 0===e?void 0:e.startTime){const e=null==a?void 0:a.teaserTimer[0];$(e),H(h(e))}else H(!1);J(!0)},[null==a?void 0:a.teaserTimer]),t(()=>{const e=w(null==a?void 0:a.scheduleStartTime),o=w(null==a?void 0:a.scheduleEndTime),n=A.getTime(),i=[e,o].filter(e=>Boolean(e)).map(e=>e.getTime()).filter(e=>e>n).sort((e,o)=>e-o)[0];if(!i)return;const l=i-n,t=window.setTimeout(()=>{D(new Date)},Math.max(l,0));return()=>{window.clearTimeout(t)}},[null==a?void 0:a.scheduleStartTime,null==a?void 0:a.scheduleEndTime,A]),t(()=>{var e;const o=new IntersectionObserver(e=>{var o,n;e[0].isIntersecting&&e[0].intersectionRatio>=.5&&!(null===(o=localStorage.getItem("analyticsUids"))||void 0===o?void 0:o.includes(a._uid))&&(d(s,s,{banner_promotion_name:null!==(n=null==a?void 0:a.bannerPromotionName)&&void 0!==n?n:null==a?void 0:a.title,banner_source:m,banner_type:c,banner_location:null==a?void 0:a.bannerLocation,audience_name:u,promotion_objective:u}),localStorage.setItem("analyticsUids",JSON.stringify([...localStorage.getItem("analyticsUids")?JSON.parse(localStorage.getItem("analyticsUids")||""):[],a._uid])))},{threshold:.5});return E.current&&!(null===(e=localStorage.getItem("analyticsUids"))||void 0===e?void 0:e.includes(a._uid))&&o.observe(E.current),()=>{o.disconnect()}});const z=w(null==a?void 0:a.scheduleStartTime),K=w(null==a?void 0:a.scheduleEndTime),Q=!z||A.getTime()>=z.getTime(),X=!K||K.getTime()>A.getTime(),Y=!1===U&&F&&j&&O&&(Q&&X),Z=(null==a?void 0:a.gradientBackgroundGlobal)&&"none"!==(null==a?void 0:a.gradientBackgroundGlobal)?a.gradientBackgroundGlobal.replace(/;\s*$/,""):null==a?void 0:a.backgroundColor;return e("div",{className:"body-banner",suppressHydrationWarning:!0,children:P&&Y&&e(o,{children:e("div",{className:`globalPromoRibbon_Wrapper${M}`,style:{background:Z},ref:E,children:n("div",{className:"globalPromoRibbon_Card",children:[n("div",{className:"globalPromoRibbon_descriptionBlockSection",children:[(null===(_=null==a?void 0:a.icon)||void 0===_?void 0:_.filename)&&e("div",{className:"globalPromoRibbon_Image",children:e("img",{className:"globalPromoRibbon_Icon",src:null===(y=null==a?void 0:a.icon)||void 0===y?void 0:y.filename})}),(null==a?void 0:a.title)&&n("div",{className:"globalPromoRibbon_TextContainer",children:[e("span",{style:{color:null==a?void 0:a.titleColor},children:null==a?void 0:a.title}),e("div",{})]})]}),n("div",{className:"globalPromoRibbon_ButtonSection",children:[(null===(S=null==a?void 0:a.teaserTimer[0])||void 0===S?void 0:S.startTime)&&!W&&e("div",{className:"globalPromoRibbon_Timer",children:e(r,{content:G,setTimerExpired:H,isSlimVersion:Boolean(null==a?void 0:a.slimVersion)})}),(null===(N=null==a?void 0:a.buttons)||void 0===N?void 0:N.length)?e("div",{className:"globalPromoRibbon_Buttons",children:a.buttons.map((o,n)=>{var i,l,t,r,d,s,u,c;return e(v,{wrapperClassName:"globalPromoRibbon_Button",href:o.href||(null===(i=o.buttonLink)||void 0===i?void 0:i.url)||(null===(l=o.buttonLink)||void 0===l?void 0:l.cached_url)||"",label:o.buttonLabel||o.label||"",buttonType:o.buttonType,isSlim:Boolean(null==a?void 0:a.slimVersion),target:null!==(r=null!==(t=o.target)&&void 0!==t?t:o.linkTarget)&&void 0!==r?r:"",rel:null!==(d=o.rel)&&void 0!==d?d:"_blank"===o.linkTarget?"opener":"noopener",iconFilename:o.iconFilename||(null===(s=o.buttonIcon)||void 0===s?void 0:s.filename),iconPosition:o.iconPosition},`${o.href||(null===(u=o.buttonLink)||void 0===u?void 0:u.url)||(null===(c=o.buttonLink)||void 0===c?void 0:c.cached_url)||n}`)})}):null,(null===(I=null==a?void 0:a.closeIcon)||void 0===I?void 0:I.filename)&&(null==a?void 0:a.showCloseIcon)&&e("div",{className:"globalPromoRibbon_CloseIcon",onClick:()=>q(),children:e("img",{src:null===(C=null==a?void 0:a.closeIcon)||void 0===C?void 0:C.filename})})]}),(null===(R=null==a?void 0:a.closeIcon)||void 0===R?void 0:R.filename)&&(null==a?void 0:a.showCloseIcon)&&e("div",{className:"globalPromoRibbon_CloseIcon1",onClick:()=>q(),children:e("img",{src:null===(k=null==a?void 0:a.closeIcon)||void 0===k?void 0:k.filename})})]})})})})};export{T as default};
|
|
3
3
|
//# sourceMappingURL=GlobalPromoRibbon.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GlobalPromoRibbon.js","sources":["../../../../../src/components/GlobalPromoRibbon/GlobalPromoRibbon.tsx"],"sourcesContent":[null],"names":["normalizeStringArray","value","Array","isArray","filter","Boolean","map","item","String","trim","toLowerCase","getScheduleDateTime","calculateDateTime","Date","replace","isTeaserTimerExpired","timer","endTime","getTime","now","GlobalPromoRibbon","content","isHydrated","setIsHydrated","useState","isTargetingResolved","setIsTargetingResolved","isTargetingAllowed","setIsTargetingAllowed","currentTime","setCurrentTime","elementRef","useRef","closeBanner","setCloseBanner","displayMaintainance","seDisplayMaintainance","teaserContent","setTeaserContent","teaserTimer","isTimerExpired","setIsTimerExpired","_a","slimWrapperClass","slimVersion","useEffect","customerGroup","window","localStorage","getItem","CUSTOMER_GROUP_STORAGE_KEY","tealiumAudiences","Set","rawValue","audiences","JSON","parse","Object","keys","audience","_b","getTealiumAudienceKeys","hasConfiguredTealiumAudiences","length","configuredAudiences","availableAudiences","normalizedAudiences","some","has","matchesTealiumAudiences","customerType","configuredTypes","includes","matchesCustomerType","onClickClose","startTime","tempContent","scheduleStart","scheduleStartTime","scheduleEnd","scheduleEndTime","presentTimeMs","nextRecalculationTimeMs","time","timeMs","sort","a","b","delay","setTimeout","Math","max","clearTimeout","observer","IntersectionObserver","
|
|
1
|
+
{"version":3,"file":"GlobalPromoRibbon.js","sources":["../../../../../src/components/GlobalPromoRibbon/GlobalPromoRibbon.tsx"],"sourcesContent":[null],"names":["normalizeStringArray","value","Array","isArray","filter","Boolean","map","item","String","trim","toLowerCase","getScheduleDateTime","calculateDateTime","Date","replace","isTeaserTimerExpired","timer","endTime","getTime","now","GlobalPromoRibbon","content","isHydrated","setIsHydrated","useState","isTargetingResolved","setIsTargetingResolved","isTargetingAllowed","setIsTargetingAllowed","currentTime","setCurrentTime","elementRef","useRef","closeBanner","setCloseBanner","displayMaintainance","seDisplayMaintainance","teaserContent","setTeaserContent","teaserTimer","isTimerExpired","setIsTimerExpired","_a","slimWrapperClass","slimVersion","useEffect","customerGroup","window","localStorage","getItem","CUSTOMER_GROUP_STORAGE_KEY","tealiumAudiences","Set","rawValue","audiences","JSON","parse","Object","keys","audience","_b","getTealiumAudienceKeys","hasConfiguredTealiumAudiences","length","configuredAudiences","availableAudiences","normalizedAudiences","some","has","matchesTealiumAudiences","customerType","configuredTypes","includes","matchesCustomerType","onClickClose","_uid","Number","expireTime","expiresAt","dismissedRibbonsMap","DISMISSED_RIBBONS_STORAGE_KEY","parsed","entries","reduce","acc","uid","isFinite","getDismissedRibbonsMap","setItem","stringify","dispatchEvent","Event","RIBBON_DISMISS_UPDATED_EVENT","startTime","tempContent","scheduleStart","scheduleStartTime","scheduleEnd","scheduleEndTime","presentTimeMs","nextRecalculationTimeMs","time","timeMs","sort","a","b","delay","setTimeout","Math","max","clearTimeout","observer","IntersectionObserver","isIntersecting","intersectionRatio","trackNewDatalayerEvent","VIEWPROMOTION","banner_promotion_name","bannerPromotionName","title","banner_source","CMS","banner_type","RIBBON","banner_location","bannerLocation","audience_name","ALL","promotion_objective","threshold","current","observe","disconnect","hasStarted","notExpired","shouldRenderRibbon","backgroundStyle","gradientBackgroundGlobal","backgroundColor","_jsx","className","suppressHydrationWarning","children","_Fragment","style","background","ref","_jsxs","icon","filename","src","_c","color","titleColor","_d","RibbonComponentTimer","setTimerExpired","isSlimVersion","_e","buttons","button","index","FalconButtonV3","wrapperClassName","href","buttonLink","url","cached_url","label","buttonLabel","buttonType","isSlim","target","linkTarget","rel","iconFilename","buttonIcon","_f","iconPosition","_g","_h","closeIcon","showCloseIcon","onClick","_j"],"mappings":"smBAkBA,MA2BMA,EAAwBC,GACvBA,GAIGC,MAAMC,QAAQF,GAASA,EAAQ,CAACA,IACrCG,OAAOC,SACPC,IAAKC,GAASC,OAAOD,GAAME,OAAOC,eAL5B,GAwDLC,EAAuBV,GACtBA,EAIEW,EAAkB,IAAIC,KAAKZ,EAAMQ,OAAOK,QAAQ,KAAM,OAHpD,KAMLC,EAAwBC,IAC5B,KAAKA,aAAK,EAALA,EAAOC,SACV,OAAO,EAIT,OADgBL,EAAkB,IAAIC,KAAKG,EAAMC,QAAQH,QAAQ,KAAM,OACxDI,WAAaL,KAAKM,OAa7BC,EAAoB,EAAGC,oCAC3B,MAAOC,EAAYC,GAAiBC,GAAS,IACtCC,EAAqBC,GAA0BF,GAAS,IACxDG,EAAoBC,GAAyBJ,GAAS,IACtDK,EAAaC,GAAkBN,EAAe,IAAIX,MAC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A/J,aAAO,EAAPA,EAASgK,iBAAS,IAAAD,OAAA,EAAAA,EAAE/B,YAAYhI,aAAO,EAAPA,EAASiK,gBACxC3C,EAAA,MAAA,CAAKC,UAAW,+BAAgC2C,QAAS,IAAM7G,IAAcoE,SAC3EH,EAAA,MAAA,CACEW,IAAuB,QAAlBkC,EAAAnK,aAAO,EAAPA,EAASgK,iBAAS,IAAAG,OAAA,EAAAA,EAAEnC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e}from"react/jsx-runtime";import{useState as
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{useState as t,useEffect as n}from"react";import{calculateDateTime as r}from"../RibbonComponent/utils.js";import{CUSTOMER_GROUP_STORAGE_KEY as i,RIBBON_DISMISS_UPDATED_EVENT as o,DISMISSED_RIBBONS_STORAGE_KEY as s}from"../Constants.js";const u=e=>e.trim().toLowerCase(),l=e=>e?Array.isArray(e)?e:[e]:[],c=e=>e?r(new Date(e.trim().replace(/-/g,"/"))):null,a=()=>{if("undefined"==typeof window)return{};const e=window.localStorage.getItem(s);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),r=Object.fromEntries(n);return"undefined"!=typeof window&&(0===n.length?window.localStorage.removeItem(s):n.length!==Object.keys(e).length&&window.localStorage.setItem(s,JSON.stringify(r))),r},d=({ribbonConfig:r,metadata:s,channel:d,renderRibbon:f})=>{const[b,w]=t(null),[g,p]=t(new Set),[h,y]=t(!1),[S,v]=t(new Date),[T,j]=t(0);n(()=>{if("undefined"==typeof window)return;const e=window.localStorage.getItem(i);w(e),p((()=>{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}})()),y(!0)},[]),n(()=>{if("undefined"==typeof window)return;const e=()=>{j(e=>e+1),v(new Date)};return window.addEventListener(o,e),()=>{window.removeEventListener(o,e)}},[]);const N=r||(null==s?void 0:s.ribbonConfig),C=d||process.env.NEXT_PUBLIC_CHANNEL||"";if(n(()=>{var e;if(!(null===(e=null==N?void 0:N.ribbons)||void 0===e?void 0:e.length))return;const t=S.getTime(),n=m(a(),t),r=N.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(()=>{v(new Date)},Math.max(i,0));return()=>{window.clearTimeout(o)}},[null==N?void 0:N.ribbons,S,T]),!h)return null;if(!(null==N?void 0:N.ribbons)||!Array.isArray(N.ribbons)||0===N.ribbons.length)return null;const L=m(a(),S.getTime()),O=N.ribbons.filter(e=>{if(!e.component)return!1;if(e._uid&&L[e._uid]&&L[e._uid]>S.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,S))return!1;if((null==e?void 0:e.microsites)&&!((e,t)=>{if(!Array.isArray(e.microsites)||0===e.microsites.length)return!1;const n=u(t);return e.microsites.some(e=>"string"==typeof e&&u(e)===n)})(e,C))return!1;if("globalPromoRibbon"!==e.component)return!0;return l(e.tealiumAudiences).length>0?((e,t)=>{const n=l(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!t.size&&n.some(e=>t.has(e))})(e.tealiumAudiences,g):((e,t)=>{const n=l(e).map(e=>String(e).trim().toLowerCase());return!n.length||!!n.includes("all")||!!t&&n.includes(t.toLowerCase())})(e.customerType,b)}),A=O.find(e=>"heroLogin"===e.component),_=O.find(e=>"heroLogin"!==e.component),E=[];return _&&E.push(_),A&&E.push(A),0===E.length?null:e("div",{className:"ribbons-wrapper",children:E.map((t,n)=>e("div",{className:"ribbon-item",children:f(Object.assign(Object.assign({},t),{_uid:t._uid||`ribbon-${n}`,component:t.component}),n)},t._uid||n))})};export{d as default};
|
|
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","normalizeStringArray","Array","isArray","getScheduleDateTime","calculateDateTime","Date","replace","
|
|
1
|
+
{"version":3,"file":"RibbonRenderer.js","sources":["../../../../../src/components/RibbonRenderer/RibbonRenderer.tsx"],"sourcesContent":[null],"names":["normalizeMicrositeValue","value","trim","toLowerCase","normalizeStringArray","Array","isArray","getScheduleDateTime","calculateDateTime","Date","replace","getDismissedRibbonsMap","window","rawValue","localStorage","getItem","DISMISSED_RIBBONS_STORAGE_KEY","parsed","JSON","parse","Object","entries","reduce","acc","uid","expiresAt","Number","isFinite","_a","pruneExpiredDismissedRibbons","dismissedRibbonsMap","nowMs","activeEntries","filter","cleanedMap","fromEntries","length","removeItem","keys","setItem","stringify","RibbonRenderer","ribbonConfig","metadata","channel","renderRibbon","userCustomerGroup","setUserCustomerGroup","useState","tealiumAudiences","setTealiumAudiences","Set","isHydrated","setIsHydrated","currentTime","setCurrentTime","dismissedRibbonVersion","setDismissedRibbonVersion","useEffect","customerGroup","CUSTOMER_GROUP_STORAGE_KEY","audiences","Boolean","map","audience","String","getTealiumAudienceKeys","onDismissedRibbonUpdated","previousVersion","addEventListener","RIBBON_DISMISS_UPDATED_EVENT","removeEventListener","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","microsites","normalizedChannel","some","microsite","isRibbonAllowedForChannel","ribbonAudiences","availableAudiences","normalizedRibbonAudiences","size","has","matchesTealiumAudiences","ribbonCustomerGroup","customerGroups","group","includes","matchesCustomerGroup","customerType","heroLoginRibbon","find","nonHeroLoginRibbon","ribbonsToRender","_jsx","className","children","index","assign"],"mappings":"0RAyCA,MAAMA,EAA2BC,GAA0BA,EAAMC,OAAOC,cA2ClEC,EAAwBH,GACvBA,EACEI,MAAMC,QAAQL,GAASA,EAAQ,CAACA,GADpB,GA8CfM,EAAuBN,GACtBA,EAIEO,EAAkB,IAAIC,KAAKR,EAAMC,OAAOQ,QAAQ,KAAM,OAHpD,KAgBLC,EAAyB,KAC7B,GAAsB,oBAAXC,OACT,MAAO,CAAA,EAGT,MAAMC,EAAWD,OAAOE,aAAaC,QAAQC,GAC7C,IAAKH,EACH,MAAO,CAAA,EAGT,IACE,MAAMI,EAASC,KAAKC,MAAMN,GAC1B,OAAKI,GAA4B,iBAAXA,EAIfG,OAAOC,QAAQJ,GAAQK,OAA4B,CAACC,GAAMC,EAAKC,MACjD,iBAARD,GAAoBE,OAAOC,SAASF,KAC7CF,EAAIC,GAAOE,OAAOD,IAEbF,GACN,CAAA,GARM,CAAA,CASX,CAAE,MAAAK,GACA,MAAO,CAAA,CACT,GAGIC,EAA+B,CACnCC,EACAC,KAEA,MAAMC,EAAgBZ,OAAOC,QAAQS,GAAqBG,OAAO,EAAC,CAAGR,KACnEC,OAAOC,SAASF,IAAcC,OAAOD,GAAaM,GAG9CG,EAAad,OAAOe,YAAYH,GAUtC,MARsB,oBAAXpB,SACoB,IAAzBoB,EAAcI,OAChBxB,OAAOE,aAAauB,WAAWrB,GACtBgB,EAAcI,SAAWh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G,EAAgB7F,OACX,KAIP8F,EAAA,MAAA,CAAKC,UAAU,kBAAiBC,SAC7BH,EAAgBlE,IAAI,CAACmB,EAAqBmD,IACzCH,EAAA,MAAA,CAA+CC,UAAU,cAAaC,SACnEvF,EACCzB,OAAAkH,OAAAlH,OAAAkH,OAAA,CAAA,EACKpD,GAAM,CACTuB,KAAOvB,EAAa,MAAgB,UAAUmD,IAC9C7B,UAAWtB,EAAOsB,YAEpB6B,IAPOnD,EAAa,MAAgBmD"}
|
package/dist/index.d.ts
CHANGED
|
@@ -84,6 +84,7 @@ interface RibbonBlock {
|
|
|
84
84
|
tealiumAudiences?: string | string[];
|
|
85
85
|
scheduleStartTime?: string | null;
|
|
86
86
|
scheduleEndTime?: string | null;
|
|
87
|
+
expireTime?: number | null;
|
|
87
88
|
[key: string]: unknown;
|
|
88
89
|
}
|
|
89
90
|
interface ResolvedRibbonBlock extends RibbonBlock {
|
|
@@ -122,6 +123,7 @@ interface GlobalPromoRibbonSchema {
|
|
|
122
123
|
gradientBackgroundGlobal?: string;
|
|
123
124
|
customerType?: string | string[];
|
|
124
125
|
tealiumAudiences?: string | string[];
|
|
126
|
+
expireTime?: number | null;
|
|
125
127
|
}
|
|
126
128
|
interface GlobalPromoRibbonButtonSchema {
|
|
127
129
|
href?: string;
|
package/dist/navigation.css
CHANGED
|
@@ -1,172 +1,3 @@
|
|
|
1
|
-
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/ResponsiveRow/row.module.scss */
|
|
2
|
-
/* center a block element */
|
|
3
|
-
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
4
|
-
/* setting styles in separate formats for cross browser support */
|
|
5
|
-
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
6
|
-
/* vertically center alilgn any HTML element */
|
|
7
|
-
/* add basePath to assets */
|
|
8
|
-
.row-module__sr-def-row___us1ph {
|
|
9
|
-
margin-left: auto;
|
|
10
|
-
margin-right: auto;
|
|
11
|
-
padding-left: 16px;
|
|
12
|
-
padding-right: 16px;
|
|
13
|
-
max-width: 1308px;
|
|
14
|
-
width: 100%;
|
|
15
|
-
}
|
|
16
|
-
.row-module__sr-def-row___us1ph .row-module__sr-def-row___us1ph {
|
|
17
|
-
padding: 0px;
|
|
18
|
-
max-width: 100%;
|
|
19
|
-
}
|
|
20
|
-
@media (min-width: 1024px) and (max-width: 1439px) {
|
|
21
|
-
.row-module__sr-def-row___us1ph {
|
|
22
|
-
max-width: 972px;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
@media (min-width: 768px) and (max-width: 1023px) {
|
|
26
|
-
.row-module__sr-def-row___us1ph {
|
|
27
|
-
max-width: 720px;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
@media (max-width: 767px) {
|
|
31
|
-
.row-module__sr-def-row___us1ph {
|
|
32
|
-
max-width: 100%;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/MinimizedHeader/MinimizedHeader.module.scss */
|
|
37
|
-
/* center a block element */
|
|
38
|
-
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
39
|
-
/* setting styles in separate formats for cross browser support */
|
|
40
|
-
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
41
|
-
/* vertically center alilgn any HTML element */
|
|
42
|
-
/* add basePath to assets */
|
|
43
|
-
@media (min-width: 768px) {
|
|
44
|
-
.MinimizedHeader-module__outer___JOzJC {
|
|
45
|
-
background-color: #ffffff;
|
|
46
|
-
border-top: 4px solid #da291c;
|
|
47
|
-
box-shadow: 0px 2px 4px rgba(87, 84, 82, 0.2);
|
|
48
|
-
height: 72px;
|
|
49
|
-
}
|
|
50
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
51
|
-
position: fixed;
|
|
52
|
-
top: 0;
|
|
53
|
-
left: 0;
|
|
54
|
-
padding: 4px 8px;
|
|
55
|
-
font-size: 14px;
|
|
56
|
-
z-index: 10000;
|
|
57
|
-
color: #5f5955;
|
|
58
|
-
background: #ffffff;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
@media (min-width: 768px) and (max-width: 850px) {
|
|
62
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
63
|
-
padding: 0 4px;
|
|
64
|
-
font-size: 8px;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
@media (min-width: 768px) {
|
|
68
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X {
|
|
69
|
-
width: 100%;
|
|
70
|
-
display: inline-block;
|
|
71
|
-
}
|
|
72
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO {
|
|
73
|
-
display: flex;
|
|
74
|
-
float: left;
|
|
75
|
-
align-items: center;
|
|
76
|
-
margin: 10px 0;
|
|
77
|
-
}
|
|
78
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 {
|
|
79
|
-
padding-left: 10px;
|
|
80
|
-
}
|
|
81
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- {
|
|
82
|
-
float: right;
|
|
83
|
-
display: flex;
|
|
84
|
-
margin: 24px 0 24px 0;
|
|
85
|
-
}
|
|
86
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-icon___LlK8O {
|
|
87
|
-
background-image: url("/ecom-int/HeaderIcons/new_profile_icon1.svg");
|
|
88
|
-
background-repeat: no-repeat;
|
|
89
|
-
background-size: contain;
|
|
90
|
-
display: block;
|
|
91
|
-
height: 24px;
|
|
92
|
-
margin-right: 6px;
|
|
93
|
-
width: 24px;
|
|
94
|
-
}
|
|
95
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-name___Kh-fd {
|
|
96
|
-
color: #da291c;
|
|
97
|
-
font-weight: 700;
|
|
98
|
-
font-size: 18px;
|
|
99
|
-
line-height: 24px;
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
@media (max-width: 767px) {
|
|
103
|
-
.MinimizedHeader-module__outer___JOzJC {
|
|
104
|
-
background-color: #ffffff;
|
|
105
|
-
border-top: 4px solid #da291c;
|
|
106
|
-
box-shadow: 0px 2px 4px rgba(87, 84, 82, 0.2);
|
|
107
|
-
height: 48px;
|
|
108
|
-
}
|
|
109
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X {
|
|
110
|
-
width: 100%;
|
|
111
|
-
display: inline-block;
|
|
112
|
-
}
|
|
113
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO {
|
|
114
|
-
display: flex;
|
|
115
|
-
float: left;
|
|
116
|
-
}
|
|
117
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__icon___wYr8J {
|
|
118
|
-
margin-top: 12px;
|
|
119
|
-
}
|
|
120
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__icon___wYr8J > img {
|
|
121
|
-
height: 24px;
|
|
122
|
-
width: 24px;
|
|
123
|
-
float: left;
|
|
124
|
-
}
|
|
125
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 {
|
|
126
|
-
margin-top: 8px;
|
|
127
|
-
padding-left: 6px;
|
|
128
|
-
}
|
|
129
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 > img {
|
|
130
|
-
height: 20px;
|
|
131
|
-
}
|
|
132
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- {
|
|
133
|
-
float: right;
|
|
134
|
-
display: flex;
|
|
135
|
-
margin: 12px 0 12px 0;
|
|
136
|
-
}
|
|
137
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-icon___LlK8O {
|
|
138
|
-
background-image: url("/ecom-int/HeaderIcons/new_profile_icon1.svg");
|
|
139
|
-
background-repeat: no-repeat;
|
|
140
|
-
background-size: contain;
|
|
141
|
-
display: block;
|
|
142
|
-
height: 20px;
|
|
143
|
-
margin-right: 6px;
|
|
144
|
-
width: 20px;
|
|
145
|
-
}
|
|
146
|
-
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-name___Kh-fd {
|
|
147
|
-
color: #da291c;
|
|
148
|
-
font-weight: 700;
|
|
149
|
-
font-size: 18px;
|
|
150
|
-
line-height: 24px;
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
.MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
154
|
-
position: fixed;
|
|
155
|
-
top: 0;
|
|
156
|
-
left: 0;
|
|
157
|
-
padding: 4px 8px;
|
|
158
|
-
font-size: 14px;
|
|
159
|
-
z-index: 10000;
|
|
160
|
-
color: #5f5955;
|
|
161
|
-
background: #ffffff;
|
|
162
|
-
}
|
|
163
|
-
@media (max-width: 850px) {
|
|
164
|
-
.MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
165
|
-
padding: 0 4px;
|
|
166
|
-
font-size: 8px;
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
1
|
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/FalconMainNavigation.module.scss */
|
|
171
2
|
/* center a block element */
|
|
172
3
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
@@ -461,6 +292,41 @@
|
|
|
461
292
|
}
|
|
462
293
|
}
|
|
463
294
|
|
|
295
|
+
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/ResponsiveRow/row.module.scss */
|
|
296
|
+
/* center a block element */
|
|
297
|
+
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
298
|
+
/* setting styles in separate formats for cross browser support */
|
|
299
|
+
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
300
|
+
/* vertically center alilgn any HTML element */
|
|
301
|
+
/* add basePath to assets */
|
|
302
|
+
.row-module__sr-def-row___us1ph {
|
|
303
|
+
margin-left: auto;
|
|
304
|
+
margin-right: auto;
|
|
305
|
+
padding-left: 16px;
|
|
306
|
+
padding-right: 16px;
|
|
307
|
+
max-width: 1308px;
|
|
308
|
+
width: 100%;
|
|
309
|
+
}
|
|
310
|
+
.row-module__sr-def-row___us1ph .row-module__sr-def-row___us1ph {
|
|
311
|
+
padding: 0px;
|
|
312
|
+
max-width: 100%;
|
|
313
|
+
}
|
|
314
|
+
@media (min-width: 1024px) and (max-width: 1439px) {
|
|
315
|
+
.row-module__sr-def-row___us1ph {
|
|
316
|
+
max-width: 972px;
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
@media (min-width: 768px) and (max-width: 1023px) {
|
|
320
|
+
.row-module__sr-def-row___us1ph {
|
|
321
|
+
max-width: 720px;
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
@media (max-width: 767px) {
|
|
325
|
+
.row-module__sr-def-row___us1ph {
|
|
326
|
+
max-width: 100%;
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
|
|
464
330
|
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/InteractiveHamburger/InteractiveHamburger.module.scss */
|
|
465
331
|
/* center a block element */
|
|
466
332
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
@@ -753,6 +619,140 @@
|
|
|
753
619
|
visibility: visible;
|
|
754
620
|
}
|
|
755
621
|
|
|
622
|
+
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/MinimizedHeader/MinimizedHeader.module.scss */
|
|
623
|
+
/* center a block element */
|
|
624
|
+
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
625
|
+
/* setting styles in separate formats for cross browser support */
|
|
626
|
+
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
627
|
+
/* vertically center alilgn any HTML element */
|
|
628
|
+
/* add basePath to assets */
|
|
629
|
+
@media (min-width: 768px) {
|
|
630
|
+
.MinimizedHeader-module__outer___JOzJC {
|
|
631
|
+
background-color: #ffffff;
|
|
632
|
+
border-top: 4px solid #da291c;
|
|
633
|
+
box-shadow: 0px 2px 4px rgba(87, 84, 82, 0.2);
|
|
634
|
+
height: 72px;
|
|
635
|
+
}
|
|
636
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
637
|
+
position: fixed;
|
|
638
|
+
top: 0;
|
|
639
|
+
left: 0;
|
|
640
|
+
padding: 4px 8px;
|
|
641
|
+
font-size: 14px;
|
|
642
|
+
z-index: 10000;
|
|
643
|
+
color: #5f5955;
|
|
644
|
+
background: #ffffff;
|
|
645
|
+
}
|
|
646
|
+
}
|
|
647
|
+
@media (min-width: 768px) and (max-width: 850px) {
|
|
648
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
649
|
+
padding: 0 4px;
|
|
650
|
+
font-size: 8px;
|
|
651
|
+
}
|
|
652
|
+
}
|
|
653
|
+
@media (min-width: 768px) {
|
|
654
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X {
|
|
655
|
+
width: 100%;
|
|
656
|
+
display: inline-block;
|
|
657
|
+
}
|
|
658
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO {
|
|
659
|
+
display: flex;
|
|
660
|
+
float: left;
|
|
661
|
+
align-items: center;
|
|
662
|
+
margin: 10px 0;
|
|
663
|
+
}
|
|
664
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 {
|
|
665
|
+
padding-left: 10px;
|
|
666
|
+
}
|
|
667
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- {
|
|
668
|
+
float: right;
|
|
669
|
+
display: flex;
|
|
670
|
+
margin: 24px 0 24px 0;
|
|
671
|
+
}
|
|
672
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-icon___LlK8O {
|
|
673
|
+
background-image: url("/ecom-int/HeaderIcons/new_profile_icon1.svg");
|
|
674
|
+
background-repeat: no-repeat;
|
|
675
|
+
background-size: contain;
|
|
676
|
+
display: block;
|
|
677
|
+
height: 24px;
|
|
678
|
+
margin-right: 6px;
|
|
679
|
+
width: 24px;
|
|
680
|
+
}
|
|
681
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-name___Kh-fd {
|
|
682
|
+
color: #da291c;
|
|
683
|
+
font-weight: 700;
|
|
684
|
+
font-size: 18px;
|
|
685
|
+
line-height: 24px;
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
@media (max-width: 767px) {
|
|
689
|
+
.MinimizedHeader-module__outer___JOzJC {
|
|
690
|
+
background-color: #ffffff;
|
|
691
|
+
border-top: 4px solid #da291c;
|
|
692
|
+
box-shadow: 0px 2px 4px rgba(87, 84, 82, 0.2);
|
|
693
|
+
height: 48px;
|
|
694
|
+
}
|
|
695
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X {
|
|
696
|
+
width: 100%;
|
|
697
|
+
display: inline-block;
|
|
698
|
+
}
|
|
699
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO {
|
|
700
|
+
display: flex;
|
|
701
|
+
float: left;
|
|
702
|
+
}
|
|
703
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__icon___wYr8J {
|
|
704
|
+
margin-top: 12px;
|
|
705
|
+
}
|
|
706
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__icon___wYr8J > img {
|
|
707
|
+
height: 24px;
|
|
708
|
+
width: 24px;
|
|
709
|
+
float: left;
|
|
710
|
+
}
|
|
711
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 {
|
|
712
|
+
margin-top: 8px;
|
|
713
|
+
padding-left: 6px;
|
|
714
|
+
}
|
|
715
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__wrap___rUhGO .MinimizedHeader-module__title___4dK49 > img {
|
|
716
|
+
height: 20px;
|
|
717
|
+
}
|
|
718
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- {
|
|
719
|
+
float: right;
|
|
720
|
+
display: flex;
|
|
721
|
+
margin: 12px 0 12px 0;
|
|
722
|
+
}
|
|
723
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-icon___LlK8O {
|
|
724
|
+
background-image: url("/ecom-int/HeaderIcons/new_profile_icon1.svg");
|
|
725
|
+
background-repeat: no-repeat;
|
|
726
|
+
background-size: contain;
|
|
727
|
+
display: block;
|
|
728
|
+
height: 20px;
|
|
729
|
+
margin-right: 6px;
|
|
730
|
+
width: 20px;
|
|
731
|
+
}
|
|
732
|
+
.MinimizedHeader-module__outer___JOzJC .MinimizedHeader-module__align___yv11X .MinimizedHeader-module__after-login___-BGe- .MinimizedHeader-module__profile-name___Kh-fd {
|
|
733
|
+
color: #da291c;
|
|
734
|
+
font-weight: 700;
|
|
735
|
+
font-size: 18px;
|
|
736
|
+
line-height: 24px;
|
|
737
|
+
}
|
|
738
|
+
}
|
|
739
|
+
.MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
740
|
+
position: fixed;
|
|
741
|
+
top: 0;
|
|
742
|
+
left: 0;
|
|
743
|
+
padding: 4px 8px;
|
|
744
|
+
font-size: 14px;
|
|
745
|
+
z-index: 10000;
|
|
746
|
+
color: #5f5955;
|
|
747
|
+
background: #ffffff;
|
|
748
|
+
}
|
|
749
|
+
@media (max-width: 850px) {
|
|
750
|
+
.MinimizedHeader-module__s20-header__version-number___vI9Rr {
|
|
751
|
+
padding: 0 4px;
|
|
752
|
+
font-size: 8px;
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
|
|
756
756
|
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/FalconHeader/LocaleSelector/LocaleSelector.module.scss */
|
|
757
757
|
/* center a block element */
|
|
758
758
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
@@ -1201,93 +1201,6 @@
|
|
|
1201
1201
|
filter: brightness(0) invert(0.9);
|
|
1202
1202
|
}
|
|
1203
1203
|
|
|
1204
|
-
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/FalconHeader/BusinessCustomerLinkOut/BusinessCustomerLinkOut.module.scss */
|
|
1205
|
-
/* center a block element */
|
|
1206
|
-
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
1207
|
-
/* setting styles in separate formats for cross browser support */
|
|
1208
|
-
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
1209
|
-
/* vertically center alilgn any HTML element */
|
|
1210
|
-
/* add basePath to assets */
|
|
1211
|
-
.BusinessCustomerLinkOut-module__outer-icon___lsbX9 {
|
|
1212
|
-
margin-left: 0 !important;
|
|
1213
|
-
}
|
|
1214
|
-
|
|
1215
|
-
.BusinessCustomerLinkOut-module__icon___lYHUm {
|
|
1216
|
-
padding: 14px 8px 18px 8px;
|
|
1217
|
-
cursor: pointer;
|
|
1218
|
-
}
|
|
1219
|
-
.BusinessCustomerLinkOut-module__icon___lYHUm img {
|
|
1220
|
-
margin-left: 0px !important;
|
|
1221
|
-
padding-left: 8px;
|
|
1222
|
-
}
|
|
1223
|
-
|
|
1224
|
-
.BusinessCustomerLinkOut-module__icon1___VBeT5 {
|
|
1225
|
-
color: #da291c;
|
|
1226
|
-
background-color: #ffffff;
|
|
1227
|
-
padding: 14px 8px 18px 8px;
|
|
1228
|
-
border-radius: 4px 4px 0 0;
|
|
1229
|
-
}
|
|
1230
|
-
.BusinessCustomerLinkOut-module__icon1___VBeT5 img {
|
|
1231
|
-
color: #da291c;
|
|
1232
|
-
margin-left: 0px !important;
|
|
1233
|
-
padding-left: unset;
|
|
1234
|
-
padding-right: 8px;
|
|
1235
|
-
transform: rotate(-180deg);
|
|
1236
|
-
}
|
|
1237
|
-
|
|
1238
|
-
.BusinessCustomerLinkOut-module__icon2___gPMoZ a, .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm a {
|
|
1239
|
-
color: #da291c !important;
|
|
1240
|
-
}
|
|
1241
|
-
.BusinessCustomerLinkOut-module__icon2___gPMoZ, .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1242
|
-
border-radius: 4px 4px 0 0;
|
|
1243
|
-
background-color: #ffffff;
|
|
1244
|
-
padding: 14px 8px 18px 8px;
|
|
1245
|
-
}
|
|
1246
|
-
|
|
1247
|
-
.BusinessCustomerLinkOut-module__dropdown-one-item___MVk1f a {
|
|
1248
|
-
color: unset !important;
|
|
1249
|
-
}
|
|
1250
|
-
.BusinessCustomerLinkOut-module__dropdown-one-item___MVk1f {
|
|
1251
|
-
background-color: unset;
|
|
1252
|
-
}
|
|
1253
|
-
|
|
1254
|
-
.BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1255
|
-
background-color: transparent;
|
|
1256
|
-
}
|
|
1257
|
-
|
|
1258
|
-
.BusinessCustomerLinkOut-module__login-flyover___9GsNf {
|
|
1259
|
-
margin-left: 0px !important;
|
|
1260
|
-
position: absolute;
|
|
1261
|
-
min-width: 214px;
|
|
1262
|
-
display: block;
|
|
1263
|
-
padding: 36px 32px 36px 32px;
|
|
1264
|
-
font-size: 18px;
|
|
1265
|
-
line-height: 24px;
|
|
1266
|
-
border: 0;
|
|
1267
|
-
box-shadow: 0 2px 4px rgba(87, 84, 82, 0.2);
|
|
1268
|
-
background-color: #ffffff;
|
|
1269
|
-
border-radius: 0 0 8px 8px;
|
|
1270
|
-
z-index: 1;
|
|
1271
|
-
}
|
|
1272
|
-
.BusinessCustomerLinkOut-module__login-flyover___9GsNf :not(:first-child) {
|
|
1273
|
-
margin-left: 0 !important;
|
|
1274
|
-
padding-top: 18px;
|
|
1275
|
-
}
|
|
1276
|
-
.BusinessCustomerLinkOut-module__login-flyover___9GsNf :last-child {
|
|
1277
|
-
padding-top: 28px;
|
|
1278
|
-
}
|
|
1279
|
-
.BusinessCustomerLinkOut-module__login-flyover___9GsNf div:nth-child(1) {
|
|
1280
|
-
border-bottom: 1px solid #e6e3df;
|
|
1281
|
-
padding-bottom: 18px;
|
|
1282
|
-
}
|
|
1283
|
-
|
|
1284
|
-
.BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__icon2___gPMoZ, .BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1285
|
-
background-color: #111111;
|
|
1286
|
-
}
|
|
1287
|
-
.BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__highlighted___Y5Afb {
|
|
1288
|
-
background-color: #1f1f1f;
|
|
1289
|
-
}
|
|
1290
|
-
|
|
1291
1204
|
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/SubNavigation/SubNavigation.module.scss */
|
|
1292
1205
|
/* center a block element */
|
|
1293
1206
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
@@ -1398,6 +1311,93 @@
|
|
|
1398
1311
|
border: none;
|
|
1399
1312
|
}
|
|
1400
1313
|
|
|
1314
|
+
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/FalconHeader/BusinessCustomerLinkOut/BusinessCustomerLinkOut.module.scss */
|
|
1315
|
+
/* center a block element */
|
|
1316
|
+
/* use this to any of the pseudo elements as these are the mandatory properties */
|
|
1317
|
+
/* setting styles in separate formats for cross browser support */
|
|
1318
|
+
/* specify the max width for an element and apply ellipses and truncate the overflow */
|
|
1319
|
+
/* vertically center alilgn any HTML element */
|
|
1320
|
+
/* add basePath to assets */
|
|
1321
|
+
.BusinessCustomerLinkOut-module__outer-icon___lsbX9 {
|
|
1322
|
+
margin-left: 0 !important;
|
|
1323
|
+
}
|
|
1324
|
+
|
|
1325
|
+
.BusinessCustomerLinkOut-module__icon___lYHUm {
|
|
1326
|
+
padding: 14px 8px 18px 8px;
|
|
1327
|
+
cursor: pointer;
|
|
1328
|
+
}
|
|
1329
|
+
.BusinessCustomerLinkOut-module__icon___lYHUm img {
|
|
1330
|
+
margin-left: 0px !important;
|
|
1331
|
+
padding-left: 8px;
|
|
1332
|
+
}
|
|
1333
|
+
|
|
1334
|
+
.BusinessCustomerLinkOut-module__icon1___VBeT5 {
|
|
1335
|
+
color: #da291c;
|
|
1336
|
+
background-color: #ffffff;
|
|
1337
|
+
padding: 14px 8px 18px 8px;
|
|
1338
|
+
border-radius: 4px 4px 0 0;
|
|
1339
|
+
}
|
|
1340
|
+
.BusinessCustomerLinkOut-module__icon1___VBeT5 img {
|
|
1341
|
+
color: #da291c;
|
|
1342
|
+
margin-left: 0px !important;
|
|
1343
|
+
padding-left: unset;
|
|
1344
|
+
padding-right: 8px;
|
|
1345
|
+
transform: rotate(-180deg);
|
|
1346
|
+
}
|
|
1347
|
+
|
|
1348
|
+
.BusinessCustomerLinkOut-module__icon2___gPMoZ a, .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm a {
|
|
1349
|
+
color: #da291c !important;
|
|
1350
|
+
}
|
|
1351
|
+
.BusinessCustomerLinkOut-module__icon2___gPMoZ, .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1352
|
+
border-radius: 4px 4px 0 0;
|
|
1353
|
+
background-color: #ffffff;
|
|
1354
|
+
padding: 14px 8px 18px 8px;
|
|
1355
|
+
}
|
|
1356
|
+
|
|
1357
|
+
.BusinessCustomerLinkOut-module__dropdown-one-item___MVk1f a {
|
|
1358
|
+
color: unset !important;
|
|
1359
|
+
}
|
|
1360
|
+
.BusinessCustomerLinkOut-module__dropdown-one-item___MVk1f {
|
|
1361
|
+
background-color: unset;
|
|
1362
|
+
}
|
|
1363
|
+
|
|
1364
|
+
.BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1365
|
+
background-color: transparent;
|
|
1366
|
+
}
|
|
1367
|
+
|
|
1368
|
+
.BusinessCustomerLinkOut-module__login-flyover___9GsNf {
|
|
1369
|
+
margin-left: 0px !important;
|
|
1370
|
+
position: absolute;
|
|
1371
|
+
min-width: 214px;
|
|
1372
|
+
display: block;
|
|
1373
|
+
padding: 36px 32px 36px 32px;
|
|
1374
|
+
font-size: 18px;
|
|
1375
|
+
line-height: 24px;
|
|
1376
|
+
border: 0;
|
|
1377
|
+
box-shadow: 0 2px 4px rgba(87, 84, 82, 0.2);
|
|
1378
|
+
background-color: #ffffff;
|
|
1379
|
+
border-radius: 0 0 8px 8px;
|
|
1380
|
+
z-index: 1;
|
|
1381
|
+
}
|
|
1382
|
+
.BusinessCustomerLinkOut-module__login-flyover___9GsNf :not(:first-child) {
|
|
1383
|
+
margin-left: 0 !important;
|
|
1384
|
+
padding-top: 18px;
|
|
1385
|
+
}
|
|
1386
|
+
.BusinessCustomerLinkOut-module__login-flyover___9GsNf :last-child {
|
|
1387
|
+
padding-top: 28px;
|
|
1388
|
+
}
|
|
1389
|
+
.BusinessCustomerLinkOut-module__login-flyover___9GsNf div:nth-child(1) {
|
|
1390
|
+
border-bottom: 1px solid #e6e3df;
|
|
1391
|
+
padding-bottom: 18px;
|
|
1392
|
+
}
|
|
1393
|
+
|
|
1394
|
+
.BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__icon2___gPMoZ, .BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__icon2-scroll___lSNWm {
|
|
1395
|
+
background-color: #111111;
|
|
1396
|
+
}
|
|
1397
|
+
.BusinessCustomerLinkOut-module__black-friday___AwfEN .BusinessCustomerLinkOut-module__highlighted___Y5Afb {
|
|
1398
|
+
background-color: #1f1f1f;
|
|
1399
|
+
}
|
|
1400
|
+
|
|
1401
1401
|
/* /Users/filipe.cruz2/Projects/sunrise-ch-b2c-sales-static-components/src/components/FalconMainNavigation/MobileNavigation/MobileSubNavigation/MobileSubNavigation.module.scss */
|
|
1402
1402
|
/* center a block element */
|
|
1403
1403
|
/* use this to any of the pseudo elements as these are the mandatory properties */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sunrise-upc/sales-static-components",
|
|
3
|
-
"version": "3.8.6-beta.
|
|
3
|
+
"version": "3.8.6-beta.6",
|
|
4
4
|
"description": "Static Reusable Components Library",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -13,15 +13,18 @@
|
|
|
13
13
|
},
|
|
14
14
|
"./GlobalPromoRibbon": {
|
|
15
15
|
"import": "./dist/esm/components/GlobalPromoRibbon/GlobalPromoRibbon.js",
|
|
16
|
-
"require": "./dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js"
|
|
16
|
+
"require": "./dist/cjs/components/GlobalPromoRibbon/GlobalPromoRibbon.js",
|
|
17
|
+
"types": "./dist/index.d.ts"
|
|
17
18
|
},
|
|
18
19
|
"./RibbonRenderer": {
|
|
19
20
|
"import": "./dist/esm/components/RibbonRenderer/RibbonRenderer.js",
|
|
20
|
-
"require": "./dist/cjs/components/RibbonRenderer/RibbonRenderer.js"
|
|
21
|
+
"require": "./dist/cjs/components/RibbonRenderer/RibbonRenderer.js",
|
|
22
|
+
"types": "./dist/index.d.ts"
|
|
21
23
|
},
|
|
22
24
|
"./InternetAndTvCardsBenefits": {
|
|
23
25
|
"import": "./dist/esm/components/InternetAndTvCardsBenefits/InternetAndTvCardsBenefits.js",
|
|
24
|
-
"require": "./dist/cjs/components/InternetAndTvCardsBenefits/InternetAndTvCardsBenefits.js"
|
|
26
|
+
"require": "./dist/cjs/components/InternetAndTvCardsBenefits/InternetAndTvCardsBenefits.js",
|
|
27
|
+
"types": "./dist/index.d.ts"
|
|
25
28
|
},
|
|
26
29
|
"./navigation.css": "./dist/navigation.css"
|
|
27
30
|
},
|
|
@@ -34,6 +37,19 @@
|
|
|
34
37
|
"package.json"
|
|
35
38
|
],
|
|
36
39
|
"typings": "dist/index.d.ts",
|
|
40
|
+
"typesVersions": {
|
|
41
|
+
"*": {
|
|
42
|
+
"RibbonRenderer": [
|
|
43
|
+
"dist/index.d.ts"
|
|
44
|
+
],
|
|
45
|
+
"GlobalPromoRibbon": [
|
|
46
|
+
"dist/index.d.ts"
|
|
47
|
+
],
|
|
48
|
+
"InternetAndTvCardsBenefits": [
|
|
49
|
+
"dist/index.d.ts"
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
},
|
|
37
53
|
"scripts": {
|
|
38
54
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
39
55
|
"clean": "rimraf dist",
|