@everymatrix/casino-engagement-suite-modal-container 1.67.0 → 1.68.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/casino-engagement-suite-modal-container/casino-engagement-suite-modal-container.esm.js +1 -1
- package/dist/casino-engagement-suite-modal-container/casino-engagement-suite-modal_2.entry.js +1 -1
- package/dist/cjs/casino-engagement-suite-modal-container.cjs.js +1 -1
- package/dist/cjs/casino-engagement-suite-modal_2.cjs.entry.js +12 -14
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/casino-engagement-suite-modal-container/casino-engagement-suite-modal-container.js +13 -14
- package/dist/esm/casino-engagement-suite-modal-container.js +1 -1
- package/dist/esm/casino-engagement-suite-modal_2.entry.js +12 -14
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/casino-engagement-suite-modal-container/casino-engagement-suite-modal-container.d.ts +1 -0
- package/dist/types/models/index.d.ts +1 -0
- package/package.json +1 -1
package/dist/casino-engagement-suite-modal-container/casino-engagement-suite-modal-container.esm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as n,b as e}from"./index-6912ff15.js";export{s as setNonce}from"./index-6912ff15.js";import{g as i}from"./app-globals-0f993ce5.js";(()=>{const e=import.meta.url,i={};return""!==e&&(i.resourcesUrl=new URL(".",e).href),n(i)})().then((async n=>(await i(),e([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],language:[1],isJoiningToChallenge:[1028,"is-joining-to-challenge"],device:[1],limitStylingAppends:[32],openModals:[32],rewardMessage:[32],hasError:[32],confirmationData:[32],winAmount:[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],isOpen:[4,"is-open"],isLoading:[1028,"is-loading"],header:[1],contentIcon:[1,"content-icon"],modalType:[1,"modal-type"],device:[1],showAnimation:[4,"show-animation"],limitStylingAppends:[32]}]]]],n))));
|
|
1
|
+
import{p as n,b as e}from"./index-6912ff15.js";export{s as setNonce}from"./index-6912ff15.js";import{g as i}from"./app-globals-0f993ce5.js";(()=>{const e=import.meta.url,i={};return""!==e&&(i.resourcesUrl=new URL(".",e).href),n(i)})().then((async n=>(await i(),e([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],language:[1],isJoiningToChallenge:[1028,"is-joining-to-challenge"],device:[1],limitStylingAppends:[32],openModals:[32],rewardMessage:[32],rewardText:[32],hasError:[32],confirmationData:[32],winAmount:[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],isOpen:[4,"is-open"],isLoading:[1028,"is-loading"],header:[1],contentIcon:[1,"content-icon"],modalType:[1,"modal-type"],device:[1],showAnimation:[4,"show-animation"],limitStylingAppends:[32]}]]]],n))));
|
package/dist/casino-engagement-suite-modal-container/casino-engagement-suite-modal_2.entry.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,c as t,h as o,g as i}from"./index-6912ff15.js";const a=class{constructor(o){e(this,o),this.closeModal=t(this,"closeModal",7),this.handleCloseClick=()=>{this.isLoading||this.closeModal.emit(this.modalType)},this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{this.host.prepend(t)}),1)})).catch((e=>{console.log("Error ",e)}))},this.clientStyling="",this.clientStylingUrl="",this.isOpen=void 0,this.isLoading=void 0,this.header=void 0,this.contentIcon=void 0,this.modalType=void 0,this.device="Mobile",this.showAnimation=!1,this.limitStylingAppends=!1}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){return o("div",{key:"570a2289e990efeae5cceac8bc2152cbb9bb5221",class:`ModalOverlay ${this.isOpen&&"Open"} ${this.device} ${this.showAnimation&&"ShowAnimation"}`},o("div",{key:"9d40898f29b5a539907a7e50f3fdee02636aced6",class:"ModalWinAnimation"}),o("div",{key:"724ffe5cd946b40aa12f99ac926a6c832c1633da",class:"ModalContent GradientBorder"},o("div",{key:"14bb1463ba0b5e9cdb545a81c13873a3e124f4c3",class:"IconCloseContainer"},o("button",{key:"1640c3c0881c65199a26f3f2217610189d626f91",class:"EngagementSuiteIconButton Close",onClick:this.handleCloseClick})),this.contentIcon?o("div",{class:"ModalIcon",style:{background:`url(${this.contentIcon}) no-repeat center, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%)`}}):null,o("div",{key:"c49ddc1152bb9c8af76ff11874816da8477ba821",class:"ModalHeader"},o("h1",{key:"08352f25028b0b08c2c1a77b91ea80cc968aa4e1"},this.header)),o("div",{key:"3420427d531aceb3861c1876394443ad664ff68b",class:"ModalBodyWrapper"},o("div",{key:"3e453586b727029f5fca9688b376d4b3e8298dbf",class:"ModalBody"},o("slot",{key:"0d82c3fa9b0faa9012005ccca85350313a684326",name:"body"})),o("div",{key:"9e7a078e4c912869f2e3573a533bb3cf82454a4c",class:"ModalFooter"},o("slot",{key:"df8e0568aeca79889cf8eb8f7fb33caf685b092e",name:"footer"})))))}get host(){return i(this)}};a.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer;touch-action:manipulation}button:focus{outline:none}.EngagementSuiteIconButton{width:24px;height:24px}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.ModalOverlay{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0, 0, 0, 0.5);justify-content:center;align-items:center;z-index:1}.ModalOverlay.Open{display:flex}.IconCloseContainer{width:100%;display:flex;justify-content:end}.ModalBodyWrapper{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden}.ModalBodyWrapper::-webkit-scrollbar{width:3px;background:none}.ModalBodyWrapper::-webkit-scrollbar-thumb{border-radius:var(--emw--border-radius-small, 4px);background-color:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.ModalContent{display:flex;flex-direction:column;align-items:center;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);position:relative;color:var(--emw--color-typography, #FFFFFF);background-color:var(--emw--color-background, #1E1638);padding:24px;border-radius:var(--emw--border-radius-large, 8px);width:450px;max-width:100%;text-align:center;max-height:90dvh}.GradientBorder::before{content:"";position:absolute;top:-1px;left:-1px;right:-1px;bottom:-1px;border-radius:var(--emw--border-radius-large, 9px);background:linear-gradient(143.2deg, #FF9401 -0.41%, #FFD32D 45.61%, #FF9401 82.77%);z-index:-1}.ModalHeader h1{font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large-plus, 24px);padding:0 16px;margin-bottom:16px}.ModalIcon{width:44px;height:44px;border-radius:50%;background-size:cover;margin:12px 0}.ModalBody{font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);color:var(--emw--color-secondary, #BBB9C3);padding:0 16px}.ModalFooter{margin-top:40px;margin-bottom:28px;padding:0 16px;width:100%}@keyframes rotate{100%{transform:rotate(1turn)}}.ModalOverlay .ModalWinAnimation{display:none}.ModalOverlay.ShowAnimation .ModalWinAnimation{display:block;position:absolute;width:100%;height:100%;inset:0;background:center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/light.svg) no-repeat, center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/win.svg) no-repeat;animation:6s rotate linear infinite}.ModalOverlay.Mobile .EngagementSuiteIconButton{width:16px;height:16px}.ModalOverlay.Mobile .ModalBody{font-size:var(--emw--font-size-small, 14px)}.ModalOverlay.Mobile .ModalContent{width:318px;padding:12px}.ModalOverlay.Mobile .ModalHeader h1{font-size:var(--emw--font-size-large, 20px);padding:0 60px}.ModalOverlay.Mobile.ShowAnimation .ModalWinAnimation{background-size:400px}';const n=["en"],s={en:{joinHeader:"Choose another mission?",desc:"Any progress on the current mission will be kept and you can rejoin the mission at any time.",joinQuestion:"Would you still like to join another mission?",joinConfirm:"Yes, join another mission",joinReject:"No, stay at this mission",unJoinHeader:"Quit Mission?",unJoinQuestion:"Would you still like to quit the mission?",unJoinConfirm:"Yes, I want to quit this mission",unJoinReject:"No, stay at this mission",join:"Unjoin",unJoin:"Unjoin",continue:"Continue",okContinue:"Ok, continue",won:"You won",supportInfo:"However, some rewards cannot be issued. Please, contact support.",noReward:"Reward cannot be issued",contactSupport:"Please contact support.",noMissions:"No Missions yet",tryOtherGames:"Try winning Missions as rewards or launching other booster games",tooltip:"Mission where your real money bets contribute towards the level progress to achieve the level reward",jackpotWin:"Total Jackpot Win!",jackpotWinInfo:"Please refresh game page or place any bet to update game balance",seeYouLater:"See you later",noSpinsLeft:"You used all spins here"}},r=(e,t)=>{const o=t;return s[void 0!==o&&n.includes(o)?o:"en"][e]},d=class{constructor(o){e(this,o),this.closeModal=t(this,"closeModal",7),this.handleCloseClick=e=>{const t=e.currentTarget.getAttribute("data-type");this.closeModal.emit(t)},this.handleChallengeAttendance=()=>{window.postMessage({type:"ChallengeJoinRequest",data:this.confirmationData})},this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{this.host.prepend(t)}),1)})).catch((e=>{console.log("Error ",e)}))},this.isModalOpen=e=>Boolean(this.openModals.find((t=>t===e))),this.clientStyling="",this.clientStylingUrl="",this.language="en",this.isJoiningToChallenge=void 0,this.device="Mobile",this.limitStylingAppends=!1,this.openModals=[],this.rewardMessage="",this.hasError=!1,this.confirmationData=null,this.winAmount={amount:0,currency:""}}openModalHandler(e){const{modalType:t,rewardMessage:o,hasError:i,confirmationData:a,winAmount:n}=e.detail;n&&(this.winAmount=this.isModalOpen("JACKPOT_REWARD_MODAL")?{amount:this.winAmount.amount+n.amount,currency:n.currency}:n),this.openModals=[...this.openModals,t],this.rewardMessage=o,this.hasError=i,a&&(this.confirmationData=a)}closeModalHandler(e){this.openModals=this.openModals.filter((t=>t!==e.detail))}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){const{ProgressToActivate:e}=this.confirmationData||{};return o("div",{key:"e9a8acb94d06f7c7f551de2fa61d601d3a0eeac8",class:`ModalContainer ${this.device}`},o("casino-engagement-suite-modal",{key:"5d28d01520bb671c4c932b6e53d6b1075f9c3378",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("REWARD_MODAL"),header:"Congratulations!",contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg",modalType:"REWARD_MODAL","show-animation":!0,device:this.device},o("div",{key:"6ef8750352a10fcbffbbe09c8bfba46b96c2098a",slot:"body"},o("div",{key:"c7b0c5c5202185a4001fbd23a60077e5b4484cfd"},r("won",this.language)," ",o("span",{key:"a4635cada0b6b4bb54a73377fcd0165a12400c5f",class:"ModalReward"},this.rewardMessage)),this.hasError&&o("div",{key:"e06df98ca254006caf79ff443da7e7c4dc7c8e46",class:"SupportInfo"},r("supportInfo",this.language))),o("div",{key:"434d5bf025fe0222f8d73d94e26bfe465492eacb",slot:"footer"},o("button",{key:"6927f9a1ee16c3b50abd62fe5bc736800b18d8f8",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"REWARD_MODAL"},r("continue",this.language)))),o("casino-engagement-suite-modal",{key:"802cb8c9e712f387f26ea4411f3bb0a1497fba80",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("JACKPOT_REWARD_MODAL"),header:"Congratulations!",contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg","show-animation":!0,modalType:"JACKPOT_REWARD_MODAL",device:this.device},o("div",{key:"70fe768de685e857cdf3cc889ec9f7a841ed4c09",slot:"body"},o("div",{key:"bfafa6ea6d1d200d4c4c1a1e2a9d5bc43a0fbfa1",class:"JackpotWinText"},r("jackpotWin",this.language)),o("div",{key:"62d3c8a92e0d0e0b2178087f421701a00b23bd32",class:"JackpotWinAmount"},(t=this.winAmount.amount,`${this.winAmount.currency} ${new Intl.NumberFormat("en",{minimumFractionDigits:2,maximumFractionDigits:2}).format(t)}`))),o("div",{key:"a062a76ba5d7d5ccb9defc85697b69d59ef1af5a",slot:"footer"},o("button",{key:"9fa028e9f0857539e66007b1ac5f5f005dd03267",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"JACKPOT_REWARD_MODAL"},r("continue",this.language)),o("div",{key:"483eb12b73245887e6ebc251e2e93db7e6d7dbc3",class:"JackpotWinInfoText"},r("jackpotWinInfo",this.language)))),o("casino-engagement-suite-modal",{key:"898dc39daf3ee36027a080364042e8653df9c390",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("TARGET_MODAL"),header:r(e?"joinHeader":"unJoinHeader",this.language),modalType:"TARGET_MODAL",device:this.device,isLoading:this.isJoiningToChallenge},o("div",{key:"08bcfbe6506982e393c92b0f776629dc336b751a",slot:"body"},o("div",{key:"58e20c9775e690344804f505ef30c5a4d59940ce",class:"LeftAlign"},r("desc",this.language)),o("div",{key:"8081f426a1c5556b3d95e875da12e9fb214937db",class:"LeftAlignQuestion"},r(e?"joinQuestion":"unJoinQuestion",this.language))),o("div",{key:"44614b02fd105bbe4a698460696a7842c85e3c49",slot:"footer",class:"ManyActions"},o("button",{key:"21b8b45fd8e28625d2ece9124bca65fb5429eb12",class:"ModalFooterButton "+(this.isJoiningToChallenge?"Disabled":""),onClick:this.handleChallengeAttendance},r(e?"joinConfirm":"unJoinConfirm",this.language)),o("button",{key:"e01e434afa2e1129c325042a37b1ac76be5a28c7",class:"ModalFooterButtonOutlined "+(this.isJoiningToChallenge?"Disabled":""),onClick:this.handleCloseClick,"data-type":"TARGET_MODAL"},o("div",{key:"622d587b43206691f4f67b7f13c18f4187560b15",class:"GradientText"},r(e?"joinReject":"unJoinReject",this.language))))),o("casino-engagement-suite-modal",{key:"8310ae114d8eefd5d91fb07c5d7cca34c70bffa3",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("SUPPORT_MODAL"),header:r("noReward",this.language),contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/alert.svg",modalType:"SUPPORT_MODAL",device:this.device},o("div",{key:"f6cc0be359c4cdbe0c2a3dd3ff3dbfb0841e65fe",slot:"body"},o("span",{key:"d4229846b65de554ba68c2c4545e2ac1fcc4fabe"},r("contactSupport",this.language))),o("div",{key:"55a91614a32feca8f3ea613b2ea27bb0f37145e9",slot:"footer"},o("button",{key:"9ea26fa1b55d7fe1201e460c11ec46e8ea673240",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"SUPPORT_MODAL"},r("okContinue",this.language)))),o("casino-engagement-suite-modal",{key:"d4e5b152a9599c3464d2f810dc2795cd482c1a1d",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("NO_SPIN_LEFT_MODAL"),header:r("noSpinsLeft",this.language),contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg",modalType:"NO_SPIN_LEFT_MODAL","show-animation":!1,device:this.device},o("div",{key:"ad796a55fe5078c31a595c0bd98787594cd58bec",slot:"body"},o("div",{key:"256ec7b9f143778c02e33e37a28b0d26c7ae2fa0"},r("seeYouLater",this.language))),o("div",{key:"0c861dd0e84b81730a3c56338ac38007b19cb70e",slot:"footer"},o("button",{key:"1ecd10f264a158b58a6e7d5db900175dcd36e65d",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"NO_SPIN_LEFT_MODAL"},"OK"))));var t}get host(){return i(this)}};d.style=':host{display:block;font-family:inherit}.ModalFooterButton,.ModalFooterButtonOutlined{transition:all 0.5s ease-out;background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));color:var(--emw--color-background, #1E1638);border-radius:99px;min-width:160px;height:36px;font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-bold, 700);position:relative;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);padding:0 12px;box-sizing:border-box;margin:auto;border:none;cursor:pointer}.ModalFooterButtonOutlined{background:linear-gradient(var(--emw--color-background, #1E1638) 0 0) padding-box, var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%)) border-box;border:2px solid transparent}.GradientText{background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));color:transparent;background-clip:text}.ManyActions{display:flex;width:100%;flex-direction:column;align-items:stretch}.ManyActions .ModalFooterButton,.ManyActions .ModalFooterButtonOutlined{width:280px}.ManyActions button:first-child{margin-bottom:16px}.Disabled{opacity:0.5;pointer-events:none;cursor:auto}.ModalReward{font-weight:var(--emw--font-weight-semibold, 600);color:var(--emw--color-typography, #FFFFFF);word-break:break-word}.JackpotWinText{margin:0;font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-medium, 16px);line-height:20px;color:var(--emw--color-typography, #FFF)}.JackpotWinAmount{margin-top:8px;background:var(--emw--linear-gradient-golden, 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;font-weight:var(--emw--font-weight-black, 900);font-size:var(--emw--font-size-medium, 16px);line-height:16px}.JackpotWinInfoText{padding:0 50px;margin-top:20px;font-size:var(--emw--font-size-small, 14px);line-height:16px;color:var(--emw--color-secondary, #BBB9C3)}.SupportInfo{margin-top:20px}.ModalContainer.Mobile .ModalFooterButton,.ModalContainer.Mobile .ModalFooterButtonOutlined{font-size:var(--emw--font-size-small, 14px);min-width:140px;height:32px}.ModalContainer.Mobile .ManyActions .ModalFooterButton,.ModalContainer.Mobile .ManyActions .ModalFooterButtonOutlined{width:100%;height:32px}.ModalContainer.Mobile .ManyActions button:first-child{margin-bottom:8px}.ModalContainer.Mobile .JackpotWinText{font-size:var(--emw--font-size-small, 14px);line-height:16px}.ModalContainer.Mobile .JackpotWinAmount{font-size:var(--emw--font-size-small, 14px);line-height:14px}.ModalContainer.Mobile .JackpotWinInfoText{padding:0;margin-top:20px;font-size:var(--emw--font-size-small, 14px);line-height:16px;color:var(--emw--color-secondary, #BBB9C3)}.LeftAlign,.LeftAlignQuestion{text-align:left;line-height:1.2}.LeftAlignQuestion{margin-top:20px}';export{a as casino_engagement_suite_modal,d as casino_engagement_suite_modal_container}
|
|
1
|
+
import{r as e,c as t,h as o,g as i}from"./index-6912ff15.js";const a=class{constructor(o){e(this,o),this.closeModal=t(this,"closeModal",7),this.handleCloseClick=()=>{this.isLoading||this.closeModal.emit(this.modalType)},this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{this.host.prepend(t)}),1)})).catch((e=>{console.log("Error ",e)}))},this.clientStyling="",this.clientStylingUrl="",this.isOpen=void 0,this.isLoading=void 0,this.header=void 0,this.contentIcon=void 0,this.modalType=void 0,this.device="Mobile",this.showAnimation=!1,this.limitStylingAppends=!1}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){return o("div",{key:"570a2289e990efeae5cceac8bc2152cbb9bb5221",class:`ModalOverlay ${this.isOpen&&"Open"} ${this.device} ${this.showAnimation&&"ShowAnimation"}`},o("div",{key:"9d40898f29b5a539907a7e50f3fdee02636aced6",class:"ModalWinAnimation"}),o("div",{key:"724ffe5cd946b40aa12f99ac926a6c832c1633da",class:"ModalContent GradientBorder"},o("div",{key:"14bb1463ba0b5e9cdb545a81c13873a3e124f4c3",class:"IconCloseContainer"},o("button",{key:"1640c3c0881c65199a26f3f2217610189d626f91",class:"EngagementSuiteIconButton Close",onClick:this.handleCloseClick})),this.contentIcon?o("div",{class:"ModalIcon",style:{background:`url(${this.contentIcon}) no-repeat center, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%)`}}):null,o("div",{key:"c49ddc1152bb9c8af76ff11874816da8477ba821",class:"ModalHeader"},o("h1",{key:"08352f25028b0b08c2c1a77b91ea80cc968aa4e1"},this.header)),o("div",{key:"3420427d531aceb3861c1876394443ad664ff68b",class:"ModalBodyWrapper"},o("div",{key:"3e453586b727029f5fca9688b376d4b3e8298dbf",class:"ModalBody"},o("slot",{key:"0d82c3fa9b0faa9012005ccca85350313a684326",name:"body"})),o("div",{key:"9e7a078e4c912869f2e3573a533bb3cf82454a4c",class:"ModalFooter"},o("slot",{key:"df8e0568aeca79889cf8eb8f7fb33caf685b092e",name:"footer"})))))}get host(){return i(this)}};a.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer;touch-action:manipulation}button:focus{outline:none}.EngagementSuiteIconButton{width:24px;height:24px}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.ModalOverlay{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0, 0, 0, 0.5);justify-content:center;align-items:center;z-index:1}.ModalOverlay.Open{display:flex}.IconCloseContainer{width:100%;display:flex;justify-content:end}.ModalBodyWrapper{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden}.ModalBodyWrapper::-webkit-scrollbar{width:3px;background:none}.ModalBodyWrapper::-webkit-scrollbar-thumb{border-radius:var(--emw--border-radius-small, 4px);background-color:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.ModalContent{display:flex;flex-direction:column;align-items:center;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);position:relative;color:var(--emw--color-typography, #FFFFFF);background-color:var(--emw--color-background, #1E1638);padding:24px;border-radius:var(--emw--border-radius-large, 8px);width:450px;max-width:100%;text-align:center;max-height:90dvh}.GradientBorder::before{content:"";position:absolute;top:-1px;left:-1px;right:-1px;bottom:-1px;border-radius:var(--emw--border-radius-large, 9px);background:linear-gradient(143.2deg, #FF9401 -0.41%, #FFD32D 45.61%, #FF9401 82.77%);z-index:-1}.ModalHeader h1{font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large-plus, 24px);padding:0 16px;margin-bottom:16px}.ModalIcon{width:44px;height:44px;border-radius:50%;background-size:cover;margin:12px 0}.ModalBody{font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);color:var(--emw--color-secondary, #BBB9C3);padding:0 16px}.ModalFooter{margin-top:40px;margin-bottom:28px;padding:0 16px;width:100%}@keyframes rotate{100%{transform:rotate(1turn)}}.ModalOverlay .ModalWinAnimation{display:none}.ModalOverlay.ShowAnimation .ModalWinAnimation{display:block;position:absolute;width:100%;height:100%;inset:0;background:center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/light.svg) no-repeat, center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/win.svg) no-repeat;animation:6s rotate linear infinite}.ModalOverlay.Mobile .EngagementSuiteIconButton{width:16px;height:16px}.ModalOverlay.Mobile .ModalBody{font-size:var(--emw--font-size-small, 14px)}.ModalOverlay.Mobile .ModalContent{width:318px;padding:12px}.ModalOverlay.Mobile .ModalHeader h1{font-size:var(--emw--font-size-large, 20px);padding:0 60px}.ModalOverlay.Mobile.ShowAnimation .ModalWinAnimation{background-size:400px}';const n=["en"],s={en:{joinHeader:"Choose another mission?",desc:"Any progress on the current mission will be kept and you can rejoin the mission at any time.",joinQuestion:"Would you still like to join another mission?",joinConfirm:"Yes, join another mission",joinReject:"No, stay at this mission",unJoinHeader:"Quit Mission?",unJoinQuestion:"Would you still like to quit the mission?",unJoinConfirm:"Yes, I want to quit this mission",unJoinReject:"No, stay at this mission",join:"Unjoin",unJoin:"Unjoin",continue:"Continue",okContinue:"Ok, continue",won:"You won",supportInfo:"However, some rewards cannot be issued. Please, contact support.",noReward:"Reward cannot be issued",contactSupport:"Please contact support.",noMissions:"No Missions yet",tryOtherGames:"Try winning Missions as rewards or launching other booster games",tooltip:"Mission where your real money bets contribute towards the level progress to achieve the level reward",jackpotWin:"Total Jackpot Win!",jackpotWinInfo:"Please refresh game page or place any bet to update game balance",seeYouLater:"See you later",noSpinsLeft:"You used all spins here"}},r=(e,t)=>{const o=t;return s[void 0!==o&&n.includes(o)?o:"en"][e]},d=class{constructor(o){e(this,o),this.closeModal=t(this,"closeModal",7),this.handleCloseClick=e=>{const t=e.currentTarget.getAttribute("data-type");this.closeModal.emit(t)},this.handleChallengeAttendance=()=>{window.postMessage({type:"ChallengeJoinRequest",data:this.confirmationData})},this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{this.host.prepend(t)}),1)})).catch((e=>{console.log("Error ",e)}))},this.isModalOpen=e=>Boolean(this.openModals.find((t=>t===e))),this.clientStyling="",this.clientStylingUrl="",this.language="en",this.isJoiningToChallenge=void 0,this.device="Mobile",this.limitStylingAppends=!1,this.openModals=[],this.rewardMessage="",this.rewardText="",this.hasError=!1,this.confirmationData=null,this.winAmount={amount:0,currency:""}}openModalHandler(e){const{modalType:t,rewardMessage:o,hasError:i,confirmationData:a,winAmount:n,rewardText:s}=e.detail;n&&(this.winAmount=this.isModalOpen("JACKPOT_REWARD_MODAL")?{amount:this.winAmount.amount+n.amount,currency:n.currency}:n),this.openModals=[...this.openModals,t],this.rewardMessage=o,this.rewardText=s,this.hasError=i,a&&(this.confirmationData=a)}closeModalHandler(e){this.openModals=this.openModals.filter((t=>t!==e.detail))}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){const{ProgressToActivate:e}=this.confirmationData||{};return o("div",{key:"b08af5892111b026ea04657bdc9ee8e03349985f",class:`ModalContainer ${this.device}`},o("casino-engagement-suite-modal",{key:"8f3b2f0f739f479311ee70eba23ba300bed9b3b4",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("REWARD_MODAL"),header:"Congratulations!",contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg",modalType:"REWARD_MODAL","show-animation":!0,device:this.device},o("div",{key:"620b3a805aeb6afd1224720ffa46adaeb4ac3313",slot:"body"},o("div",{key:"6897a7914a5b4cdb9c7ff5f4407e38668958a429"},!this.rewardText&&r("won",this.language)," ",o("span",{key:"e5b4f13e7d59bcb74de13769c4539251df62b831",class:"ModalReward"},this.rewardText||this.rewardMessage)),this.hasError&&o("div",{key:"c2bc2b252899961f28cb81fbb048073a707105fb",class:"SupportInfo"},r("supportInfo",this.language))),o("div",{key:"aa68c9f30956f3170dd432768ad19c95cfda5ea9",slot:"footer"},o("button",{key:"2a0a48a952ccbcd584ca1ace9955d77e37433bab",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"REWARD_MODAL"},r("continue",this.language)))),o("casino-engagement-suite-modal",{key:"14931f23c32b3aa54ad682e0619fd6025714d611",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("JACKPOT_REWARD_MODAL"),header:"Congratulations!",contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg","show-animation":!0,modalType:"JACKPOT_REWARD_MODAL",device:this.device},o("div",{key:"ed850c670505d0b0c2bd0a27ddab15999e38342a",slot:"body"},o("div",{key:"cca2417825d0365b3f2c026a3e4cbc51851f393d",class:"JackpotWinText"},r("jackpotWin",this.language)),o("div",{key:"854c6622f097ac5b37ad4bceeb50a415af826f11",class:"JackpotWinAmount"},(t=this.winAmount.amount,`${this.winAmount.currency} ${new Intl.NumberFormat("en",{minimumFractionDigits:2,maximumFractionDigits:2}).format(t)}`))),o("div",{key:"d0824ddf47b73fef4dc85a8208d4b4afaf396536",slot:"footer"},o("button",{key:"14c79e18756e2a83eaa865441ad065758533ddf0",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"JACKPOT_REWARD_MODAL"},r("continue",this.language)),o("div",{key:"a7da795c5bd9596b7b7b3fd5c4b3024e764df69a",class:"JackpotWinInfoText"},r("jackpotWinInfo",this.language)))),o("casino-engagement-suite-modal",{key:"eaff45fdc5b8a7eb280f88705d23e618f43c8723",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("TARGET_MODAL"),header:r(e?"joinHeader":"unJoinHeader",this.language),modalType:"TARGET_MODAL",device:this.device,isLoading:this.isJoiningToChallenge},o("div",{key:"b6b976ab9ad9a1e620dcb4663b90284c239159f4",slot:"body"},o("div",{key:"8bb1357f8509e26ecc6265b3b6bea7b8791ec307",class:"LeftAlign"},r("desc",this.language)),o("div",{key:"72cf7f14881769ab9b01728e1560cf4368ad5447",class:"LeftAlignQuestion"},r(e?"joinQuestion":"unJoinQuestion",this.language))),o("div",{key:"aabc5024f5ba5f3b130f592c6982538e76a63842",slot:"footer",class:"ManyActions"},o("button",{key:"c51bc6f661ed61557a459d9774f98a27cc3b1ae7",class:"ModalFooterButton "+(this.isJoiningToChallenge?"Disabled":""),onClick:this.handleChallengeAttendance},r(e?"joinConfirm":"unJoinConfirm",this.language)),o("button",{key:"75230bf99e98607427bdd932fd4f52a399b0354d",class:"ModalFooterButtonOutlined "+(this.isJoiningToChallenge?"Disabled":""),onClick:this.handleCloseClick,"data-type":"TARGET_MODAL"},o("div",{key:"756c14df8fbbd4c53a814967e43293301c2f81ec",class:"GradientText"},r(e?"joinReject":"unJoinReject",this.language))))),o("casino-engagement-suite-modal",{key:"496ba508f75434543423cc085514a23914947afe",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("SUPPORT_MODAL"),header:r("noReward",this.language),contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/alert.svg",modalType:"SUPPORT_MODAL",device:this.device},o("div",{key:"672c8cd14776e063a2a60f1b15e5aebcd3b7e15d",slot:"body"},o("span",{key:"91cfc35783c2ccd1e5f1bd36aabb1597c8fd8418"},r("contactSupport",this.language))),o("div",{key:"f7fdf4c75a43047c2748e07f77aeaf9ad457e64c",slot:"footer"},o("button",{key:"89b73a043587b6f5af54732bc6f3620e3b15fb66",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"SUPPORT_MODAL"},r("okContinue",this.language)))),o("casino-engagement-suite-modal",{key:"62e009b6c229659c6c93d39963f3e0ee4f00667d",clientStylingUrl:this.clientStylingUrl,isOpen:this.isModalOpen("NO_SPIN_LEFT_MODAL"),header:r("noSpinsLeft",this.language),contentIcon:"https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg",modalType:"NO_SPIN_LEFT_MODAL","show-animation":!1,device:this.device},o("div",{key:"f1877b36eb4ee45c80fcc522291b5679c06e898d",slot:"body"},o("div",{key:"74dc8497679ef79340506e30775ff8568df1d0a9"},r("seeYouLater",this.language))),o("div",{key:"17b3af15772508b4387f6f9459c8cf63c6149b54",slot:"footer"},o("button",{key:"879442528f93fed31f601e662ac1c1b49fcb7488",class:"ModalFooterButton",onClick:this.handleCloseClick,"data-type":"NO_SPIN_LEFT_MODAL"},"OK"))));var t}get host(){return i(this)}};d.style=':host{display:block;font-family:inherit}.ModalFooterButton,.ModalFooterButtonOutlined{transition:all 0.5s ease-out;background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));color:var(--emw--color-background, #1E1638);border-radius:99px;min-width:160px;height:36px;font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-bold, 700);position:relative;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);padding:0 12px;box-sizing:border-box;margin:auto;border:none;cursor:pointer}.ModalFooterButtonOutlined{background:linear-gradient(var(--emw--color-background, #1E1638) 0 0) padding-box, var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%)) border-box;border:2px solid transparent}.GradientText{background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));color:transparent;background-clip:text}.ManyActions{display:flex;width:100%;flex-direction:column;align-items:stretch}.ManyActions .ModalFooterButton,.ManyActions .ModalFooterButtonOutlined{width:280px}.ManyActions button:first-child{margin-bottom:16px}.Disabled{opacity:0.5;pointer-events:none;cursor:auto}.ModalReward{font-weight:var(--emw--font-weight-semibold, 600);color:var(--emw--color-typography, #FFFFFF);word-break:break-word}.JackpotWinText{margin:0;font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-medium, 16px);line-height:20px;color:var(--emw--color-typography, #FFF)}.JackpotWinAmount{margin-top:8px;background:var(--emw--linear-gradient-golden, 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;font-weight:var(--emw--font-weight-black, 900);font-size:var(--emw--font-size-medium, 16px);line-height:16px}.JackpotWinInfoText{padding:0 50px;margin-top:20px;font-size:var(--emw--font-size-small, 14px);line-height:16px;color:var(--emw--color-secondary, #BBB9C3)}.SupportInfo{margin-top:20px}.ModalContainer.Mobile .ModalFooterButton,.ModalContainer.Mobile .ModalFooterButtonOutlined{font-size:var(--emw--font-size-small, 14px);min-width:140px;height:32px}.ModalContainer.Mobile .ManyActions .ModalFooterButton,.ModalContainer.Mobile .ManyActions .ModalFooterButtonOutlined{width:100%;height:32px}.ModalContainer.Mobile .ManyActions button:first-child{margin-bottom:8px}.ModalContainer.Mobile .JackpotWinText{font-size:var(--emw--font-size-small, 14px);line-height:16px}.ModalContainer.Mobile .JackpotWinAmount{font-size:var(--emw--font-size-small, 14px);line-height:14px}.ModalContainer.Mobile .JackpotWinInfoText{padding:0;margin-top:20px;font-size:var(--emw--font-size-small, 14px);line-height:16px;color:var(--emw--color-secondary, #BBB9C3)}.LeftAlign,.LeftAlignQuestion{text-align:left;line-height:1.2}.LeftAlignQuestion{margin-top:20px}';export{a as casino_engagement_suite_modal,d as casino_engagement_suite_modal_container}
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["casino-engagement-suite-modal_2.cjs",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
22
|
+
return index.bootstrapLazy([["casino-engagement-suite-modal_2.cjs",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"rewardText":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -117,7 +117,7 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
117
117
|
this.handleChallengeAttendance = () => {
|
|
118
118
|
window.postMessage({
|
|
119
119
|
type: 'ChallengeJoinRequest',
|
|
120
|
-
data: this.confirmationData
|
|
120
|
+
data: this.confirmationData
|
|
121
121
|
});
|
|
122
122
|
};
|
|
123
123
|
this.setClientStyling = () => {
|
|
@@ -132,14 +132,16 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
132
132
|
.then((res) => res.text())
|
|
133
133
|
.then((data) => {
|
|
134
134
|
cssFile.innerHTML = data;
|
|
135
|
-
setTimeout(() => {
|
|
135
|
+
setTimeout(() => {
|
|
136
|
+
this.host.prepend(cssFile);
|
|
137
|
+
}, 1);
|
|
136
138
|
})
|
|
137
139
|
.catch((err) => {
|
|
138
140
|
console.log('Error ', err);
|
|
139
141
|
});
|
|
140
142
|
};
|
|
141
143
|
this.isModalOpen = (type) => {
|
|
142
|
-
return Boolean(this.openModals.find(el => el === type));
|
|
144
|
+
return Boolean(this.openModals.find((el) => el === type));
|
|
143
145
|
};
|
|
144
146
|
this.clientStyling = '';
|
|
145
147
|
this.clientStylingUrl = '';
|
|
@@ -149,12 +151,13 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
149
151
|
this.limitStylingAppends = false;
|
|
150
152
|
this.openModals = [];
|
|
151
153
|
this.rewardMessage = '';
|
|
154
|
+
this.rewardText = '';
|
|
152
155
|
this.hasError = false;
|
|
153
156
|
this.confirmationData = null;
|
|
154
157
|
this.winAmount = { amount: 0, currency: '' };
|
|
155
158
|
}
|
|
156
159
|
openModalHandler(event) {
|
|
157
|
-
const { modalType, rewardMessage, hasError, confirmationData, winAmount } = event.detail;
|
|
160
|
+
const { modalType, rewardMessage, hasError, confirmationData, winAmount, rewardText } = event.detail;
|
|
158
161
|
if (winAmount) {
|
|
159
162
|
// If jackpot win modal is already opened
|
|
160
163
|
// add won amount to the previous amount
|
|
@@ -167,13 +170,14 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
167
170
|
}
|
|
168
171
|
this.openModals = [...this.openModals, modalType];
|
|
169
172
|
this.rewardMessage = rewardMessage;
|
|
173
|
+
this.rewardText = rewardText;
|
|
170
174
|
this.hasError = hasError;
|
|
171
175
|
if (confirmationData) {
|
|
172
176
|
this.confirmationData = confirmationData;
|
|
173
177
|
}
|
|
174
178
|
}
|
|
175
179
|
closeModalHandler(event) {
|
|
176
|
-
this.openModals = this.openModals.filter(el => el !== event.detail);
|
|
180
|
+
this.openModals = this.openModals.filter((el) => el !== event.detail);
|
|
177
181
|
}
|
|
178
182
|
componentDidRender() {
|
|
179
183
|
if (!this.limitStylingAppends && this.host) {
|
|
@@ -186,15 +190,9 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
186
190
|
}
|
|
187
191
|
render() {
|
|
188
192
|
const { ProgressToActivate } = this.confirmationData || {};
|
|
189
|
-
return (index.h("div", { key: '
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
translate('joinQuestion', this.language) :
|
|
193
|
-
translate('unJoinQuestion', this.language))), index.h("div", { key: '44614b02fd105bbe4a698460696a7842c85e3c49', slot: "footer", class: 'ManyActions' }, index.h("button", { key: '21b8b45fd8e28625d2ece9124bca65fb5429eb12', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ?
|
|
194
|
-
translate('joinConfirm', this.language) :
|
|
195
|
-
translate('unJoinConfirm', this.language)), index.h("button", { key: 'e01e434afa2e1129c325042a37b1ac76be5a28c7', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": 'TARGET_MODAL' }, index.h("div", { key: '622d587b43206691f4f67b7f13c18f4187560b15', class: 'GradientText' }, ProgressToActivate ?
|
|
196
|
-
translate('joinReject', this.language) :
|
|
197
|
-
translate('unJoinReject', this.language))))), index.h("casino-engagement-suite-modal", { key: '8310ae114d8eefd5d91fb07c5d7cca34c70bffa3', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("SUPPORT_MODAL"), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, index.h("div", { key: 'f6cc0be359c4cdbe0c2a3dd3ff3dbfb0841e65fe', slot: "body" }, index.h("span", { key: 'd4229846b65de554ba68c2c4545e2ac1fcc4fabe' }, translate('contactSupport', this.language))), index.h("div", { key: '55a91614a32feca8f3ea613b2ea27bb0f37145e9', slot: "footer" }, index.h("button", { key: '9ea26fa1b55d7fe1201e460c11ec46e8ea673240', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'SUPPORT_MODAL' }, translate('okContinue', this.language)))), index.h("casino-engagement-suite-modal", { key: 'd4e5b152a9599c3464d2f810dc2795cd482c1a1d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("NO_SPIN_LEFT_MODAL"), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, index.h("div", { key: 'ad796a55fe5078c31a595c0bd98787594cd58bec', slot: "body" }, index.h("div", { key: '256ec7b9f143778c02e33e37a28b0d26c7ae2fa0' }, translate('seeYouLater', this.language))), index.h("div", { key: '0c861dd0e84b81730a3c56338ac38007b19cb70e', slot: "footer" }, index.h("button", { key: '1ecd10f264a158b58a6e7d5db900175dcd36e65d', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'NO_SPIN_LEFT_MODAL' }, "OK")))));
|
|
193
|
+
return (index.h("div", { key: 'b08af5892111b026ea04657bdc9ee8e03349985f', class: `ModalContainer ${this.device}` }, index.h("casino-engagement-suite-modal", { key: '8f3b2f0f739f479311ee70eba23ba300bed9b3b4', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "REWARD_MODAL", "show-animation": true, device: this.device }, index.h("div", { key: '620b3a805aeb6afd1224720ffa46adaeb4ac3313', slot: "body" }, index.h("div", { key: '6897a7914a5b4cdb9c7ff5f4407e38668958a429' }, !this.rewardText && translate('won', this.language), ' ', index.h("span", { key: 'e5b4f13e7d59bcb74de13769c4539251df62b831', class: "ModalReward" }, this.rewardText || this.rewardMessage)), this.hasError && index.h("div", { key: 'c2bc2b252899961f28cb81fbb048073a707105fb', class: "SupportInfo" }, translate('supportInfo', this.language))), index.h("div", { key: 'aa68c9f30956f3170dd432768ad19c95cfda5ea9', slot: "footer" }, index.h("button", { key: '2a0a48a952ccbcd584ca1ace9955d77e37433bab', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "REWARD_MODAL" }, translate('continue', this.language)))), index.h("casino-engagement-suite-modal", { key: '14931f23c32b3aa54ad682e0619fd6025714d611', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('JACKPOT_REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", "show-animation": true, modalType: "JACKPOT_REWARD_MODAL", device: this.device }, index.h("div", { key: 'ed850c670505d0b0c2bd0a27ddab15999e38342a', slot: "body" }, index.h("div", { key: 'cca2417825d0365b3f2c026a3e4cbc51851f393d', class: "JackpotWinText" }, translate('jackpotWin', this.language)), index.h("div", { key: '854c6622f097ac5b37ad4bceeb50a415af826f11', class: "JackpotWinAmount" }, formatBalance(this.winAmount.amount, this.winAmount.currency))), index.h("div", { key: 'd0824ddf47b73fef4dc85a8208d4b4afaf396536', slot: "footer" }, index.h("button", { key: '14c79e18756e2a83eaa865441ad065758533ddf0', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "JACKPOT_REWARD_MODAL" }, translate('continue', this.language)), index.h("div", { key: 'a7da795c5bd9596b7b7b3fd5c4b3024e764df69a', class: "JackpotWinInfoText" }, translate('jackpotWinInfo', this.language)))), index.h("casino-engagement-suite-modal", { key: 'eaff45fdc5b8a7eb280f88705d23e618f43c8723', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('TARGET_MODAL'), header: ProgressToActivate ? translate('joinHeader', this.language) : translate('unJoinHeader', this.language), modalType: "TARGET_MODAL", device: this.device, isLoading: this.isJoiningToChallenge }, index.h("div", { key: 'b6b976ab9ad9a1e620dcb4663b90284c239159f4', slot: "body" }, index.h("div", { key: '8bb1357f8509e26ecc6265b3b6bea7b8791ec307', class: "LeftAlign" }, translate('desc', this.language)), index.h("div", { key: '72cf7f14881769ab9b01728e1560cf4368ad5447', class: "LeftAlignQuestion" }, ProgressToActivate
|
|
194
|
+
? translate('joinQuestion', this.language)
|
|
195
|
+
: translate('unJoinQuestion', this.language))), index.h("div", { key: 'aabc5024f5ba5f3b130f592c6982538e76a63842', slot: "footer", class: "ManyActions" }, index.h("button", { key: 'c51bc6f661ed61557a459d9774f98a27cc3b1ae7', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ? translate('joinConfirm', this.language) : translate('unJoinConfirm', this.language)), index.h("button", { key: '75230bf99e98607427bdd932fd4f52a399b0354d', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": "TARGET_MODAL" }, index.h("div", { key: '756c14df8fbbd4c53a814967e43293301c2f81ec', class: "GradientText" }, ProgressToActivate ? translate('joinReject', this.language) : translate('unJoinReject', this.language))))), index.h("casino-engagement-suite-modal", { key: '496ba508f75434543423cc085514a23914947afe', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('SUPPORT_MODAL'), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, index.h("div", { key: '672c8cd14776e063a2a60f1b15e5aebcd3b7e15d', slot: "body" }, index.h("span", { key: '91cfc35783c2ccd1e5f1bd36aabb1597c8fd8418' }, translate('contactSupport', this.language))), index.h("div", { key: 'f7fdf4c75a43047c2748e07f77aeaf9ad457e64c', slot: "footer" }, index.h("button", { key: '89b73a043587b6f5af54732bc6f3620e3b15fb66', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "SUPPORT_MODAL" }, translate('okContinue', this.language)))), index.h("casino-engagement-suite-modal", { key: '62e009b6c229659c6c93d39963f3e0ee4f00667d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('NO_SPIN_LEFT_MODAL'), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, index.h("div", { key: 'f1877b36eb4ee45c80fcc522291b5679c06e898d', slot: "body" }, index.h("div", { key: '74dc8497679ef79340506e30775ff8568df1d0a9' }, translate('seeYouLater', this.language))), index.h("div", { key: '17b3af15772508b4387f6f9459c8cf63c6149b54', slot: "footer" }, index.h("button", { key: '879442528f93fed31f601e662ac1c1b49fcb7488', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "NO_SPIN_LEFT_MODAL" }, "OK")))));
|
|
198
196
|
}
|
|
199
197
|
get host() { return index.getElement(this); }
|
|
200
198
|
};
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
9
9
|
if (typeof window === 'undefined') return undefined;
|
|
10
10
|
await appGlobals.globalScripts();
|
|
11
|
-
return index.bootstrapLazy([["casino-engagement-suite-modal_2.cjs",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
11
|
+
return index.bootstrapLazy([["casino-engagement-suite-modal_2.cjs",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"rewardText":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
exports.setNonce = index.setNonce;
|
|
@@ -11,7 +11,7 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
11
11
|
this.handleChallengeAttendance = () => {
|
|
12
12
|
window.postMessage({
|
|
13
13
|
type: 'ChallengeJoinRequest',
|
|
14
|
-
data: this.confirmationData
|
|
14
|
+
data: this.confirmationData
|
|
15
15
|
});
|
|
16
16
|
};
|
|
17
17
|
this.setClientStyling = () => {
|
|
@@ -26,14 +26,16 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
26
26
|
.then((res) => res.text())
|
|
27
27
|
.then((data) => {
|
|
28
28
|
cssFile.innerHTML = data;
|
|
29
|
-
setTimeout(() => {
|
|
29
|
+
setTimeout(() => {
|
|
30
|
+
this.host.prepend(cssFile);
|
|
31
|
+
}, 1);
|
|
30
32
|
})
|
|
31
33
|
.catch((err) => {
|
|
32
34
|
console.log('Error ', err);
|
|
33
35
|
});
|
|
34
36
|
};
|
|
35
37
|
this.isModalOpen = (type) => {
|
|
36
|
-
return Boolean(this.openModals.find(el => el === type));
|
|
38
|
+
return Boolean(this.openModals.find((el) => el === type));
|
|
37
39
|
};
|
|
38
40
|
this.clientStyling = '';
|
|
39
41
|
this.clientStylingUrl = '';
|
|
@@ -43,12 +45,13 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
43
45
|
this.limitStylingAppends = false;
|
|
44
46
|
this.openModals = [];
|
|
45
47
|
this.rewardMessage = '';
|
|
48
|
+
this.rewardText = '';
|
|
46
49
|
this.hasError = false;
|
|
47
50
|
this.confirmationData = null;
|
|
48
51
|
this.winAmount = { amount: 0, currency: '' };
|
|
49
52
|
}
|
|
50
53
|
openModalHandler(event) {
|
|
51
|
-
const { modalType, rewardMessage, hasError, confirmationData, winAmount } = event.detail;
|
|
54
|
+
const { modalType, rewardMessage, hasError, confirmationData, winAmount, rewardText } = event.detail;
|
|
52
55
|
if (winAmount) {
|
|
53
56
|
// If jackpot win modal is already opened
|
|
54
57
|
// add won amount to the previous amount
|
|
@@ -61,13 +64,14 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
61
64
|
}
|
|
62
65
|
this.openModals = [...this.openModals, modalType];
|
|
63
66
|
this.rewardMessage = rewardMessage;
|
|
67
|
+
this.rewardText = rewardText;
|
|
64
68
|
this.hasError = hasError;
|
|
65
69
|
if (confirmationData) {
|
|
66
70
|
this.confirmationData = confirmationData;
|
|
67
71
|
}
|
|
68
72
|
}
|
|
69
73
|
closeModalHandler(event) {
|
|
70
|
-
this.openModals = this.openModals.filter(el => el !== event.detail);
|
|
74
|
+
this.openModals = this.openModals.filter((el) => el !== event.detail);
|
|
71
75
|
}
|
|
72
76
|
componentDidRender() {
|
|
73
77
|
if (!this.limitStylingAppends && this.host) {
|
|
@@ -80,15 +84,9 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
80
84
|
}
|
|
81
85
|
render() {
|
|
82
86
|
const { ProgressToActivate } = this.confirmationData || {};
|
|
83
|
-
return (h("div", { key: '
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
translate('joinQuestion', this.language) :
|
|
87
|
-
translate('unJoinQuestion', this.language))), h("div", { key: '44614b02fd105bbe4a698460696a7842c85e3c49', slot: "footer", class: 'ManyActions' }, h("button", { key: '21b8b45fd8e28625d2ece9124bca65fb5429eb12', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ?
|
|
88
|
-
translate('joinConfirm', this.language) :
|
|
89
|
-
translate('unJoinConfirm', this.language)), h("button", { key: 'e01e434afa2e1129c325042a37b1ac76be5a28c7', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": 'TARGET_MODAL' }, h("div", { key: '622d587b43206691f4f67b7f13c18f4187560b15', class: 'GradientText' }, ProgressToActivate ?
|
|
90
|
-
translate('joinReject', this.language) :
|
|
91
|
-
translate('unJoinReject', this.language))))), h("casino-engagement-suite-modal", { key: '8310ae114d8eefd5d91fb07c5d7cca34c70bffa3', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("SUPPORT_MODAL"), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, h("div", { key: 'f6cc0be359c4cdbe0c2a3dd3ff3dbfb0841e65fe', slot: "body" }, h("span", { key: 'd4229846b65de554ba68c2c4545e2ac1fcc4fabe' }, translate('contactSupport', this.language))), h("div", { key: '55a91614a32feca8f3ea613b2ea27bb0f37145e9', slot: "footer" }, h("button", { key: '9ea26fa1b55d7fe1201e460c11ec46e8ea673240', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'SUPPORT_MODAL' }, translate('okContinue', this.language)))), h("casino-engagement-suite-modal", { key: 'd4e5b152a9599c3464d2f810dc2795cd482c1a1d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("NO_SPIN_LEFT_MODAL"), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, h("div", { key: 'ad796a55fe5078c31a595c0bd98787594cd58bec', slot: "body" }, h("div", { key: '256ec7b9f143778c02e33e37a28b0d26c7ae2fa0' }, translate('seeYouLater', this.language))), h("div", { key: '0c861dd0e84b81730a3c56338ac38007b19cb70e', slot: "footer" }, h("button", { key: '1ecd10f264a158b58a6e7d5db900175dcd36e65d', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'NO_SPIN_LEFT_MODAL' }, "OK")))));
|
|
87
|
+
return (h("div", { key: 'b08af5892111b026ea04657bdc9ee8e03349985f', class: `ModalContainer ${this.device}` }, h("casino-engagement-suite-modal", { key: '8f3b2f0f739f479311ee70eba23ba300bed9b3b4', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "REWARD_MODAL", "show-animation": true, device: this.device }, h("div", { key: '620b3a805aeb6afd1224720ffa46adaeb4ac3313', slot: "body" }, h("div", { key: '6897a7914a5b4cdb9c7ff5f4407e38668958a429' }, !this.rewardText && translate('won', this.language), ' ', h("span", { key: 'e5b4f13e7d59bcb74de13769c4539251df62b831', class: "ModalReward" }, this.rewardText || this.rewardMessage)), this.hasError && h("div", { key: 'c2bc2b252899961f28cb81fbb048073a707105fb', class: "SupportInfo" }, translate('supportInfo', this.language))), h("div", { key: 'aa68c9f30956f3170dd432768ad19c95cfda5ea9', slot: "footer" }, h("button", { key: '2a0a48a952ccbcd584ca1ace9955d77e37433bab', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "REWARD_MODAL" }, translate('continue', this.language)))), h("casino-engagement-suite-modal", { key: '14931f23c32b3aa54ad682e0619fd6025714d611', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('JACKPOT_REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", "show-animation": true, modalType: "JACKPOT_REWARD_MODAL", device: this.device }, h("div", { key: 'ed850c670505d0b0c2bd0a27ddab15999e38342a', slot: "body" }, h("div", { key: 'cca2417825d0365b3f2c026a3e4cbc51851f393d', class: "JackpotWinText" }, translate('jackpotWin', this.language)), h("div", { key: '854c6622f097ac5b37ad4bceeb50a415af826f11', class: "JackpotWinAmount" }, formatBalance(this.winAmount.amount, this.winAmount.currency))), h("div", { key: 'd0824ddf47b73fef4dc85a8208d4b4afaf396536', slot: "footer" }, h("button", { key: '14c79e18756e2a83eaa865441ad065758533ddf0', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "JACKPOT_REWARD_MODAL" }, translate('continue', this.language)), h("div", { key: 'a7da795c5bd9596b7b7b3fd5c4b3024e764df69a', class: "JackpotWinInfoText" }, translate('jackpotWinInfo', this.language)))), h("casino-engagement-suite-modal", { key: 'eaff45fdc5b8a7eb280f88705d23e618f43c8723', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('TARGET_MODAL'), header: ProgressToActivate ? translate('joinHeader', this.language) : translate('unJoinHeader', this.language), modalType: "TARGET_MODAL", device: this.device, isLoading: this.isJoiningToChallenge }, h("div", { key: 'b6b976ab9ad9a1e620dcb4663b90284c239159f4', slot: "body" }, h("div", { key: '8bb1357f8509e26ecc6265b3b6bea7b8791ec307', class: "LeftAlign" }, translate('desc', this.language)), h("div", { key: '72cf7f14881769ab9b01728e1560cf4368ad5447', class: "LeftAlignQuestion" }, ProgressToActivate
|
|
88
|
+
? translate('joinQuestion', this.language)
|
|
89
|
+
: translate('unJoinQuestion', this.language))), h("div", { key: 'aabc5024f5ba5f3b130f592c6982538e76a63842', slot: "footer", class: "ManyActions" }, h("button", { key: 'c51bc6f661ed61557a459d9774f98a27cc3b1ae7', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ? translate('joinConfirm', this.language) : translate('unJoinConfirm', this.language)), h("button", { key: '75230bf99e98607427bdd932fd4f52a399b0354d', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": "TARGET_MODAL" }, h("div", { key: '756c14df8fbbd4c53a814967e43293301c2f81ec', class: "GradientText" }, ProgressToActivate ? translate('joinReject', this.language) : translate('unJoinReject', this.language))))), h("casino-engagement-suite-modal", { key: '496ba508f75434543423cc085514a23914947afe', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('SUPPORT_MODAL'), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, h("div", { key: '672c8cd14776e063a2a60f1b15e5aebcd3b7e15d', slot: "body" }, h("span", { key: '91cfc35783c2ccd1e5f1bd36aabb1597c8fd8418' }, translate('contactSupport', this.language))), h("div", { key: 'f7fdf4c75a43047c2748e07f77aeaf9ad457e64c', slot: "footer" }, h("button", { key: '89b73a043587b6f5af54732bc6f3620e3b15fb66', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "SUPPORT_MODAL" }, translate('okContinue', this.language)))), h("casino-engagement-suite-modal", { key: '62e009b6c229659c6c93d39963f3e0ee4f00667d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('NO_SPIN_LEFT_MODAL'), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, h("div", { key: 'f1877b36eb4ee45c80fcc522291b5679c06e898d', slot: "body" }, h("div", { key: '74dc8497679ef79340506e30775ff8568df1d0a9' }, translate('seeYouLater', this.language))), h("div", { key: '17b3af15772508b4387f6f9459c8cf63c6149b54', slot: "footer" }, h("button", { key: '879442528f93fed31f601e662ac1c1b49fcb7488', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "NO_SPIN_LEFT_MODAL" }, "OK")))));
|
|
92
90
|
}
|
|
93
91
|
static get is() { return "casino-engagement-suite-modal-container"; }
|
|
94
92
|
static get encapsulation() { return "shadow"; }
|
|
@@ -200,6 +198,7 @@ export class CasinoEngagementSuiteModalContainer {
|
|
|
200
198
|
"limitStylingAppends": {},
|
|
201
199
|
"openModals": {},
|
|
202
200
|
"rewardMessage": {},
|
|
201
|
+
"rewardText": {},
|
|
203
202
|
"hasError": {},
|
|
204
203
|
"confirmationData": {},
|
|
205
204
|
"winAmount": {}
|
|
@@ -16,5 +16,5 @@ var patchBrowser = () => {
|
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(async (options) => {
|
|
18
18
|
await globalScripts();
|
|
19
|
-
return bootstrapLazy([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
19
|
+
return bootstrapLazy([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"rewardText":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
20
20
|
});
|
|
@@ -113,7 +113,7 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
113
113
|
this.handleChallengeAttendance = () => {
|
|
114
114
|
window.postMessage({
|
|
115
115
|
type: 'ChallengeJoinRequest',
|
|
116
|
-
data: this.confirmationData
|
|
116
|
+
data: this.confirmationData
|
|
117
117
|
});
|
|
118
118
|
};
|
|
119
119
|
this.setClientStyling = () => {
|
|
@@ -128,14 +128,16 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
128
128
|
.then((res) => res.text())
|
|
129
129
|
.then((data) => {
|
|
130
130
|
cssFile.innerHTML = data;
|
|
131
|
-
setTimeout(() => {
|
|
131
|
+
setTimeout(() => {
|
|
132
|
+
this.host.prepend(cssFile);
|
|
133
|
+
}, 1);
|
|
132
134
|
})
|
|
133
135
|
.catch((err) => {
|
|
134
136
|
console.log('Error ', err);
|
|
135
137
|
});
|
|
136
138
|
};
|
|
137
139
|
this.isModalOpen = (type) => {
|
|
138
|
-
return Boolean(this.openModals.find(el => el === type));
|
|
140
|
+
return Boolean(this.openModals.find((el) => el === type));
|
|
139
141
|
};
|
|
140
142
|
this.clientStyling = '';
|
|
141
143
|
this.clientStylingUrl = '';
|
|
@@ -145,12 +147,13 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
145
147
|
this.limitStylingAppends = false;
|
|
146
148
|
this.openModals = [];
|
|
147
149
|
this.rewardMessage = '';
|
|
150
|
+
this.rewardText = '';
|
|
148
151
|
this.hasError = false;
|
|
149
152
|
this.confirmationData = null;
|
|
150
153
|
this.winAmount = { amount: 0, currency: '' };
|
|
151
154
|
}
|
|
152
155
|
openModalHandler(event) {
|
|
153
|
-
const { modalType, rewardMessage, hasError, confirmationData, winAmount } = event.detail;
|
|
156
|
+
const { modalType, rewardMessage, hasError, confirmationData, winAmount, rewardText } = event.detail;
|
|
154
157
|
if (winAmount) {
|
|
155
158
|
// If jackpot win modal is already opened
|
|
156
159
|
// add won amount to the previous amount
|
|
@@ -163,13 +166,14 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
163
166
|
}
|
|
164
167
|
this.openModals = [...this.openModals, modalType];
|
|
165
168
|
this.rewardMessage = rewardMessage;
|
|
169
|
+
this.rewardText = rewardText;
|
|
166
170
|
this.hasError = hasError;
|
|
167
171
|
if (confirmationData) {
|
|
168
172
|
this.confirmationData = confirmationData;
|
|
169
173
|
}
|
|
170
174
|
}
|
|
171
175
|
closeModalHandler(event) {
|
|
172
|
-
this.openModals = this.openModals.filter(el => el !== event.detail);
|
|
176
|
+
this.openModals = this.openModals.filter((el) => el !== event.detail);
|
|
173
177
|
}
|
|
174
178
|
componentDidRender() {
|
|
175
179
|
if (!this.limitStylingAppends && this.host) {
|
|
@@ -182,15 +186,9 @@ const CasinoEngagementSuiteModalContainer = class {
|
|
|
182
186
|
}
|
|
183
187
|
render() {
|
|
184
188
|
const { ProgressToActivate } = this.confirmationData || {};
|
|
185
|
-
return (h("div", { key: '
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
translate('joinQuestion', this.language) :
|
|
189
|
-
translate('unJoinQuestion', this.language))), h("div", { key: '44614b02fd105bbe4a698460696a7842c85e3c49', slot: "footer", class: 'ManyActions' }, h("button", { key: '21b8b45fd8e28625d2ece9124bca65fb5429eb12', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ?
|
|
190
|
-
translate('joinConfirm', this.language) :
|
|
191
|
-
translate('unJoinConfirm', this.language)), h("button", { key: 'e01e434afa2e1129c325042a37b1ac76be5a28c7', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": 'TARGET_MODAL' }, h("div", { key: '622d587b43206691f4f67b7f13c18f4187560b15', class: 'GradientText' }, ProgressToActivate ?
|
|
192
|
-
translate('joinReject', this.language) :
|
|
193
|
-
translate('unJoinReject', this.language))))), h("casino-engagement-suite-modal", { key: '8310ae114d8eefd5d91fb07c5d7cca34c70bffa3', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("SUPPORT_MODAL"), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, h("div", { key: 'f6cc0be359c4cdbe0c2a3dd3ff3dbfb0841e65fe', slot: "body" }, h("span", { key: 'd4229846b65de554ba68c2c4545e2ac1fcc4fabe' }, translate('contactSupport', this.language))), h("div", { key: '55a91614a32feca8f3ea613b2ea27bb0f37145e9', slot: "footer" }, h("button", { key: '9ea26fa1b55d7fe1201e460c11ec46e8ea673240', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'SUPPORT_MODAL' }, translate('okContinue', this.language)))), h("casino-engagement-suite-modal", { key: 'd4e5b152a9599c3464d2f810dc2795cd482c1a1d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen("NO_SPIN_LEFT_MODAL"), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, h("div", { key: 'ad796a55fe5078c31a595c0bd98787594cd58bec', slot: "body" }, h("div", { key: '256ec7b9f143778c02e33e37a28b0d26c7ae2fa0' }, translate('seeYouLater', this.language))), h("div", { key: '0c861dd0e84b81730a3c56338ac38007b19cb70e', slot: "footer" }, h("button", { key: '1ecd10f264a158b58a6e7d5db900175dcd36e65d', class: 'ModalFooterButton', onClick: this.handleCloseClick, "data-type": 'NO_SPIN_LEFT_MODAL' }, "OK")))));
|
|
189
|
+
return (h("div", { key: 'b08af5892111b026ea04657bdc9ee8e03349985f', class: `ModalContainer ${this.device}` }, h("casino-engagement-suite-modal", { key: '8f3b2f0f739f479311ee70eba23ba300bed9b3b4', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "REWARD_MODAL", "show-animation": true, device: this.device }, h("div", { key: '620b3a805aeb6afd1224720ffa46adaeb4ac3313', slot: "body" }, h("div", { key: '6897a7914a5b4cdb9c7ff5f4407e38668958a429' }, !this.rewardText && translate('won', this.language), ' ', h("span", { key: 'e5b4f13e7d59bcb74de13769c4539251df62b831', class: "ModalReward" }, this.rewardText || this.rewardMessage)), this.hasError && h("div", { key: 'c2bc2b252899961f28cb81fbb048073a707105fb', class: "SupportInfo" }, translate('supportInfo', this.language))), h("div", { key: 'aa68c9f30956f3170dd432768ad19c95cfda5ea9', slot: "footer" }, h("button", { key: '2a0a48a952ccbcd584ca1ace9955d77e37433bab', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "REWARD_MODAL" }, translate('continue', this.language)))), h("casino-engagement-suite-modal", { key: '14931f23c32b3aa54ad682e0619fd6025714d611', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('JACKPOT_REWARD_MODAL'), header: "Congratulations!", contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", "show-animation": true, modalType: "JACKPOT_REWARD_MODAL", device: this.device }, h("div", { key: 'ed850c670505d0b0c2bd0a27ddab15999e38342a', slot: "body" }, h("div", { key: 'cca2417825d0365b3f2c026a3e4cbc51851f393d', class: "JackpotWinText" }, translate('jackpotWin', this.language)), h("div", { key: '854c6622f097ac5b37ad4bceeb50a415af826f11', class: "JackpotWinAmount" }, formatBalance(this.winAmount.amount, this.winAmount.currency))), h("div", { key: 'd0824ddf47b73fef4dc85a8208d4b4afaf396536', slot: "footer" }, h("button", { key: '14c79e18756e2a83eaa865441ad065758533ddf0', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "JACKPOT_REWARD_MODAL" }, translate('continue', this.language)), h("div", { key: 'a7da795c5bd9596b7b7b3fd5c4b3024e764df69a', class: "JackpotWinInfoText" }, translate('jackpotWinInfo', this.language)))), h("casino-engagement-suite-modal", { key: 'eaff45fdc5b8a7eb280f88705d23e618f43c8723', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('TARGET_MODAL'), header: ProgressToActivate ? translate('joinHeader', this.language) : translate('unJoinHeader', this.language), modalType: "TARGET_MODAL", device: this.device, isLoading: this.isJoiningToChallenge }, h("div", { key: 'b6b976ab9ad9a1e620dcb4663b90284c239159f4', slot: "body" }, h("div", { key: '8bb1357f8509e26ecc6265b3b6bea7b8791ec307', class: "LeftAlign" }, translate('desc', this.language)), h("div", { key: '72cf7f14881769ab9b01728e1560cf4368ad5447', class: "LeftAlignQuestion" }, ProgressToActivate
|
|
190
|
+
? translate('joinQuestion', this.language)
|
|
191
|
+
: translate('unJoinQuestion', this.language))), h("div", { key: 'aabc5024f5ba5f3b130f592c6982538e76a63842', slot: "footer", class: "ManyActions" }, h("button", { key: 'c51bc6f661ed61557a459d9774f98a27cc3b1ae7', class: `ModalFooterButton ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleChallengeAttendance }, ProgressToActivate ? translate('joinConfirm', this.language) : translate('unJoinConfirm', this.language)), h("button", { key: '75230bf99e98607427bdd932fd4f52a399b0354d', class: `ModalFooterButtonOutlined ${this.isJoiningToChallenge ? 'Disabled' : ''}`, onClick: this.handleCloseClick, "data-type": "TARGET_MODAL" }, h("div", { key: '756c14df8fbbd4c53a814967e43293301c2f81ec', class: "GradientText" }, ProgressToActivate ? translate('joinReject', this.language) : translate('unJoinReject', this.language))))), h("casino-engagement-suite-modal", { key: '496ba508f75434543423cc085514a23914947afe', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('SUPPORT_MODAL'), header: translate('noReward', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/alert.svg", modalType: "SUPPORT_MODAL", device: this.device }, h("div", { key: '672c8cd14776e063a2a60f1b15e5aebcd3b7e15d', slot: "body" }, h("span", { key: '91cfc35783c2ccd1e5f1bd36aabb1597c8fd8418' }, translate('contactSupport', this.language))), h("div", { key: 'f7fdf4c75a43047c2748e07f77aeaf9ad457e64c', slot: "footer" }, h("button", { key: '89b73a043587b6f5af54732bc6f3620e3b15fb66', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "SUPPORT_MODAL" }, translate('okContinue', this.language)))), h("casino-engagement-suite-modal", { key: '62e009b6c229659c6c93d39963f3e0ee4f00667d', clientStylingUrl: this.clientStylingUrl, isOpen: this.isModalOpen('NO_SPIN_LEFT_MODAL'), header: translate('noSpinsLeft', this.language), contentIcon: "https://static.everymatrix.com/gic/img/engagement-suite/cup-reward.svg", modalType: "NO_SPIN_LEFT_MODAL", "show-animation": false, device: this.device }, h("div", { key: 'f1877b36eb4ee45c80fcc522291b5679c06e898d', slot: "body" }, h("div", { key: '74dc8497679ef79340506e30775ff8568df1d0a9' }, translate('seeYouLater', this.language))), h("div", { key: '17b3af15772508b4387f6f9459c8cf63c6149b54', slot: "footer" }, h("button", { key: '879442528f93fed31f601e662ac1c1b49fcb7488', class: "ModalFooterButton", onClick: this.handleCloseClick, "data-type": "NO_SPIN_LEFT_MODAL" }, "OK")))));
|
|
194
192
|
}
|
|
195
193
|
get host() { return getElement(this); }
|
|
196
194
|
};
|
package/dist/esm/loader.js
CHANGED
|
@@ -5,7 +5,7 @@ import { g as globalScripts } from './app-globals-0f993ce5.js';
|
|
|
5
5
|
const defineCustomElements = async (win, options) => {
|
|
6
6
|
if (typeof window === 'undefined') return undefined;
|
|
7
7
|
await globalScripts();
|
|
8
|
-
return bootstrapLazy([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
8
|
+
return bootstrapLazy([["casino-engagement-suite-modal_2",[[1,"casino-engagement-suite-modal-container",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[1],"isJoiningToChallenge":[1028,"is-joining-to-challenge"],"device":[1],"limitStylingAppends":[32],"openModals":[32],"rewardMessage":[32],"rewardText":[32],"hasError":[32],"confirmationData":[32],"winAmount":[32]},[[16,"openModal","openModalHandler"],[16,"closeModal","closeModalHandler"]]],[1,"casino-engagement-suite-modal",{"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"isOpen":[4,"is-open"],"isLoading":[1028,"is-loading"],"header":[1],"contentIcon":[1,"content-icon"],"modalType":[1,"modal-type"],"device":[1],"showAnimation":[4,"show-animation"],"limitStylingAppends":[32]}]]]], options);
|
|
9
9
|
};
|
|
10
10
|
|
|
11
11
|
export { defineCustomElements };
|