@everymatrix/casino-engagement-suite-jackpot-details 1.0.69

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/dist/casino-engagement-suite-jackpot-details/casino-engagement-suite-jackpot-details.esm.js +1 -0
  2. package/dist/casino-engagement-suite-jackpot-details/index.esm.js +0 -0
  3. package/dist/casino-engagement-suite-jackpot-details/p-88902287.entry.js +1 -0
  4. package/dist/casino-engagement-suite-jackpot-details/p-98211c8b.entry.js +1 -0
  5. package/dist/casino-engagement-suite-jackpot-details/p-c7ee604a.js +2 -0
  6. package/dist/casino-engagement-suite-jackpot-details/p-e1255160.js +1 -0
  7. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  8. package/dist/cjs/casino-engagement-suite-jackpot-details.cjs.entry.js +390 -0
  9. package/dist/cjs/casino-engagement-suite-jackpot-details.cjs.js +25 -0
  10. package/dist/cjs/casino-engagement-suite-progress-bar.cjs.entry.js +71 -0
  11. package/dist/cjs/index-d83151b6.js +1331 -0
  12. package/dist/cjs/index.cjs.js +2 -0
  13. package/dist/cjs/loader.cjs.js +15 -0
  14. package/dist/collection/collection-manifest.json +19 -0
  15. package/dist/collection/components/casino-engagement-suite-jackpot-details/casino-engagement-suite-jackpot-details.css +374 -0
  16. package/dist/collection/components/casino-engagement-suite-jackpot-details/casino-engagement-suite-jackpot-details.js +472 -0
  17. package/dist/collection/components/casino-engagement-suite-jackpot-details/index.js +1 -0
  18. package/dist/collection/index.js +1 -0
  19. package/dist/collection/models/index.js +1 -0
  20. package/dist/collection/utils/index.js +5 -0
  21. package/dist/collection/utils/locale.utils.js +22 -0
  22. package/dist/collection/utils/utils.js +3 -0
  23. package/dist/esm/app-globals-0f993ce5.js +3 -0
  24. package/dist/esm/casino-engagement-suite-jackpot-details.entry.js +386 -0
  25. package/dist/esm/casino-engagement-suite-jackpot-details.js +20 -0
  26. package/dist/esm/casino-engagement-suite-progress-bar.entry.js +67 -0
  27. package/dist/esm/index-0237d1e2.js +1303 -0
  28. package/dist/esm/index.js +1 -0
  29. package/dist/esm/loader.js +11 -0
  30. package/dist/index.cjs.js +1 -0
  31. package/dist/index.js +1 -0
  32. package/dist/stencil.config.dev.js +17 -0
  33. package/dist/stencil.config.js +17 -0
  34. package/dist/types/Users/raul.vasile/workspace/everymatrix/widgets-monorepo/packages/stencil/casino-engagement-suite-jackpot-details/.stencil/packages/stencil/casino-engagement-suite-jackpot-details/stencil.config.d.ts +2 -0
  35. package/dist/types/Users/raul.vasile/workspace/everymatrix/widgets-monorepo/packages/stencil/casino-engagement-suite-jackpot-details/.stencil/packages/stencil/casino-engagement-suite-jackpot-details/stencil.config.dev.d.ts +2 -0
  36. package/dist/types/components/casino-engagement-suite-jackpot-details/casino-engagement-suite-jackpot-details.d.ts +92 -0
  37. package/dist/types/components/casino-engagement-suite-jackpot-details/index.d.ts +1 -0
  38. package/dist/types/components.d.ts +113 -0
  39. package/dist/types/index.d.ts +1 -0
  40. package/dist/types/models/index.d.ts +48 -0
  41. package/dist/types/stencil-public-runtime.d.ts +1674 -0
  42. package/dist/types/utils/index.d.ts +1 -0
  43. package/dist/types/utils/locale.utils.d.ts +1 -0
  44. package/dist/types/utils/utils.d.ts +1 -0
  45. package/loader/cdn.js +1 -0
  46. package/loader/index.cjs.js +1 -0
  47. package/loader/index.d.ts +24 -0
  48. package/loader/index.es2017.js +1 -0
  49. package/loader/index.js +2 -0
  50. package/loader/package.json +11 -0
  51. package/package.json +29 -0
@@ -0,0 +1 @@
1
+ import{p as e,b as t}from"./p-c7ee604a.js";export{s as setNonce}from"./p-c7ee604a.js";import{g as i}from"./p-e1255160.js";(()=>{const t=import.meta.url,i={};return""!==t&&(i.resourcesUrl=new URL(".",t).href),e(i)})().then((async e=>(await i(),t([["p-98211c8b",[[1,"casino-engagement-suite-jackpot-details",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],jackpot:[16],jackpotChangeStatusRequest:[1040],language:[1],gameSlug:[1,"game-slug"],device:[1],limitStylingAppends:[32],timer:[32],disabledStatus:[32],activeTab:[32],visibleGames:[32],enabled:[32],balance:[32],winBalance:[32],showDetails:[32],jackpotEndTime:[32],showTooltip:[32]},[[8,"message","handleEvent"],[9,"resize","handleResize"]],{jackpot:["handleJackpotUpdate"]}]]],["p-88902287",[[1,"casino-engagement-suite-progress-bar",{value:[2],disabled:[4],hidePercent:[4,"hide-percent"],indeterminate:[4],clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],limitStylingAppends:[32]}]]]],e))));
@@ -0,0 +1 @@
1
+ import{r as e,h as r,g as s}from"./p-c7ee604a.js";const t=class{constructor(r){e(this,r),this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),r=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{r.innerHTML=e,setTimeout((()=>{this.host.prepend(r)}),1)})).catch((e=>{console.log("Error ",e)}))},this.value=0,this.disabled=!1,this.hidePercent=!1,this.indeterminate=!1,this.clientStyling="",this.clientStylingUrl="",this.limitStylingAppends=!1}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}getProgressBarClasses(){return{ProgressBar:!0,Completed:100===this.value,Disabled:this.disabled,HidePercent:this.hidePercent||this.indeterminate}}getProgressBarLineTemplate(){return r("div",this.indeterminate?{class:"ProgressBarLine Indeterminate",part:"ProgressBarLine Indeterminate"}:{class:"ProgressBarLine",part:"ProgressBarLine",style:{width:this.value+"%"}})}render(){return r("div",{key:"ecce3a26a92d2e090c1db84bdc1bdbeb505080ed",class:this.getProgressBarClasses(),part:"ProgressBar"},r("div",{key:"649fe1103d222200f2a1ad3b5967e37da1f1ab3d",class:"ProgressBarInfo",part:"ProgressBarInfo"},r("slot",{key:"49dc180eedd823f0027f75099813fb9d91bcd938",name:"Title"},r("div",{key:"e6e59da3fe7bbcb37e118e7fd23a8ff35587aca5"})),r("slot",{key:"3dc8e5fd1dbc8c268b9c76e393b751cb53605e7e",name:"Percent"},r("div",{key:"6a9e880f3ee3c4f26e8577c69be5db5f8e2d10ad",class:"ProgressBarPercent",part:"ProgressBarPercent"},this.value,"%"))),r("div",{key:"141106e77caad7b04bb199f911e87c0c6f0adc2d",class:"ProgressBarBackground",part:"ProgressBarBackground"},this.getProgressBarLineTemplate()))}get host(){return s(this)}};t.style=":host{display:block;font-family:inherit}:host(.Desktop) .ProgressBarPercent{font-size:14px;line-height:14px}.ProgressBarBackground{height:8px;background-color:var(--emw--color-background, #666178);border-radius:4px;position:relative}.ProgressBarLine{position:absolute;left:0;top:0;bottom:0;border-radius:4px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);transition:width ease-out 0.3s}.ProgressBarInfo{margin-bottom:8px;display:flex;justify-content:space-between;align-items:center}.ProgressBarPercent{font-weight:700;font-size:12px;line-height:12px}.HidePercent .ProgressBarPercent{display:none}.ProgressBar:not(.Disabled) .ProgressBarPercent{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.ProgressBar.Disabled .ProgressBarPercent{color:var(--emw--color-background, #666178)}.ProgressBar.Disabled .ProgressBarLine{background:var(--emw--color-background-secondary, #474668)}";export{t as casino_engagement_suite_progress_bar}
@@ -0,0 +1 @@
1
+ import{r as t,c as e,h as o,g as a}from"./p-c7ee604a.js";function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function s(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function n(t){s(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===i(t)&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}function p(t,e){s(2,arguments);var o=n(t),a=n(e);return o.getTime()<a.getTime()}const c=["en"],l={en:{jackpots:"Jackpots",join:"Join",unjoin:"Unjoin",info:"Info",games:"Games",operatorContribution:"Operator Contribution",type:"Type",winningProbability:"Winning Probability",tc:"Terms & Conditions",jackpotIsWon:"Jackpot’s won!",loadMore:"Load More",jackpotDetails:"Jackpot Details"}},r=(t,e)=>{const o=e;return l[void 0!==o&&c.includes(o)?o:"en"][t]};function h(t,e,o=99999999){return t=Math.min(t,o),`${e} ${new Intl.NumberFormat("en",{minimumFractionDigits:2,maximumFractionDigits:2}).format(t)}`}const k=class{constructor(o){t(this,o),this.close=e(this,"close",7),this.back=e(this,"back",7),this.maxVisibleGames=0,this.handleTabChange=t=>{this.activeTab=+t.target.getAttribute("data-index"),this.visibleGames=[],this.maxVisibleGames=0},this.handleLoadMore=()=>{this.visibleGames=this.jackpot.GamesInfo.slice(0,this.visibleGames.length+this.maxVisibleGames)},this.toggleShowDetails=()=>{this.showDetails=!this.showDetails},this.toggleTooltip=()=>{this.showTooltip=!this.showTooltip},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.host.prepend(t)},this.setClientStylingURL=()=>{let t=new URL(this.clientStylingUrl),e=document.createElement("style");fetch(t.href).then((t=>t.text())).then((t=>{e.innerHTML=t,setTimeout((()=>{this.host.prepend(e)}),1)})).catch((t=>{console.log("Error ",t)}))},this.handleCloseClick=()=>{this.close.emit()},this.handleBackClick=()=>{this.back.emit()},this.onGameClick=t=>{const e=t.currentTarget.getAttribute("data-slug");e&&window.postMessage({type:"EngagementSuiteGameRedirect",data:{Slug:e}})},this.clientStyling="",this.clientStylingUrl="",this.jackpot=void 0,this.jackpotChangeStatusRequest=void 0,this.language="en",this.gameSlug="",this.device="Mobile",this.limitStylingAppends=!1,this.timer="",this.disabledStatus="",this.activeTab=1,this.visibleGames=[],this.enabled=!1,this.balance=void 0,this.winBalance=void 0,this.showDetails=!1,this.jackpotEndTime="",this.showTooltip=!1}handleEvent(t){const{type:e,data:o}=null==t?void 0:t.data;switch(e){case"UpdateJackpotStatus":this.jackpot.JackpotId===t.data.data.JackpotId&&this.updateJackpotStatus(t.data.data);break;case"JoinJackpotResult":o.Success&&this.jackpot.JackpotId in o.JackpotIds&&(this.enabled=this.jackpot.Enabled=o.JackpotIds[this.jackpot.JackpotId])}}handleJackpotUpdate(){this.balance=this.jackpot.Balance,this.winBalance=this.jackpot.WinBalance}handleResize(){2===this.activeTab&&this.setVisibleGames(),this.showTooltip=!1}componentWillLoad(){this.enabled=this.jackpot.Enabled,this.balance=this.jackpot.Balance,this.winBalance=this.jackpot.WinBalance,this.jackpotEndTime=this.jackpot.JackpotEndTime,this.disabledStatus=this.jackpot.Reason||"",this.startCountdown()}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0),2!==this.activeTab||this.maxVisibleGames||this.setVisibleGames()}disconnectedCallback(){this.clearInterval()}clearInterval(){this.interval&&(clearInterval(this.interval),this.interval=null)}setVisibleGames(){const t="Mobile"===this.device?10:12,e="Mobile"===this.device?4:5;this.maxVisibleGames=Math.max(Math.floor(this.gamesListWrapperEl.offsetHeight/((this.gamesListWrapperEl.offsetWidth-t*(e-1))/e/74*40+t))*e,e),this.visibleGames=this.jackpot.GamesInfo.slice(0,this.maxVisibleGames)}updateJackpotStatus(t){t.IsClosed?(this.clearInterval(),this.disabledStatus=t.Reason,this.activeTab=1):(this.disabledStatus="",this.jackpotEndTime=t.JackpotEndTime,this.startCountdown())}getTopNavigationTemplate(){return o("div",{class:"JackpotDetailsNavigation"},o("button",{class:"JackpotIconButton",onClick:this.handleBackClick},o("img",{src:"https://static.everymatrix.com/gic/img/engagement-suite/back.svg",alt:"back"})),o("div",{class:"JackpotPopupName"},r("jackpots",this.language)),o("button",{class:"JackpotIconButton",onClick:this.handleCloseClick},o("img",{src:"https://static.everymatrix.com/gic/img/engagement-suite/close.svg",alt:"close"})))}getJackpotBalance(){return h(this.balance,this.jackpot.Currency)}getJoinButtonClasses(){return{PopupButton:!0,Active:this.enabled,Loading:this.jackpot.Pending}}getJackpotDetailsHeaderTemplate(){const t=p(new Date(this.jackpot.JackpotEndTime),new Date)||!!this.disabledStatus;return o("div",{class:"JackpotDetailsHeader"},o("div",null,o("div",{class:"JackpotType"},this.jackpot.Type),o("div",{class:"JackpotBalance"},this.getJackpotBalance())),o("div",{class:"JackpotDetailsHeaderSecondCol"},o("button",{disabled:t,onClick:this.jackpotChangeStatusRequest,class:this.getJoinButtonClasses(),"data-id":this.jackpot.JackpotId},r(this.enabled?"unjoin":"join",this.language)),!!this.winBalance&&o("div",{class:"JackpotIsWon"},r("jackpotIsWon",this.language))))}getTabsTemplate(){return o("div",{class:"JackpotDetailsTabs"},o("div",{"data-index":"1",onClick:this.handleTabChange,class:"JackpotDetailsTab "+(1===this.activeTab?"Active":"")},r("info",this.language)),o("div",{"data-index":"2",onClick:this.handleTabChange,class:"JackpotDetailsTab "+(2===this.activeTab?"Active":"")},r("games",this.language)))}getTabsContentTemplate(){return 1===this.activeTab?this.getJackpotInfoTemplate():this.getGamesTemplate()}getJackpotDetailsTemplate(){return o("div",null,o("div",{class:"JackpotDetailsButton",onClick:this.toggleShowDetails},o("div",{class:"Toggle "+(this.showDetails?"Closed":"Open")}),o("span",null,r("jackpotDetails",this.language))),this.showDetails&&o("div",{class:"JackpotDetailsContent"},this.jackpot.Description&&o("p",{class:"JackpotDescription"},this.jackpot.Description),this.jackpot.JackpotRulesUrl&&o("a",{class:"TermsAndConditions",href:this.jackpot.JackpotRulesUrl,target:"_blank"},r("tc",this.jackpot.JackpotRulesUrl))))}getBetLimitsRange(){var t,e,a,i;if(this.jackpot.BetLimits){const s=this.jackpot.Currency,n=Object.keys(this.jackpot.BetLimits),p=n.find((t=>t===s))||n[0],c=this.jackpot.BetLimits&&!!(null===(t=this.jackpot.BetLimits[p])||void 0===t?void 0:t.MinBet),l=this.jackpot.BetLimits&&!!(null===(e=this.jackpot.BetLimits[p])||void 0===e?void 0:e.MaxBet),k=h(null===(a=this.jackpot.BetLimits[p])||void 0===a?void 0:a.MinBet,p),d=h(null===(i=this.jackpot.BetLimits[p])||void 0===i?void 0:i.MaxBet,p);return o("div",null,c&&o("div",{class:"JackpotInfoItem"},r("minBet",this.language),": ",o("span",null,k)),l&&o("div",{class:"JackpotInfoItem"},r("maxBet",this.language),": ",o("span",null,d)))}}getJackpotInfoTemplate(){return o("div",{class:"JackpotInfoTabContent"},!(!this.jackpot.Description&&!this.jackpot.JackpotRulesUrl)&&this.getJackpotDetailsTemplate(),o("div",{class:"JackpotInfo"},o("div",{class:"JackpotInfoItem"},r("betContribution",this.language),": ",o("span",null,+this.jackpot.ContributionPercent,"%")),o("div",{class:"JackpotInfoItem"},r("type",this.language),": ",o("span",null,this.jackpot.JackpotTypePresentation)),o("div",{class:"JackpotInfoItem"},r("winningProbability",this.language),": ",o("span",null,"1:",this.jackpot.Probability)),o("div",{class:"JackpotInfoItem"},r("operatorContribution",this.language),": ",o("span",null,+this.jackpot.OperatorContributionPercent,"%"),o("button",{class:"JackpotContributionTooltipButton",onClick:this.toggleTooltip})),this.getBetLimitsRange()))}getGamesTemplate(){const t=this.visibleGames.map((t=>o("div",{onClick:this.onGameClick,class:"JackpotGamesListItem "+(t.GameSlug===this.gameSlug?"Disabled":""),key:t.CasinoGameId,"data-slug":t.GameSlug,style:{background:`center / cover url(${t.GameIcon}) no-repeat`},title:t.GameName})));return[o("div",{class:"JackpotGamesListWrapper",ref:t=>this.gamesListWrapperEl=t},o("div",{class:"JackpotGamesList"},t)),this.visibleGames.length<this.jackpot.GamesInfo.length?o("button",{class:"PopupButton Active JackpotGamesButton",onClick:this.handleLoadMore},r("loadMore",this.language)):""]}getJackpotCountdown(){const t=r(this.disabledStatus,this.language)||this.timer;return o("div",{class:"JackpotCountdown "+(this.disabledStatus?"Suspended":"")},t)}startCountdown(){this.updateTimer(),this.interval=setInterval((()=>{this.updateTimer()}),1e3)}updateTimer(){const t=new Date(this.jackpotEndTime).getTime()-(new Date).getTime();if(t<1)return void this.clearInterval();const{days:e,hours:o,minutes:a,seconds:i}={days:String(Math.floor(t/864e5)).padStart(2,"0"),hours:String(Math.floor(t%864e5/36e5)).padStart(2,"0"),minutes:String(Math.floor(t%36e5/6e4)).padStart(2,"0"),seconds:String(Math.floor(t%6e4/1e3)).padStart(2,"0")};this.timer="00"===e?`${o}h:${a}m:${i}s`:`${e}d:${o}h:${a}m`}getPopupClasses(){return{JackpotDetailsPopup:!0,Disabled:!!this.disabledStatus||p(new Date(this.jackpot.JackpotEndTime),new Date),[this.device]:!0,[this.jackpot.Type.charAt(0).toUpperCase()+this.jackpot.Type.slice(1)]:!0}}getTooltipTemplate(){return o("div",{class:"JackpotsTooltipBackdrop"},o("div",{class:"JackpotsTooltip"},o("button",{class:"JackpotsIconButton",onClick:this.toggleTooltip},o("img",{src:"https://static.everymatrix.com/gic/img/engagement-suite/close.svg",alt:"Close tooltip"})),r("contributionTooltip",this.language)))}render(){return o("div",{key:"1588370db82c0c7d4118fce75e60cb2e1204c9f3",class:this.getPopupClasses()},this.getTopNavigationTemplate(),o("div",{key:"320b03501c86164369fc715590cfbbfa6dc8bf3e",class:"JackpotDetailsPopupContent"},this.getJackpotDetailsHeaderTemplate(),this.getJackpotCountdown(),this.getTabsTemplate(),this.getTabsContentTemplate(),this.showTooltip&&this.getTooltipTemplate()))}get host(){return a(this)}static get watchers(){return{jackpot:["handleJackpotUpdate"]}}};k.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none}button:focus{outline:none}button:not(:disabled){cursor:pointer}.PopupButton{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);color:var(--emw--color-typography, #1E1638);border-radius:99px;min-width:88px;min-height:32px;font-size:14px;font-weight:700;position:relative;font-family:"Montserrat", sans-serif}.PopupButton.Active{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.PopupButton.Active::before{content:"";position:absolute;inset:0;padding:1px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-mask:linear-gradient(#FFF 0 0) content-box, linear-gradient(#FFF 0 0);-webkit-mask-composite:xor;mask-composite:exclude;border-radius:99px}.PopupButton.Loading{opacity:0.5;pointer-events:none}.JackpotDetailsPopup{display:flex;height:100%;background-color:var(--emw--color-background, #1E1638);border-radius:8px;overflow:hidden;flex-direction:column;position:relative}.JackpotDetailsPopup.Disabled .JackpotDetailsHeader{opacity:0.5}.JackpotDetailsPopup.Disabled .JackpotDetailsTabs{cursor:default;pointer-events:none}.JackpotDetailsPopup.Disabled .JackpotInfoItem{color:var(--emw--color-primary, #8F8B9C)}.JackpotGamesListWrapper,.JackpotInfoTabContent{overflow-x:auto;scrollbar-gutter:stable}.JackpotGamesListWrapper::-webkit-scrollbar,.JackpotInfoTabContent::-webkit-scrollbar{width:3px;background:none}.JackpotGamesListWrapper::-webkit-scrollbar-thumb,.JackpotInfoTabContent::-webkit-scrollbar-thumb{border-radius:4px;background:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.JackpotDetailsNavigation{display:flex;justify-content:space-between;align-items:center;padding:12px 8px 8px}.JackpotDetailsNavigation .JackpotIconButton{width:16px;height:16px;cursor:pointer;display:flex;justify-content:center;align-items:center}.JackpotDetailsNavigation .JackpotPopupName{color:var(--emw--color-gray-100, #BBB9C3);font-size:16px;font-weight:500;line-height:16px;display:none}.JackpotDetailsPopupContent{padding:8px 18px 18px;overflow:hidden;height:100%;display:flex;flex-direction:column}.JackpotDetailsHeader{display:flex;justify-content:space-between;align-items:center;gap:12px}.JackpotDetailsHeader .JackpotDetailsHeaderSecondCol{text-align:right}.JackpotDetailsHeader .JackpotType{text-transform:uppercase;font-family:"Montserrat", sans-serif;font-size:var(--emw--font-size-medium, 18px);font-weight:var(--emw--font-weight-bold, 700);line-height:22px;color:var(--emfe-w-color-white, #FFF);word-break:break-all}.JackpotDetailsHeader .JackpotBalance{margin-top:8px;font-family:Montserrat, sans-serif;font-size:18px;font-weight:var(--emw--font-weight-bold, 800);line-height:18px}.JackpotDetailsHeader .JackpotIsWon{margin-top:8px;font-family:Montserrat, sans-serif;font-weight:var(--emw--font-weight-bold, 700);font-size:12px;line-height:15px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Mega .JackpotBalance{background:linear-gradient(180deg, #FFB801 15.86%, #FEF746 31.36%, #FBFFE0 36.86%, #FFFA60 47.86%, #FF9400 87.36%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Major .JackpotBalance{background:linear-gradient(180deg, #A19FA0 5.36%, #E1DBDB 28.86%, #FEFFFF 36.86%, #E1DBDB 44.36%, #5E5B5F 91.86%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Minor .JackpotBalance{background:linear-gradient(180deg, #A0522C 5.36%, #FFAB8C 28.86%, #FFEEDF 36.86%, #FFAB8C 44.36%, #6A3A21 91.86%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotGamesLoadMore::before,.JackpotJoinButton.Joined::before{content:"";position:absolute;inset:0;border-radius:var(--emw--button-border-radius, 4px);padding:1px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-mask:linear-gradient(#FFF 0 0) content-box, linear-gradient(#FFF 0 0);-webkit-mask-composite:xor;mask-composite:exclude}.JackpotGamesButton{margin-top:12px;align-self:center;min-width:140px}.JackpotCountdown{font-size:var(--emw--font-size-x-small, 12px);line-height:12px;margin-top:12px;color:var(--emw--color-gray-150, #BBB9C3)}.JackpotCountdown.Suspended{font-weight:var(--emw--font-weight-bold, 700);color:var(--emfe-w-color-white, #FFF);text-transform:capitalize}.JackpotDetailsTabsWrapper{display:flex;flex-direction:column}.JackpotDetailsTabs{margin:20px 0 12px;display:flex;position:relative}.JackpotDetailsTabs .JackpotDetailsTab{padding:9px 16px 7px;font-weight:500;font-size:12px;line-height:15px;color:var(--emw--color-background, #666178);border-bottom:2px solid transparent;cursor:pointer}.JackpotDetailsTabs .JackpotDetailsTab.Active{color:var(--emw--color-typography, #FFF);border-color:var(--emw--color-typography, #FFF)}.JackpotDetailsTabs::after{content:"";position:absolute;bottom:0;left:0;width:100%;height:1px;background-color:var(--emw--color-typography, #FFF);opacity:0.1}.JackpotInfoItem{margin-bottom:8px;color:var(--emw--color-typography, #FFF);font-size:14px;line-height:17px}.JackpotInfoItem span{font-weight:var(--emw--font-weight-bold, 700)}.JackpotInfoItem .tc{color:var(--emw--color-primary, #59D1FF)}.JackpotGamesListWrapper{overflow:auto;flex-grow:1}.JackpotGamesList{display:flex;gap:10px;flex-wrap:wrap}.JackpotGamesList .JackpotGamesListItem{width:calc(25% - 8px);aspect-ratio:74/40;cursor:pointer}.JackpotGamesList .JackpotGamesListItem.Disabled{opacity:0.5;pointer-events:none;cursor:auto}.JackpotDetailsButton{margin-bottom:12px;display:flex;align-items:center;font-size:var(--emw--font-size-x-small, 12px);line-height:12px;color:var(--emw--color-primary-variant, #666178);cursor:pointer}.JackpotDetailsButton .Toggle{width:16px;height:16px;margin-right:4px}.JackpotDetailsButton .Closed{background:center/100% url("https://static.everymatrix.com/gic/img/engagement-suite/eye-closed.svg")}.JackpotDetailsButton .Open{background:center/100% url("https://static.everymatrix.com/gic/img/engagement-suite/eye-open.svg")}.JackpotDescription{margin-bottom:20px;color:var(--emw--color-typography, #FFF);font-size:var(--emw--font-size-small, 14px);line-height:17px}.JackpotDetailsPopup.Tablet .JackpotDetailsButton,.JackpotDetailsPopup.Desktop .JackpotDetailsButton{margin-bottom:20px}.JackpotDetailsPopup.Tablet .JackpotDescription,.JackpotDetailsPopup.Desktop .JackpotDescription{font-size:var(--emw--font-size-medium, 16px);line-height:22px}.JackpotDetailsPopup.Tablet .JackpotPopupName,.JackpotDetailsPopup.Desktop .JackpotPopupName{display:block}.JackpotDetailsPopup.Tablet .JackpotDetailsNavigation,.JackpotDetailsPopup.Desktop .JackpotDetailsNavigation{padding-top:16px}.JackpotDetailsPopup.Tablet .JackpotIconButton,.JackpotDetailsPopup.Desktop .JackpotIconButton{width:24px;height:24px}.JackpotDetailsPopup.Tablet .JackpotDetailsPopupContent,.JackpotDetailsPopup.Desktop .JackpotDetailsPopupContent{padding:20px 24px 30px}.JackpotDetailsPopup.Tablet .JackpotBalance,.JackpotDetailsPopup.Tablet .JackpotType,.JackpotDetailsPopup.Desktop .JackpotBalance,.JackpotDetailsPopup.Desktop .JackpotType{line-height:27px;font-size:22px}.JackpotDetailsPopup.Tablet .JackpotBalance,.JackpotDetailsPopup.Desktop .JackpotBalance{font-weight:var(--emw--font-weight-bold, 700)}.JackpotDetailsPopup.Tablet .PopupButton,.JackpotDetailsPopup.Desktop .PopupButton{min-height:36px;font-size:16px}.JackpotDetailsPopup.Tablet .JackpotCountdown,.JackpotDetailsPopup.Desktop .JackpotCountdown{font-size:var(--emw--font-size-small, 14px);line-height:14px}.JackpotDetailsPopup.Tablet .JackpotDetailsTabs,.JackpotDetailsPopup.Desktop .JackpotDetailsTabs{margin-bottom:20px}.JackpotDetailsPopup.Tablet .JackpotInfoItem,.JackpotDetailsPopup.Desktop .JackpotInfoItem{font-size:16px;line-height:20px}.JackpotDetailsPopup.Tablet .JackpotIsWon,.JackpotDetailsPopup.Desktop .JackpotIsWon{font-size:14px;line-height:17px}.JackpotDetailsPopup.Tablet .JackpotGamesList,.JackpotDetailsPopup.Desktop .JackpotGamesList{gap:12px}.JackpotDetailsPopup.Tablet .JackpotGamesList .JackpotGamesListItem,.JackpotDetailsPopup.Desktop .JackpotGamesList .JackpotGamesListItem{width:calc(20% - 10px)}.JackpotDetailsPopup.Tablet .JackpotDetailsTabs .JackpotDetailsTab,.JackpotDetailsPopup.Desktop .JackpotDetailsTabs .JackpotDetailsTab{font-size:16px;line-height:20px}';export{k as casino_engagement_suite_jackpot_details}
@@ -0,0 +1,2 @@
1
+ var e=Object.defineProperty,t=new WeakMap,n=e=>t.get(e),l=(e,n)=>t.set(n.t=e,n),o=(e,t)=>t in e,s=(e,t)=>(0,console.error)(e,t),i=new Map,r=new Map,c="slot-fb{display:contents}slot-fb[hidden]{display:none}",a="undefined"!=typeof window?window:{},u=a.document||{head:{}},f={l:0,o:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,l)=>e.addEventListener(t,n,l),rel:(e,t,n,l)=>e.removeEventListener(t,n,l),ce:(e,t)=>new CustomEvent(e,t)},h=e=>Promise.resolve(e),d=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(e){}return!1})(),p=!1,m=[],y=[],$=(e,t)=>n=>{e.push(n),p||(p=!0,t&&4&f.l?w(v):f.raf(v))},b=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){s(e)}e.length=0},v=()=>{b(m),b(y),(p=m.length>0)&&f.raf(v)},w=e=>h().then(e),g=$(y,!0),S={},j=e=>"object"==(e=typeof e)||"function"===e;function k(e){var t,n,l;return null!=(l=null==(n=null==(t=e.head)?void 0:t.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?l:void 0}((t,n)=>{for(var l in n)e(t,l,{get:n[l],enumerable:!0})})({},{err:()=>O,map:()=>C,ok:()=>E,unwrap:()=>x,unwrapErr:()=>P});var E=e=>({isOk:!0,isErr:!1,value:e}),O=e=>({isOk:!1,isErr:!0,value:e});function C(e,t){if(e.isOk){const n=t(e.value);return n instanceof Promise?n.then((e=>E(e))):E(n)}if(e.isErr)return O(e.value);throw"should never get here"}var M,x=e=>{if(e.isOk)return e.value;throw e.value},P=e=>{if(e.isErr)return e.value;throw e.value},R=(e,t,...n)=>{let l=null,o=null,s=!1,i=!1;const r=[],c=t=>{for(let n=0;n<t.length;n++)l=t[n],Array.isArray(l)?c(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof e&&!j(l))&&(l+=""),s&&i?r[r.length-1].i+=l:r.push(s?A(null,l):l),i=s)};if(c(n),t){t.key&&(o=t.key);{const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}}const a=A(e,null);return a.u=t,r.length>0&&(a.h=r),a.p=o,a},A=(e,t)=>({l:0,m:e,i:t,$:null,h:null,u:null,p:null}),T={},D=e=>n(e).$hostElement$,F=(e,t,n)=>{const l=D(e);return{emit:e=>H(l,t,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:e})}},H=(e,t,n)=>{const l=f.ce(t,n);return e.dispatchEvent(l),l},L=new WeakMap,N=e=>"sc-"+e.v,U=(e,t,n,l,s,i)=>{if(n!==l){let r=o(e,t),c=t.toLowerCase();if("class"===t){const t=e.classList,o=q(n),s=q(l);t.remove(...o.filter((e=>e&&!s.includes(e)))),t.add(...s.filter((e=>e&&!o.includes(e))))}else if("style"===t){for(const t in n)l&&null!=l[t]||(t.includes("-")?e.style.removeProperty(t):e.style[t]="");for(const t in l)n&&l[t]===n[t]||(t.includes("-")?e.style.setProperty(t,l[t]):e.style[t]=l[t])}else if("key"===t);else if("ref"===t)l&&l(e);else if(r||"o"!==t[0]||"n"!==t[1]){const o=j(l);if((r||o&&null!==l)&&!s)try{if(e.tagName.includes("-"))e[t]=l;else{const o=null==l?"":l;"list"===t?r=!1:null!=n&&e[t]==o||(e[t]=o)}}catch(e){}null==l||!1===l?!1===l&&""!==e.getAttribute(t)||e.removeAttribute(t):(!r||4&i||s)&&!o&&e.setAttribute(t,l=!0===l?"":l)}else if(t="-"===t[2]?t.slice(3):o(a,c)?c.slice(2):c[2]+t.slice(3),n||l){const o=t.endsWith(G);t=t.replace(V,""),n&&f.rel(e,t,n,o),l&&f.ael(e,t,l,o)}}},W=/\s/,q=e=>e?e.split(W):[],G="Capture",V=RegExp(G+"$"),_=(e,t,n)=>{const l=11===t.$.nodeType&&t.$.host?t.$.host:t.$,o=e&&e.u||S,s=t.u||S;for(const e of z(Object.keys(o)))e in s||U(l,e,o[e],void 0,n,t.l);for(const e of z(Object.keys(s)))U(l,e,o[e],s[e],n,t.l)};function z(e){return e.includes("ref")?[...e.filter((e=>"ref"!==e)),"ref"]:e}var B=!1,I=!1,J=(e,t,n)=>{const l=t.h[n];let o,s,i=0;if(null!==l.i)o=l.$=u.createTextNode(l.i);else if(o=l.$=u.createElement(l.m),_(null,l,I),o.getRootNode().querySelector("body"),l.h)for(i=0;i<l.h.length;++i)s=J(e,l,i),s&&o.appendChild(s);return o["s-hn"]=M,o},K=(e,t,n,l,o,s)=>{let i,r=e;for(r.shadowRoot&&r.tagName===M&&(r=r.shadowRoot);o<=s;++o)l[o]&&(i=J(null,n,o),i&&(l[o].$=i,ee(r,i,t)))},Q=(e,t,n)=>{for(let l=t;l<=n;++l){const t=e[l];if(t){const e=t.$;Z(t),e&&e.remove()}}},X=(e,t,n=!1)=>e.m===t.m&&(!!n||e.p===t.p),Y=(e,t,n=!1)=>{const l=t.$=e.$,o=e.h,s=t.h,i=t.i;null===i?(("slot"!==t.m||B)&&_(e,t,I),null!==o&&null!==s?((e,t,n,l,o=!1)=>{let s,i,r=0,c=0,a=0,u=0,f=t.length-1,h=t[0],d=t[f],p=l.length-1,m=l[0],y=l[p];for(;r<=f&&c<=p;)if(null==h)h=t[++r];else if(null==d)d=t[--f];else if(null==m)m=l[++c];else if(null==y)y=l[--p];else if(X(h,m,o))Y(h,m,o),h=t[++r],m=l[++c];else if(X(d,y,o))Y(d,y,o),d=t[--f],y=l[--p];else if(X(h,y,o))Y(h,y,o),ee(e,h.$,d.$.nextSibling),h=t[++r],y=l[--p];else if(X(d,m,o))Y(d,m,o),ee(e,d.$,h.$),d=t[--f],m=l[++c];else{for(a=-1,u=r;u<=f;++u)if(t[u]&&null!==t[u].p&&t[u].p===m.p){a=u;break}a>=0?(i=t[a],i.m!==m.m?s=J(t&&t[c],n,a):(Y(i,m,o),t[a]=void 0,s=i.$),m=l[++c]):(s=J(t&&t[c],n,c),m=l[++c]),s&&ee(h.$.parentNode,s,h.$)}r>f?K(e,null==l[p+1]?null:l[p+1].$,n,l,c,p):c>p&&Q(t,r,f)})(l,o,t,s,n):null!==s?(null!==e.i&&(l.textContent=""),K(l,null,t,s,0,s.length-1)):!n&&null!==o&&Q(o,0,o.length-1)):e.i!==i&&(l.data=i)},Z=e=>{e.u&&e.u.ref&&e.u.ref(null),e.h&&e.h.map(Z)},ee=(e,t,n)=>null==e?void 0:e.insertBefore(t,n),te=(e,t)=>{t&&!e.S&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.S=t)))},ne=(e,t)=>{if(e.l|=16,!(4&e.l))return te(e,e.j),g((()=>le(e,t)));e.l|=512},le=(e,t)=>{const n=e.t;if(!n)throw Error(`Can't render component <${e.$hostElement$.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let l;return t&&(e.l|=256,e.k&&(e.k.map((([e,t])=>ue(n,e,t))),e.k=void 0),l=ue(n,"componentWillLoad")),oe(l,(()=>ie(e,n,t)))},oe=(e,t)=>se(e)?e.then(t).catch((e=>{console.error(e),t()})):t(),se=e=>e instanceof Promise||e&&e.then&&"function"==typeof e.then,ie=async(e,t,n)=>{var l;const o=e.$hostElement$,s=o["s-rc"];n&&(e=>{const t=e.O,n=e.$hostElement$,l=t.l,o=((e,t)=>{var n;const l=N(t),o=r.get(l);if(e=11===e.nodeType?e:u,o)if("string"==typeof o){let s,i=L.get(e=e.head||e);if(i||L.set(e,i=new Set),!i.has(l)){{s=u.createElement("style"),s.innerHTML=o;const l=null!=(n=f.C)?n:k(u);null!=l&&s.setAttribute("nonce",l),(!(1&t.l)||1&t.l&&"HEAD"!==e.nodeName)&&e.insertBefore(s,e.querySelector("link"))}4&t.l&&(s.innerHTML+=c),i&&i.add(l)}}else e.adoptedStyleSheets.includes(o)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,o]);return l})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&l&&2&l&&(n["s-sc"]=o,n.classList.add(o+"-h"))})(e);re(e,t,o,n),s&&(s.map((e=>e())),o["s-rc"]=void 0);{const t=null!=(l=o["s-p"])?l:[],n=()=>ce(e);0===t.length?n():(Promise.all(t).then(n),e.l|=4,t.length=0)}},re=(e,t,n,l)=>{try{t=t.render(),e.l&=-17,e.l|=2,((e,t,n=!1)=>{const l=e.$hostElement$,o=e.O,s=e.M||A(null,null),i=(e=>e&&e.m===T)(t)?t:R(null,null,t);if(M=l.tagName,o.P&&(i.u=i.u||{},o.P.map((([e,t])=>i.u[t]=l[e]))),n&&i.u)for(const e of Object.keys(i.u))l.hasAttribute(e)&&!["key","ref","style","class"].includes(e)&&(i.u[e]=l[e]);i.m=null,i.l|=4,e.M=i,i.$=s.$=l.shadowRoot||l,B=!!(1&o.l),Y(s,i,n)})(e,t,l)}catch(t){s(t,e.$hostElement$)}return null},ce=e=>{const t=e.$hostElement$,n=e.j;ue(e.t,"componentDidRender"),64&e.l||(e.l|=64,fe(t),e.R(t),n||ae()),e.S&&(e.S(),e.S=void 0),512&e.l&&w((()=>ne(e,!1))),e.l&=-517},ae=()=>{fe(u.documentElement),w((()=>H(a,"appload",{detail:{namespace:"casino-engagement-suite-jackpot-details"}})))},ue=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){s(e)}},fe=e=>e.classList.add("hydrated"),he=(e,t,l)=>{var o,i;const r=e.prototype;if(t.A||t.T||e.watchers){e.watchers&&!t.T&&(t.T=e.watchers);const c=Object.entries(null!=(o=t.A)?o:{});if(c.map((([e,[o]])=>{(31&o||2&l&&32&o)&&Object.defineProperty(r,e,{get(){return((e,t)=>n(this).D.get(t))(0,e)},set(l){((e,t,l,o)=>{const i=n(e);if(!i)throw Error(`Couldn't find host element for "${o.v}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/ionic-team/stencil/issues/5457).`);const r=i.$hostElement$,c=i.D.get(t),a=i.l,u=i.t;if(l=((e,t)=>null==e||j(e)?e:4&t?"false"!==e&&(""===e||!!e):2&t?parseFloat(e):1&t?e+"":e)(l,o.A[t][0]),(!(8&a)||void 0===c)&&l!==c&&(!Number.isNaN(c)||!Number.isNaN(l))&&(i.D.set(t,l),u)){if(o.T&&128&a){const e=o.T[t];e&&e.map((e=>{try{u[e](l,c,t)}catch(e){s(e,r)}}))}2==(18&a)&&ne(i,!1)}})(this,e,l,t)},configurable:!0,enumerable:!0})})),1&l){const l=new Map;r.attributeChangedCallback=function(e,o,s){f.jmp((()=>{var i;const c=l.get(e);if(this.hasOwnProperty(c))s=this[c],delete this[c];else{if(r.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==s)return;if(null==c){const l=n(this),r=null==l?void 0:l.l;if(r&&!(8&r)&&128&r&&s!==o){const n=l.t,r=null==(i=t.T)?void 0:i[e];null==r||r.forEach((t=>{null!=n[t]&&n[t].call(n,s,o,e)}))}return}}this[c]=(null!==s||"boolean"!=typeof this[c])&&s}))},e.observedAttributes=Array.from(new Set([...Object.keys(null!=(i=t.T)?i:{}),...c.filter((([e,t])=>15&t[0])).map((([e,n])=>{var o;const s=n[1]||e;return l.set(s,e),512&n[0]&&(null==(o=t.P)||o.push([e,s])),s}))]))}}return e},de=e=>{ue(e,"disconnectedCallback")},pe=(e,l={})=>{var o;const h=[],p=l.exclude||[],m=a.customElements,y=u.head,$=y.querySelector("meta[charset]"),b=u.createElement("style"),v=[];let w,g=!0;Object.assign(f,l),f.o=new URL(l.resourcesUrl||"./",u.baseURI).href;let S=!1;if(e.map((e=>{e[1].map((l=>{var o;const c={l:l[0],v:l[1],A:l[2],F:l[3]};4&c.l&&(S=!0),c.A=l[2],c.F=l[3],c.P=[],c.T=null!=(o=l[4])?o:{};const a=c.v,u=class extends HTMLElement{constructor(e){if(super(e),this.hasRegisteredEventListeners=!1,((e,n)=>{const l={l:0,$hostElement$:e,O:n,D:new Map};l.H=new Promise((e=>l.R=e)),e["s-p"]=[],e["s-rc"]=[],t.set(e,l)})(e=this,c),1&c.l)if(e.shadowRoot){if("open"!==e.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${c.v}! Mode is set to ${e.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else e.attachShadow({mode:"open"})}connectedCallback(){const e=n(this);this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0,me(this,e,c.F)),w&&(clearTimeout(w),w=null),g?v.push(this):f.jmp((()=>(e=>{if(!(1&f.l)){const t=n(e),l=t.O,o=()=>{};if(1&t.l)me(e,t,l.F),(null==t?void 0:t.t)||(null==t?void 0:t.H)&&t.H.then((()=>{}));else{t.l|=1;{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){te(t,t.j=n);break}}l.A&&Object.entries(l.A).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n)=>{let l;if(!(32&t.l)){if(t.l|=32,n.L){const e=(e=>{const t=e.v.replace(/-/g,"_"),n=e.L;if(!n)return;const l=i.get(n);return l?l[t]:import(`./${n}.entry.js`).then((e=>(i.set(n,e),e[t])),s)
2
+ /*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n);if(e&&"then"in e){const t=()=>{};l=await e,t()}else l=e;if(!l)throw Error(`Constructor for "${n.v}#${t.N}" was not found`);l.isProxied||(n.T=l.watchers,he(l,n,2),l.isProxied=!0);const o=()=>{};t.l|=8;try{new l(t)}catch(e){s(e)}t.l&=-9,t.l|=128,o()}else l=e.constructor,customElements.whenDefined(e.localName).then((()=>t.l|=128));if(l&&l.style){let e;"string"==typeof l.style&&(e=l.style);const t=N(n);if(!r.has(t)){const l=()=>{};((e,t,n)=>{let l=r.get(e);d&&n?(l=l||new CSSStyleSheet,"string"==typeof l?l=t:l.replaceSync(t)):l=t,r.set(e,l)})(t,e,!!(1&n.l)),l()}}}const o=t.j,c=()=>ne(t,!0);o&&o["s-rc"]?o["s-rc"].push(c):c()})(e,t,l)}o()}})(this)))}disconnectedCallback(){f.jmp((()=>(async()=>{if(!(1&f.l)){const e=n(this);e.U&&(e.U.map((e=>e())),e.U=void 0),(null==e?void 0:e.t)?de(e.t):(null==e?void 0:e.H)&&e.H.then((()=>de(e.t)))}})()))}componentOnReady(){return n(this).H}};c.L=e[0],p.includes(a)||m.get(a)||(h.push(a),m.define(a,he(u,c,1)))}))})),h.length>0&&(S&&(b.textContent+=c),b.textContent+=h.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",b.innerHTML.length)){b.setAttribute("data-styles","");const e=null!=(o=f.C)?o:k(u);null!=e&&b.setAttribute("nonce",e),y.insertBefore(b,$?$.nextSibling:y.firstChild)}g=!1,v.length?v.map((e=>e.connectedCallback())):f.jmp((()=>w=setTimeout(ae,30)))},me=(e,t,n)=>{n&&n.map((([n,l,o])=>{const s=$e(e,n),i=ye(t,o),r=be(n);f.ael(s,l,i,r),(t.U=t.U||[]).push((()=>f.rel(s,l,i,r)))}))},ye=(e,t)=>n=>{var l;try{256&e.l?null==(l=e.t)||l[t](n):(e.k=e.k||[]).push([t,n])}catch(e){s(e)}},$e=(e,t)=>8&t?a:e,be=e=>({passive:!!(1&e),capture:!!(2&e)}),ve=e=>f.C=e;export{pe as b,F as c,D as g,R as h,h as p,l as r,ve as s}
@@ -0,0 +1 @@
1
+ const o=()=>{};export{o as g}
@@ -0,0 +1,5 @@
1
+ 'use strict';
2
+
3
+ const globalScripts = () => {};
4
+
5
+ exports.globalScripts = globalScripts;
@@ -0,0 +1,390 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-d83151b6.js');
6
+
7
+ function _typeof(o) {
8
+ "@babel/helpers - typeof";
9
+
10
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
11
+ return typeof o;
12
+ } : function (o) {
13
+ return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
14
+ }, _typeof(o);
15
+ }
16
+
17
+ function requiredArgs(required, args) {
18
+ if (args.length < required) {
19
+ throw new TypeError(required + ' argument' + (required > 1 ? 's' : '') + ' required, but only ' + args.length + ' present');
20
+ }
21
+ }
22
+
23
+ /**
24
+ * @name toDate
25
+ * @category Common Helpers
26
+ * @summary Convert the given argument to an instance of Date.
27
+ *
28
+ * @description
29
+ * Convert the given argument to an instance of Date.
30
+ *
31
+ * If the argument is an instance of Date, the function returns its clone.
32
+ *
33
+ * If the argument is a number, it is treated as a timestamp.
34
+ *
35
+ * If the argument is none of the above, the function returns Invalid Date.
36
+ *
37
+ * **Note**: *all* Date arguments passed to any *date-fns* function is processed by `toDate`.
38
+ *
39
+ * @param {Date|Number} argument - the value to convert
40
+ * @returns {Date} the parsed date in the local time zone
41
+ * @throws {TypeError} 1 argument required
42
+ *
43
+ * @example
44
+ * // Clone the date:
45
+ * const result = toDate(new Date(2014, 1, 11, 11, 30, 30))
46
+ * //=> Tue Feb 11 2014 11:30:30
47
+ *
48
+ * @example
49
+ * // Convert the timestamp to date:
50
+ * const result = toDate(1392098430000)
51
+ * //=> Tue Feb 11 2014 11:30:30
52
+ */
53
+ function toDate(argument) {
54
+ requiredArgs(1, arguments);
55
+ var argStr = Object.prototype.toString.call(argument);
56
+
57
+ // Clone the date
58
+ if (argument instanceof Date || _typeof(argument) === 'object' && argStr === '[object Date]') {
59
+ // Prevent the date to lose the milliseconds when passed to new Date() in IE10
60
+ return new Date(argument.getTime());
61
+ } else if (typeof argument === 'number' || argStr === '[object Number]') {
62
+ return new Date(argument);
63
+ } else {
64
+ if ((typeof argument === 'string' || argStr === '[object String]') && typeof console !== 'undefined') {
65
+ // eslint-disable-next-line no-console
66
+ console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments");
67
+ // eslint-disable-next-line no-console
68
+ console.warn(new Error().stack);
69
+ }
70
+ return new Date(NaN);
71
+ }
72
+ }
73
+
74
+ /**
75
+ * @name isBefore
76
+ * @category Common Helpers
77
+ * @summary Is the first date before the second one?
78
+ *
79
+ * @description
80
+ * Is the first date before the second one?
81
+ *
82
+ * @param {Date|Number} date - the date that should be before the other one to return true
83
+ * @param {Date|Number} dateToCompare - the date to compare with
84
+ * @returns {Boolean} the first date is before the second date
85
+ * @throws {TypeError} 2 arguments required
86
+ *
87
+ * @example
88
+ * // Is 10 July 1989 before 11 February 1987?
89
+ * const result = isBefore(new Date(1989, 6, 10), new Date(1987, 1, 11))
90
+ * //=> false
91
+ */
92
+ function isBefore(dirtyDate, dirtyDateToCompare) {
93
+ requiredArgs(2, arguments);
94
+ var date = toDate(dirtyDate);
95
+ var dateToCompare = toDate(dirtyDateToCompare);
96
+ return date.getTime() < dateToCompare.getTime();
97
+ }
98
+
99
+ const DEFAULT_LANGUAGE = 'en';
100
+ const SUPPORTED_LANGUAGES = ['en'];
101
+ const TRANSLATIONS = {
102
+ en: {
103
+ jackpots: 'Jackpots',
104
+ join: 'Join',
105
+ unjoin: 'Unjoin',
106
+ info: 'Info',
107
+ games: 'Games',
108
+ operatorContribution: 'Operator Contribution',
109
+ type: 'Type',
110
+ winningProbability: 'Winning Probability',
111
+ tc: 'Terms & Conditions',
112
+ jackpotIsWon: 'Jackpot’s won!',
113
+ loadMore: 'Load More',
114
+ jackpotDetails: 'Jackpot Details',
115
+ }
116
+ };
117
+ const translate = (key, customLang) => {
118
+ const lang = customLang;
119
+ return TRANSLATIONS[lang !== undefined && SUPPORTED_LANGUAGES.includes(lang) ? lang : DEFAULT_LANGUAGE][key];
120
+ };
121
+
122
+ function formatBalance(amount, currency, maxAmount = 99999999) {
123
+ amount = Math.min(amount, maxAmount);
124
+ return `${currency} ${new Intl.NumberFormat('en', { minimumFractionDigits: 2, maximumFractionDigits: 2 })
125
+ .format(amount)}`;
126
+ }
127
+
128
+ const casinoEngagementSuiteJackpotDetailsCss = ":host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none}button:focus{outline:none}button:not(:disabled){cursor:pointer}.PopupButton{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);color:var(--emw--color-typography, #1E1638);border-radius:99px;min-width:88px;min-height:32px;font-size:14px;font-weight:700;position:relative;font-family:\"Montserrat\", sans-serif}.PopupButton.Active{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.PopupButton.Active::before{content:\"\";position:absolute;inset:0;padding:1px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-mask:linear-gradient(#FFF 0 0) content-box, linear-gradient(#FFF 0 0);-webkit-mask-composite:xor;mask-composite:exclude;border-radius:99px}.PopupButton.Loading{opacity:0.5;pointer-events:none}.JackpotDetailsPopup{display:flex;height:100%;background-color:var(--emw--color-background, #1E1638);border-radius:8px;overflow:hidden;flex-direction:column;position:relative}.JackpotDetailsPopup.Disabled .JackpotDetailsHeader{opacity:0.5}.JackpotDetailsPopup.Disabled .JackpotDetailsTabs{cursor:default;pointer-events:none}.JackpotDetailsPopup.Disabled .JackpotInfoItem{color:var(--emw--color-primary, #8F8B9C)}.JackpotGamesListWrapper,.JackpotInfoTabContent{overflow-x:auto;scrollbar-gutter:stable}.JackpotGamesListWrapper::-webkit-scrollbar,.JackpotInfoTabContent::-webkit-scrollbar{width:3px;background:none}.JackpotGamesListWrapper::-webkit-scrollbar-thumb,.JackpotInfoTabContent::-webkit-scrollbar-thumb{border-radius:4px;background:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.JackpotDetailsNavigation{display:flex;justify-content:space-between;align-items:center;padding:12px 8px 8px}.JackpotDetailsNavigation .JackpotIconButton{width:16px;height:16px;cursor:pointer;display:flex;justify-content:center;align-items:center}.JackpotDetailsNavigation .JackpotPopupName{color:var(--emw--color-gray-100, #BBB9C3);font-size:16px;font-weight:500;line-height:16px;display:none}.JackpotDetailsPopupContent{padding:8px 18px 18px;overflow:hidden;height:100%;display:flex;flex-direction:column}.JackpotDetailsHeader{display:flex;justify-content:space-between;align-items:center;gap:12px}.JackpotDetailsHeader .JackpotDetailsHeaderSecondCol{text-align:right}.JackpotDetailsHeader .JackpotType{text-transform:uppercase;font-family:\"Montserrat\", sans-serif;font-size:var(--emw--font-size-medium, 18px);font-weight:var(--emw--font-weight-bold, 700);line-height:22px;color:var(--emfe-w-color-white, #FFF);word-break:break-all}.JackpotDetailsHeader .JackpotBalance{margin-top:8px;font-family:Montserrat, sans-serif;font-size:18px;font-weight:var(--emw--font-weight-bold, 800);line-height:18px}.JackpotDetailsHeader .JackpotIsWon{margin-top:8px;font-family:Montserrat, sans-serif;font-weight:var(--emw--font-weight-bold, 700);font-size:12px;line-height:15px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Mega .JackpotBalance{background:linear-gradient(180deg, #FFB801 15.86%, #FEF746 31.36%, #FBFFE0 36.86%, #FFFA60 47.86%, #FF9400 87.36%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Major .JackpotBalance{background:linear-gradient(180deg, #A19FA0 5.36%, #E1DBDB 28.86%, #FEFFFF 36.86%, #E1DBDB 44.36%, #5E5B5F 91.86%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotDetailsPopup.Minor .JackpotBalance{background:linear-gradient(180deg, #A0522C 5.36%, #FFAB8C 28.86%, #FFEEDF 36.86%, #FFAB8C 44.36%, #6A3A21 91.86%);-webkit-text-fill-color:transparent;-webkit-background-clip:text}.JackpotGamesLoadMore::before,.JackpotJoinButton.Joined::before{content:\"\";position:absolute;inset:0;border-radius:var(--emw--button-border-radius, 4px);padding:1px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-mask:linear-gradient(#FFF 0 0) content-box, linear-gradient(#FFF 0 0);-webkit-mask-composite:xor;mask-composite:exclude}.JackpotGamesButton{margin-top:12px;align-self:center;min-width:140px}.JackpotCountdown{font-size:var(--emw--font-size-x-small, 12px);line-height:12px;margin-top:12px;color:var(--emw--color-gray-150, #BBB9C3)}.JackpotCountdown.Suspended{font-weight:var(--emw--font-weight-bold, 700);color:var(--emfe-w-color-white, #FFF);text-transform:capitalize}.JackpotDetailsTabsWrapper{display:flex;flex-direction:column}.JackpotDetailsTabs{margin:20px 0 12px;display:flex;position:relative}.JackpotDetailsTabs .JackpotDetailsTab{padding:9px 16px 7px;font-weight:500;font-size:12px;line-height:15px;color:var(--emw--color-background, #666178);border-bottom:2px solid transparent;cursor:pointer}.JackpotDetailsTabs .JackpotDetailsTab.Active{color:var(--emw--color-typography, #FFF);border-color:var(--emw--color-typography, #FFF)}.JackpotDetailsTabs::after{content:\"\";position:absolute;bottom:0;left:0;width:100%;height:1px;background-color:var(--emw--color-typography, #FFF);opacity:0.1}.JackpotInfoItem{margin-bottom:8px;color:var(--emw--color-typography, #FFF);font-size:14px;line-height:17px}.JackpotInfoItem span{font-weight:var(--emw--font-weight-bold, 700)}.JackpotInfoItem .tc{color:var(--emw--color-primary, #59D1FF)}.JackpotGamesListWrapper{overflow:auto;flex-grow:1}.JackpotGamesList{display:flex;gap:10px;flex-wrap:wrap}.JackpotGamesList .JackpotGamesListItem{width:calc(25% - 8px);aspect-ratio:74/40;cursor:pointer}.JackpotGamesList .JackpotGamesListItem.Disabled{opacity:0.5;pointer-events:none;cursor:auto}.JackpotDetailsButton{margin-bottom:12px;display:flex;align-items:center;font-size:var(--emw--font-size-x-small, 12px);line-height:12px;color:var(--emw--color-primary-variant, #666178);cursor:pointer}.JackpotDetailsButton .Toggle{width:16px;height:16px;margin-right:4px}.JackpotDetailsButton .Closed{background:center/100% url(\"https://static.everymatrix.com/gic/img/engagement-suite/eye-closed.svg\")}.JackpotDetailsButton .Open{background:center/100% url(\"https://static.everymatrix.com/gic/img/engagement-suite/eye-open.svg\")}.JackpotDescription{margin-bottom:20px;color:var(--emw--color-typography, #FFF);font-size:var(--emw--font-size-small, 14px);line-height:17px}.JackpotDetailsPopup.Tablet .JackpotDetailsButton,.JackpotDetailsPopup.Desktop .JackpotDetailsButton{margin-bottom:20px}.JackpotDetailsPopup.Tablet .JackpotDescription,.JackpotDetailsPopup.Desktop .JackpotDescription{font-size:var(--emw--font-size-medium, 16px);line-height:22px}.JackpotDetailsPopup.Tablet .JackpotPopupName,.JackpotDetailsPopup.Desktop .JackpotPopupName{display:block}.JackpotDetailsPopup.Tablet .JackpotDetailsNavigation,.JackpotDetailsPopup.Desktop .JackpotDetailsNavigation{padding-top:16px}.JackpotDetailsPopup.Tablet .JackpotIconButton,.JackpotDetailsPopup.Desktop .JackpotIconButton{width:24px;height:24px}.JackpotDetailsPopup.Tablet .JackpotDetailsPopupContent,.JackpotDetailsPopup.Desktop .JackpotDetailsPopupContent{padding:20px 24px 30px}.JackpotDetailsPopup.Tablet .JackpotBalance,.JackpotDetailsPopup.Tablet .JackpotType,.JackpotDetailsPopup.Desktop .JackpotBalance,.JackpotDetailsPopup.Desktop .JackpotType{line-height:27px;font-size:22px}.JackpotDetailsPopup.Tablet .JackpotBalance,.JackpotDetailsPopup.Desktop .JackpotBalance{font-weight:var(--emw--font-weight-bold, 700)}.JackpotDetailsPopup.Tablet .PopupButton,.JackpotDetailsPopup.Desktop .PopupButton{min-height:36px;font-size:16px}.JackpotDetailsPopup.Tablet .JackpotCountdown,.JackpotDetailsPopup.Desktop .JackpotCountdown{font-size:var(--emw--font-size-small, 14px);line-height:14px}.JackpotDetailsPopup.Tablet .JackpotDetailsTabs,.JackpotDetailsPopup.Desktop .JackpotDetailsTabs{margin-bottom:20px}.JackpotDetailsPopup.Tablet .JackpotInfoItem,.JackpotDetailsPopup.Desktop .JackpotInfoItem{font-size:16px;line-height:20px}.JackpotDetailsPopup.Tablet .JackpotIsWon,.JackpotDetailsPopup.Desktop .JackpotIsWon{font-size:14px;line-height:17px}.JackpotDetailsPopup.Tablet .JackpotGamesList,.JackpotDetailsPopup.Desktop .JackpotGamesList{gap:12px}.JackpotDetailsPopup.Tablet .JackpotGamesList .JackpotGamesListItem,.JackpotDetailsPopup.Desktop .JackpotGamesList .JackpotGamesListItem{width:calc(20% - 10px)}.JackpotDetailsPopup.Tablet .JackpotDetailsTabs .JackpotDetailsTab,.JackpotDetailsPopup.Desktop .JackpotDetailsTabs .JackpotDetailsTab{font-size:16px;line-height:20px}";
129
+ const CasinoEngagementSuiteJackpotDetailsStyle0 = casinoEngagementSuiteJackpotDetailsCss;
130
+
131
+ const CasinoEngagementSuiteJackpotDetails = class {
132
+ constructor(hostRef) {
133
+ index.registerInstance(this, hostRef);
134
+ this.close = index.createEvent(this, "close", 7);
135
+ this.back = index.createEvent(this, "back", 7);
136
+ this.maxVisibleGames = 0;
137
+ this.handleTabChange = (e) => {
138
+ this.activeTab = +(e.target.getAttribute('data-index'));
139
+ this.visibleGames = [];
140
+ this.maxVisibleGames = 0;
141
+ };
142
+ this.handleLoadMore = () => {
143
+ this.visibleGames = this.jackpot.GamesInfo.slice(0, this.visibleGames.length + this.maxVisibleGames);
144
+ };
145
+ this.toggleShowDetails = () => {
146
+ this.showDetails = !this.showDetails;
147
+ };
148
+ this.toggleTooltip = () => {
149
+ this.showTooltip = !this.showTooltip;
150
+ };
151
+ this.setClientStyling = () => {
152
+ let sheet = document.createElement('style');
153
+ sheet.innerHTML = this.clientStyling;
154
+ this.host.prepend(sheet);
155
+ };
156
+ this.setClientStylingURL = () => {
157
+ let url = new URL(this.clientStylingUrl);
158
+ let cssFile = document.createElement('style');
159
+ fetch(url.href)
160
+ .then((res) => res.text())
161
+ .then((data) => {
162
+ cssFile.innerHTML = data;
163
+ setTimeout(() => { this.host.prepend(cssFile); }, 1);
164
+ })
165
+ .catch((err) => {
166
+ console.log('Error ', err);
167
+ });
168
+ };
169
+ this.handleCloseClick = () => {
170
+ this.close.emit();
171
+ };
172
+ this.handleBackClick = () => {
173
+ this.back.emit();
174
+ };
175
+ this.onGameClick = (ev) => {
176
+ const slug = ev.currentTarget.getAttribute('data-slug');
177
+ if (slug) {
178
+ window.postMessage({
179
+ type: 'EngagementSuiteGameRedirect',
180
+ data: {
181
+ Slug: slug
182
+ }
183
+ });
184
+ }
185
+ };
186
+ this.clientStyling = '';
187
+ this.clientStylingUrl = '';
188
+ this.jackpot = undefined;
189
+ this.jackpotChangeStatusRequest = undefined;
190
+ this.language = 'en';
191
+ this.gameSlug = '';
192
+ this.device = 'Mobile';
193
+ this.limitStylingAppends = false;
194
+ this.timer = '';
195
+ this.disabledStatus = '';
196
+ this.activeTab = 1;
197
+ this.visibleGames = [];
198
+ this.enabled = false;
199
+ this.balance = undefined;
200
+ this.winBalance = undefined;
201
+ this.showDetails = false;
202
+ this.jackpotEndTime = '';
203
+ this.showTooltip = false;
204
+ }
205
+ handleEvent(e) {
206
+ const { type, data } = e === null || e === void 0 ? void 0 : e.data;
207
+ switch (type) {
208
+ case 'UpdateJackpotStatus': {
209
+ const data = e.data.data;
210
+ if (this.jackpot.JackpotId === data.JackpotId) {
211
+ this.updateJackpotStatus(e.data.data);
212
+ }
213
+ break;
214
+ }
215
+ case 'JoinJackpotResult': {
216
+ const res = data;
217
+ if (res.Success && this.jackpot.JackpotId in res.JackpotIds) {
218
+ this.enabled = this.jackpot.Enabled = res.JackpotIds[this.jackpot.JackpotId];
219
+ }
220
+ break;
221
+ }
222
+ }
223
+ }
224
+ handleJackpotUpdate() {
225
+ this.balance = this.jackpot.Balance;
226
+ this.winBalance = this.jackpot.WinBalance;
227
+ }
228
+ handleResize() {
229
+ this.activeTab === 2 && this.setVisibleGames();
230
+ this.showTooltip = false;
231
+ }
232
+ componentWillLoad() {
233
+ this.enabled = this.jackpot.Enabled;
234
+ this.balance = this.jackpot.Balance;
235
+ this.winBalance = this.jackpot.WinBalance;
236
+ this.jackpotEndTime = this.jackpot.JackpotEndTime;
237
+ this.disabledStatus = this.jackpot.Reason || '';
238
+ this.startCountdown();
239
+ }
240
+ componentDidRender() {
241
+ if (!this.limitStylingAppends && this.host) {
242
+ if (this.clientStyling)
243
+ this.setClientStyling();
244
+ if (this.clientStylingUrl)
245
+ this.setClientStylingURL();
246
+ this.limitStylingAppends = true;
247
+ }
248
+ if (this.activeTab === 2 && !this.maxVisibleGames) {
249
+ this.setVisibleGames();
250
+ }
251
+ }
252
+ disconnectedCallback() {
253
+ this.clearInterval();
254
+ }
255
+ clearInterval() {
256
+ if (this.interval) {
257
+ clearInterval(this.interval);
258
+ this.interval = null;
259
+ }
260
+ }
261
+ setVisibleGames() {
262
+ const gap = this.device === 'Mobile' ? 10 : 12;
263
+ const gamesPerRow = this.device === 'Mobile' ? 4 : 5;
264
+ const availableWidth = this.gamesListWrapperEl.offsetWidth - (gap * (gamesPerRow - 1));
265
+ const gameElWidth = availableWidth / gamesPerRow;
266
+ const gameElHeight = (gameElWidth / 74 * 40) + gap;
267
+ this.maxVisibleGames = Math.max(Math.floor(this.gamesListWrapperEl.offsetHeight / gameElHeight) * gamesPerRow, gamesPerRow);
268
+ this.visibleGames = this.jackpot.GamesInfo.slice(0, this.maxVisibleGames);
269
+ }
270
+ updateJackpotStatus(event) {
271
+ if (event.IsClosed) {
272
+ this.clearInterval();
273
+ this.disabledStatus = event.Reason;
274
+ this.activeTab = 1;
275
+ }
276
+ else {
277
+ this.disabledStatus = '';
278
+ this.jackpotEndTime = event.JackpotEndTime;
279
+ this.startCountdown();
280
+ }
281
+ }
282
+ getTopNavigationTemplate() {
283
+ return (index.h("div", { class: "JackpotDetailsNavigation" }, index.h("button", { class: "JackpotIconButton", onClick: this.handleBackClick }, index.h("img", { src: "https://static.everymatrix.com/gic/img/engagement-suite/back.svg", alt: "back" })), index.h("div", { class: "JackpotPopupName" }, translate('jackpots', this.language)), index.h("button", { class: "JackpotIconButton", onClick: this.handleCloseClick }, index.h("img", { src: "https://static.everymatrix.com/gic/img/engagement-suite/close.svg", alt: "close" }))));
284
+ }
285
+ getJackpotBalance() {
286
+ return formatBalance(this.balance, this.jackpot.Currency);
287
+ }
288
+ getJoinButtonClasses() {
289
+ return {
290
+ PopupButton: true,
291
+ Active: this.enabled,
292
+ Loading: this.jackpot.Pending
293
+ };
294
+ }
295
+ getJackpotDetailsHeaderTemplate() {
296
+ const joinButtonDisabled = isBefore(new Date(this.jackpot.JackpotEndTime), new Date()) || !!this.disabledStatus;
297
+ return (index.h("div", { class: "JackpotDetailsHeader" }, index.h("div", null, index.h("div", { class: "JackpotType" }, this.jackpot.Type), index.h("div", { class: "JackpotBalance" }, this.getJackpotBalance())), index.h("div", { class: "JackpotDetailsHeaderSecondCol" }, index.h("button", { disabled: joinButtonDisabled, onClick: this.jackpotChangeStatusRequest, class: this.getJoinButtonClasses(), "data-id": this.jackpot.JackpotId }, this.enabled
298
+ ? translate('unjoin', this.language)
299
+ : translate('join', this.language)), !!this.winBalance && index.h("div", { class: "JackpotIsWon" }, translate('jackpotIsWon', this.language)))));
300
+ }
301
+ getTabsTemplate() {
302
+ return index.h("div", { class: "JackpotDetailsTabs" }, index.h("div", { "data-index": "1", onClick: this.handleTabChange, class: `JackpotDetailsTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('info', this.language)), index.h("div", { "data-index": "2", onClick: this.handleTabChange, class: `JackpotDetailsTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('games', this.language)));
303
+ }
304
+ getTabsContentTemplate() {
305
+ return this.activeTab === 1
306
+ ? this.getJackpotInfoTemplate()
307
+ : this.getGamesTemplate();
308
+ }
309
+ getJackpotDetailsTemplate() {
310
+ return index.h("div", null, index.h("div", { class: "JackpotDetailsButton", onClick: this.toggleShowDetails }, index.h("div", { class: `Toggle ${this.showDetails ? 'Closed' : 'Open'}` }), index.h("span", null, translate('jackpotDetails', this.language))), this.showDetails && index.h("div", { class: "JackpotDetailsContent" }, this.jackpot.Description && index.h("p", { class: "JackpotDescription" }, this.jackpot.Description), this.jackpot.JackpotRulesUrl && index.h("a", { class: "TermsAndConditions", href: this.jackpot.JackpotRulesUrl, target: "_blank" }, translate('tc', this.jackpot.JackpotRulesUrl))));
311
+ }
312
+ getBetLimitsRange() {
313
+ var _a, _b, _c, _d;
314
+ if (this.jackpot.BetLimits) {
315
+ const playerCurrency = this.jackpot.Currency;
316
+ const betCurrencies = Object.keys(this.jackpot.BetLimits);
317
+ const matchedCurrency = betCurrencies.find(currency => currency === playerCurrency);
318
+ const betCurrency = matchedCurrency ? matchedCurrency : betCurrencies[0];
319
+ const showMinBet = this.jackpot.BetLimits && !!((_a = this.jackpot.BetLimits[betCurrency]) === null || _a === void 0 ? void 0 : _a.MinBet);
320
+ const showMaxBet = this.jackpot.BetLimits && !!((_b = this.jackpot.BetLimits[betCurrency]) === null || _b === void 0 ? void 0 : _b.MaxBet);
321
+ const formattedMinBet = formatBalance((_c = this.jackpot.BetLimits[betCurrency]) === null || _c === void 0 ? void 0 : _c.MinBet, betCurrency);
322
+ const formattedMaxBet = formatBalance((_d = this.jackpot.BetLimits[betCurrency]) === null || _d === void 0 ? void 0 : _d.MaxBet, betCurrency);
323
+ return index.h("div", null, showMinBet && index.h("div", { class: "JackpotInfoItem" }, translate('minBet', this.language), ":\u00A0", index.h("span", null, formattedMinBet)), showMaxBet && index.h("div", { class: "JackpotInfoItem" }, translate('maxBet', this.language), ":\u00A0", index.h("span", null, formattedMaxBet)));
324
+ }
325
+ }
326
+ getJackpotInfoTemplate() {
327
+ const showDetails = !!(this.jackpot.Description || this.jackpot.JackpotRulesUrl);
328
+ return index.h("div", { class: "JackpotInfoTabContent" }, showDetails && this.getJackpotDetailsTemplate(), index.h("div", { class: "JackpotInfo" }, index.h("div", { class: "JackpotInfoItem" }, translate('betContribution', this.language), ":\u00A0", index.h("span", null, +this.jackpot.ContributionPercent, "%")), index.h("div", { class: "JackpotInfoItem" }, translate('type', this.language), ":\u00A0", index.h("span", null, this.jackpot.JackpotTypePresentation)), index.h("div", { class: "JackpotInfoItem" }, translate('winningProbability', this.language), ":\u00A0", index.h("span", null, "1:", this.jackpot.Probability)), index.h("div", { class: "JackpotInfoItem" }, translate('operatorContribution', this.language), ":\u00A0", index.h("span", null, +this.jackpot.OperatorContributionPercent, "%"), index.h("button", { class: "JackpotContributionTooltipButton", onClick: this.toggleTooltip })), this.getBetLimitsRange()));
329
+ }
330
+ getGamesTemplate() {
331
+ const list = this.visibleGames.map((game) => {
332
+ return index.h("div", { onClick: this.onGameClick, class: `JackpotGamesListItem ${game.GameSlug === this.gameSlug ? 'Disabled' : ''}`, key: game.CasinoGameId, "data-slug": game.GameSlug, style: { background: `center / cover url(${game.GameIcon}) no-repeat` }, title: game.GameName });
333
+ });
334
+ return [
335
+ index.h("div", { class: "JackpotGamesListWrapper", ref: el => this.gamesListWrapperEl = el }, index.h("div", { class: "JackpotGamesList" }, list)),
336
+ this.visibleGames.length < this.jackpot.GamesInfo.length
337
+ ? index.h("button", { class: "PopupButton Active JackpotGamesButton", onClick: this.handleLoadMore }, translate('loadMore', this.language))
338
+ : ''
339
+ ];
340
+ }
341
+ getJackpotCountdown() {
342
+ const timerMessage = translate(this.disabledStatus, this.language) || this.timer;
343
+ return (index.h("div", { class: `JackpotCountdown ${this.disabledStatus ? 'Suspended' : ''}` }, timerMessage));
344
+ }
345
+ startCountdown() {
346
+ this.updateTimer();
347
+ this.interval = setInterval(() => {
348
+ this.updateTimer();
349
+ }, 1000);
350
+ }
351
+ updateTimer() {
352
+ const expirationTime = new Date(this.jackpotEndTime).getTime();
353
+ const now = new Date().getTime();
354
+ const distance = expirationTime - now;
355
+ if (distance < 1) {
356
+ this.clearInterval();
357
+ return;
358
+ }
359
+ const { days, hours, minutes, seconds } = {
360
+ days: String(Math.floor(distance / (1000 * 60 * 60 * 24))).padStart(2, '0'),
361
+ hours: String(Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60))).padStart(2, '0'),
362
+ minutes: String(Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60))).padStart(2, '0'),
363
+ seconds: String(Math.floor((distance % (1000 * 60)) / 1000)).padStart(2, '0')
364
+ };
365
+ this.timer = days === '00'
366
+ ? `${hours}h:${minutes}m:${seconds}s`
367
+ : `${days}d:${hours}h:${minutes}m`;
368
+ }
369
+ getPopupClasses() {
370
+ return {
371
+ JackpotDetailsPopup: true,
372
+ Disabled: !!this.disabledStatus || isBefore(new Date(this.jackpot.JackpotEndTime), new Date()),
373
+ [this.device]: true,
374
+ [this.jackpot.Type.charAt(0).toUpperCase() + this.jackpot.Type.slice(1)]: true
375
+ };
376
+ }
377
+ getTooltipTemplate() {
378
+ return (index.h("div", { class: "JackpotsTooltipBackdrop" }, index.h("div", { class: "JackpotsTooltip" }, index.h("button", { class: "JackpotsIconButton", onClick: this.toggleTooltip }, index.h("img", { src: "https://static.everymatrix.com/gic/img/engagement-suite/close.svg", alt: "Close tooltip" })), translate('contributionTooltip', this.language))));
379
+ }
380
+ render() {
381
+ return index.h("div", { key: '1588370db82c0c7d4118fce75e60cb2e1204c9f3', class: this.getPopupClasses() }, this.getTopNavigationTemplate(), index.h("div", { key: '320b03501c86164369fc715590cfbbfa6dc8bf3e', class: "JackpotDetailsPopupContent" }, this.getJackpotDetailsHeaderTemplate(), this.getJackpotCountdown(), this.getTabsTemplate(), this.getTabsContentTemplate(), this.showTooltip && this.getTooltipTemplate()));
382
+ }
383
+ get host() { return index.getElement(this); }
384
+ static get watchers() { return {
385
+ "jackpot": ["handleJackpotUpdate"]
386
+ }; }
387
+ };
388
+ CasinoEngagementSuiteJackpotDetails.style = CasinoEngagementSuiteJackpotDetailsStyle0;
389
+
390
+ exports.casino_engagement_suite_jackpot_details = CasinoEngagementSuiteJackpotDetails;
@@ -0,0 +1,25 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-d83151b6.js');
6
+ const appGlobals = require('./app-globals-3a1e7e63.js');
7
+
8
+ /*
9
+ Stencil Client Patch Browser v4.20.0 | MIT Licensed | https://stenciljs.com
10
+ */
11
+ var patchBrowser = () => {
12
+ const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('casino-engagement-suite-jackpot-details.cjs.js', document.baseURI).href));
13
+ const opts = {};
14
+ if (importMeta !== "") {
15
+ opts.resourcesUrl = new URL(".", importMeta).href;
16
+ }
17
+ return index.promiseResolve(opts);
18
+ };
19
+
20
+ patchBrowser().then(async (options) => {
21
+ await appGlobals.globalScripts();
22
+ return index.bootstrapLazy([["casino-engagement-suite-jackpot-details.cjs",[[1,"casino-engagement-suite-jackpot-details",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"jackpot":[16],"jackpotChangeStatusRequest":[1040],"language":[1],"gameSlug":[1,"game-slug"],"device":[1],"limitStylingAppends":[32],"timer":[32],"disabledStatus":[32],"activeTab":[32],"visibleGames":[32],"enabled":[32],"balance":[32],"winBalance":[32],"showDetails":[32],"jackpotEndTime":[32],"showTooltip":[32]},[[8,"message","handleEvent"],[9,"resize","handleResize"]],{"jackpot":["handleJackpotUpdate"]}]]],["casino-engagement-suite-progress-bar.cjs",[[1,"casino-engagement-suite-progress-bar",{"value":[2],"disabled":[4],"hidePercent":[4,"hide-percent"],"indeterminate":[4],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"limitStylingAppends":[32]}]]]], options);
23
+ });
24
+
25
+ exports.setNonce = index.setNonce;
@@ -0,0 +1,71 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-d83151b6.js');
6
+
7
+ const casinoEngagementSuiteProgressBarCss = ":host{display:block;font-family:inherit}:host(.Desktop) .ProgressBarPercent{font-size:14px;line-height:14px}.ProgressBarBackground{height:8px;background-color:var(--emw--color-background, #666178);border-radius:4px;position:relative}.ProgressBarLine{position:absolute;left:0;top:0;bottom:0;border-radius:4px;background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);transition:width ease-out 0.3s}.ProgressBarInfo{margin-bottom:8px;display:flex;justify-content:space-between;align-items:center}.ProgressBarPercent{font-weight:700;font-size:12px;line-height:12px}.HidePercent .ProgressBarPercent{display:none}.ProgressBar:not(.Disabled) .ProgressBarPercent{background:linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.ProgressBar.Disabled .ProgressBarPercent{color:var(--emw--color-background, #666178)}.ProgressBar.Disabled .ProgressBarLine{background:var(--emw--color-background-secondary, #474668)}";
8
+ const CasinoEngagementSuiteProgressBarStyle0 = casinoEngagementSuiteProgressBarCss;
9
+
10
+ const CasinoEngagementSuiteProgressBar = class {
11
+ constructor(hostRef) {
12
+ index.registerInstance(this, hostRef);
13
+ this.setClientStyling = () => {
14
+ let sheet = document.createElement('style');
15
+ sheet.innerHTML = this.clientStyling;
16
+ this.host.prepend(sheet);
17
+ };
18
+ this.setClientStylingURL = () => {
19
+ let url = new URL(this.clientStylingUrl);
20
+ let cssFile = document.createElement('style');
21
+ fetch(url.href)
22
+ .then((res) => res.text())
23
+ .then((data) => {
24
+ cssFile.innerHTML = data;
25
+ setTimeout(() => { this.host.prepend(cssFile); }, 1);
26
+ })
27
+ .catch((err) => {
28
+ console.log('Error ', err);
29
+ });
30
+ };
31
+ this.value = 0;
32
+ this.disabled = false;
33
+ this.hidePercent = false;
34
+ this.indeterminate = false;
35
+ this.clientStyling = '';
36
+ this.clientStylingUrl = '';
37
+ this.limitStylingAppends = false;
38
+ }
39
+ componentDidRender() {
40
+ if (!this.limitStylingAppends && this.host) {
41
+ if (this.clientStyling)
42
+ this.setClientStyling();
43
+ if (this.clientStylingUrl)
44
+ this.setClientStylingURL();
45
+ this.limitStylingAppends = true;
46
+ }
47
+ }
48
+ getProgressBarClasses() {
49
+ return {
50
+ ProgressBar: true,
51
+ Completed: this.value === 100,
52
+ Disabled: this.disabled,
53
+ HidePercent: this.hidePercent || this.indeterminate
54
+ };
55
+ }
56
+ getProgressBarLineTemplate() {
57
+ if (this.indeterminate) {
58
+ return index.h("div", { class: "ProgressBarLine Indeterminate", part: "ProgressBarLine Indeterminate" });
59
+ }
60
+ else {
61
+ return index.h("div", { class: "ProgressBarLine", part: "ProgressBarLine", style: { width: this.value + '%' } });
62
+ }
63
+ }
64
+ render() {
65
+ return index.h("div", { key: 'ecce3a26a92d2e090c1db84bdc1bdbeb505080ed', class: this.getProgressBarClasses(), part: "ProgressBar" }, index.h("div", { key: '649fe1103d222200f2a1ad3b5967e37da1f1ab3d', class: "ProgressBarInfo", part: "ProgressBarInfo" }, index.h("slot", { key: '49dc180eedd823f0027f75099813fb9d91bcd938', name: "Title" }, index.h("div", { key: 'e6e59da3fe7bbcb37e118e7fd23a8ff35587aca5' })), index.h("slot", { key: '3dc8e5fd1dbc8c268b9c76e393b751cb53605e7e', name: "Percent" }, index.h("div", { key: '6a9e880f3ee3c4f26e8577c69be5db5f8e2d10ad', class: "ProgressBarPercent", part: "ProgressBarPercent" }, this.value, "%"))), index.h("div", { key: '141106e77caad7b04bb199f911e87c0c6f0adc2d', class: "ProgressBarBackground", part: "ProgressBarBackground" }, this.getProgressBarLineTemplate()));
66
+ }
67
+ get host() { return index.getElement(this); }
68
+ };
69
+ CasinoEngagementSuiteProgressBar.style = CasinoEngagementSuiteProgressBarStyle0;
70
+
71
+ exports.casino_engagement_suite_progress_bar = CasinoEngagementSuiteProgressBar;