@everymatrix/casino-engagement-suite-luckywheel-list 1.70.0 → 1.71.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-luckywheel-list/casino-engagement-suite-luckywheel-list-cfa2521a.js +15 -0
- package/dist/casino-engagement-suite-luckywheel-list/casino-engagement-suite-luckywheel-list_2.entry.js +1 -1
- package/dist/casino-engagement-suite-luckywheel-list/index.esm.js +1 -1
- package/dist/cjs/{casino-engagement-suite-luckywheel-list-cdc073d0.js → casino-engagement-suite-luckywheel-list-8d3dd746.js} +23 -23
- package/dist/cjs/casino-engagement-suite-luckywheel-list_2.cjs.entry.js +1 -1
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/collection/components/casino-engagement-suite-luckywheel-list/casino-engagement-suite-luckywheel-list.js +20 -21
- package/dist/collection/utils/locale.utils.js +3 -2
- package/dist/esm/{casino-engagement-suite-luckywheel-list-a7cd1793.js → casino-engagement-suite-luckywheel-list-cfa2521a.js} +23 -23
- package/dist/esm/casino-engagement-suite-luckywheel-list_2.entry.js +1 -1
- package/dist/esm/index.js +1 -1
- package/package.json +1 -1
- package/dist/casino-engagement-suite-luckywheel-list/casino-engagement-suite-luckywheel-list-a7cd1793.js +0 -15
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/libs/common/src/storybook/storybook-utils.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/packages/stencil/casino-engagement-suite-luckywheel-list/stencil.config.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/packages/stencil/casino-engagement-suite-luckywheel-list/stencil.config.dev.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/packages/stencil/casino-engagement-suite-luckywheel-list/storybook/main.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/packages/stencil/casino-engagement-suite-luckywheel-list/storybook/preview.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/tools/plugins/vite-chunk-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop/Widgets & Template}/widgets-monorepo/packages/stencil/casino-engagement-suite-luckywheel-list/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import{h as t,r as e,c as n,g as i}from"./index-8671bc92.js";
|
|
2
|
+
/*! *****************************************************************************
|
|
3
|
+
Copyright (c) Microsoft Corporation.
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
9
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
10
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
11
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
12
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
13
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
15
|
+
***************************************************************************** */const r=["en"],o={en:{luckywheels:"LuckyWheels",join:"Join",unjoin:"Unjoin",new:"new",noluckywheels:"No Unlocked LuckyWheel",tryOtherGames:"Try winning LuckyWheel as rewards or launching other booster games",tooltip:"Get a chance to win rewards by spinning the wheel!",history:"History",rewards:"Rewards",issued:"Issued",time:"Time",loading:"Loading...",noHistory:"No LuckyWheels’ history available (last 30 days)",freeSpins:"Free Spins",luckyWheel:"LuckyWheel",leaderboard:"Leaderboard",mission:"Mission",canceled:"The luckywheel has been canceled.",support:"Please, contact support."}},s=(t,e)=>{const n=e;return o[void 0!==n&&r.includes(n)?n:"en"][t]};var a,u,l,c={};function d(t){return d="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},d(t)}function h(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function p(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function f(t){p(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===d(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(t){var e=Object.defineProperty,n=Object.defineProperties,i=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,a=(t,n,i)=>n in t?e(t,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[n]=i,u=(t,e)=>{for(var n in e||(e={}))o.call(e,n)&&a(t,n,e[n]);if(r)for(var n of r(e))s.call(e,n)&&a(t,n,e[n]);return t},l=(t,e)=>n(t,i(e)),c=(t,e,n)=>(a(t,"symbol"!=typeof e?e+"":e,n),n);function d(){}function h(t){return t()}function p(){return Object.create(null)}function f(t){t.forEach(h)}function m(t){return"function"==typeof t}function y(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function g(t,e,n){t.insertBefore(e,n||null)}function v(t){t.parentNode&&t.parentNode.removeChild(t)}function w(t){return document.createElement(t)}let b;function x(t){b=t}Object.defineProperty(t,Symbol.toStringTag,{value:"Module"});const L=[],k=[];let W=[];const H=[],E=Promise.resolve();let S=!1;function P(t){W.push(t)}const T=new Set;let M=0;function C(){if(0!==M)return;const t=b;do{try{for(;M<L.length;){const t=L[M];M++,x(t),I(t.$$)}}catch(t){throw L.length=0,M=0,t}for(x(null),L.length=0,M=0;k.length;)k.pop()();for(let t=0;t<W.length;t+=1){const e=W[t];T.has(e)||(T.add(e),e())}W.length=0}while(L.length);for(;H.length;)H.pop()();S=!1,T.clear(),x(t)}function I(t){if(null!==t.fragment){t.update(),f(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(P)}}const D=new Set;function z(t,e,n,i,r,o,s=null,a=[-1]){const u=b;x(t);const l=t.$$={fragment:null,ctx:[],props:o,update:d,not_equal:r,bound:p(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(u?u.$$.context:[])),callbacks:p(),dirty:a,skip_bound:!1,root:e.target||u.$$.root};s&&s(l.root);let c=!1;if(l.ctx=n?n(t,e.props||{},((e,n,...i)=>{const o=i.length?i[0]:n;return l.ctx&&r(l.ctx[e],l.ctx[e]=o)&&(!l.skip_bound&&l.bound[e]&&l.bound[e](o),c&&function(t,e){-1===t.$$.dirty[0]&&(L.push(t),S||(S=!0,E.then(C)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}(t,e)),n})):[],l.update(),c=!0,f(l.before_update),l.fragment=!!i&&i(l.ctx),e.target){if(e.hydrate){const t=function(t){return Array.from(t.childNodes)}(e.target);l.fragment&&l.fragment.l(t),t.forEach(v)}else l.fragment&&l.fragment.c();e.intro&&function(t){t&&t.i&&(D.delete(t),t.i(void 0))}(t.$$.fragment),function(t,e,n){const{fragment:i,after_update:r}=t.$$;i&&i.m(e,n),P((()=>{const e=t.$$.on_mount.map(h).filter(m);t.$$.on_destroy?t.$$.on_destroy.push(...e):f(e),t.$$.on_mount=[]})),r.forEach(P)}(t,e.target,e.anchor),C()}x(u)}let j;function O(t,e,n,i){var r;const o=null==(r=n[t])?void 0:r.type;if(e="Boolean"===o&&"boolean"!=typeof e?null!=e:e,!i||!n[t])return e;if("toAttribute"===i)switch(o){case"Object":case"Array":return null==e?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return null==e?null:e;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":default:return e;case"Number":return null!=e?+e:e}}"function"==typeof HTMLElement&&(j=class extends HTMLElement{constructor(t,e,n){super(),c(this,"$$ctor"),c(this,"$$s"),c(this,"$$c"),c(this,"$$cn",!1),c(this,"$$d",{}),c(this,"$$r",!1),c(this,"$$p_d",{}),c(this,"$$l",{}),c(this,"$$l_u",new Map),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){const n=this.$$c.$on(t,e);this.$$l_u.set(e,n)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){const t=this.$$l_u.get(e);t&&(t(),this.$$l_u.delete(e))}}connectedCallback(){return t=this,e=function*(){if(this.$$cn=!0,!this.$$c){let t=function(t){return()=>{let e;return{c:function(){e=w("slot"),"default"!==t&&function(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}(e,"name",t)},m:function(t,n){g(t,e,n)},d:function(t){t&&v(e)}}}};if(yield Promise.resolve(),!this.$$cn||this.$$c)return;const e={},n=function(t){const e={};return t.childNodes.forEach((t=>{e[t.slot||"default"]=!0})),e}(this);for(const i of this.$$s)i in n&&(e[i]=[t(i)]);for(const t of this.attributes){const e=this.$$g_p(t.name);e in this.$$d||(this.$$d[e]=O(e,t.value,this.$$p_d,"toProp"))}for(const t in this.$$p_d)!(t in this.$$d)&&void 0!==this[t]&&(this.$$d[t]=this[t],delete this[t]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:l(u({},this.$$d),{$$slots:e,$$scope:{ctx:[]}})});const i=()=>{this.$$r=!0;for(const t in this.$$p_d)if(this.$$d[t]=this.$$c.$$.ctx[this.$$c.$$.props[t]],this.$$p_d[t].reflect){const e=O(t,this.$$d[t],this.$$p_d,"toAttribute");null==e?this.removeAttribute(this.$$p_d[t].attribute||t):this.setAttribute(this.$$p_d[t].attribute||t,e)}this.$$r=!1};this.$$c.$$.after_update.push(i),i();for(const t in this.$$l)for(const e of this.$$l[t]){const n=this.$$c.$on(t,e);this.$$l_u.set(e,n)}this.$$l={}}},new Promise(((n,i)=>{var r=t=>{try{s(e.next(t))}catch(t){i(t)}},o=t=>{try{s(e.throw(t))}catch(t){i(t)}},s=t=>t.done?n(t.value):Promise.resolve(t.value).then(r,o);s((e=e.apply(t,null)).next())}));var t,e}attributeChangedCallback(t,e,n){var i;this.$$r||(t=this.$$g_p(t),this.$$d[t]=O(t,n,this.$$p_d,"toProp"),null==(i=this.$$c)||i.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then((()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)}))}$$g_p(t){return Object.keys(this.$$p_d).find((e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t))||t}});class B{constructor(){c(this,"$$"),c(this,"$$set")}$destroy(){(function(t,e){const n=t.$$;null!==n.fragment&&(function(t){const e=[],n=[];W.forEach((i=>-1===t.indexOf(i)?e.push(i):n.push(i))),n.forEach((t=>t())),W=e}(n.after_update),f(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])})(this,1),this.$destroy=d}$on(t,e){if(!m(e))return d;const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){this.$$set&&0!==Object.keys(t).length&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function $(t){!function(t,e,n){const i=function(t){if(!t)return document;const e=t.getRootNode?t.getRootNode():t.ownerDocument;return e&&e.host?e:t.ownerDocument}(t);if(!i.getElementById(e)){const t=w("style");t.id=e,t.textContent=n,function(t,e){!function(t,e){t.appendChild(e)}(t.head||t,e)}(i,t)}}(t,"svelte-gnt082",".LoaderContainer{display:flex;justify-content:center}.lds-ellipsis{display:inline-block;position:relative;width:80px;height:80px}.lds-ellipsis div{position:absolute;top:33px;width:13px;height:13px;border-radius:50%;background:#d1d1d1;animation-timing-function:cubic-bezier(0, 1, 1, 0)}.lds-ellipsis div:nth-child(1){left:8px;animation:lds-ellipsis1 0.6s infinite}.lds-ellipsis div:nth-child(2){left:8px;animation:lds-ellipsis2 0.6s infinite}.lds-ellipsis div:nth-child(3){left:32px;animation:lds-ellipsis2 0.6s infinite}.lds-ellipsis div:nth-child(4){left:56px;animation:lds-ellipsis3 0.6s infinite}@keyframes lds-ellipsis1{0%{transform:scale(0)}100%{transform:scale(1)}}@keyframes lds-ellipsis3{0%{transform:scale(1)}100%{transform:scale(0)}}@keyframes lds-ellipsis2{0%{transform:translate(0, 0)}100%{transform:translate(24px, 0)}}")}function N(t){let e;return{c(){e=w("div"),e.innerHTML='<section class="LoaderContainer"><div class="lds-ellipsis"><div></div><div></div><div></div><div></div></div></section>'},m(n,i){g(n,e,i),t[4](e)},p:d,i:d,o:d,d(n){n&&v(e),t[4](null)}}}function R(t,e,n){let i,{clientstyling:r=""}=e,{clientstylingurl:o=""}=e,{mbsource:s}=e;return function(t){(function(){if(!b)throw new Error("Function called outside component initialization");return b})().$$.on_mount.push(t)}((()=>()=>{})),t.$$set=t=>{"clientstyling"in t&&n(1,r=t.clientstyling),"clientstylingurl"in t&&n(2,o=t.clientstylingurl),"mbsource"in t&&n(3,s=t.mbsource)},t.$$.update=()=>{3&t.$$.dirty&&r&&i&&function(t,e){if(t){const n=document.createElement("style");n.innerHTML=e,t.appendChild(n)}}(i,r),5&t.$$.dirty&&o&&i&&function(t,e){const n=new URL(e);fetch(n.href).then((t=>t.text())).then((e=>{const n=document.createElement("style");n.innerHTML=e,t&&t.appendChild(n)})).catch((t=>{console.error("There was an error while trying to load client styling from URL",t)}))}(i,o),9&t.$$.dirty&&s&&i&&function(t,e){if(window.emMessageBus){const n=document.createElement("style");window.emMessageBus.subscribe(e,(e=>{n.innerHTML=e,t&&t.appendChild(n)}))}}(i,`${s}.Style`)},[i,r,o,s,function(t){k[t?"unshift":"push"]((()=>{i=t,n(0,i)}))}]}"undefined"!=typeof window&&(window.__svelte||(window.__svelte={v:new Set})).v.add("4");class q extends B{constructor(t){super(),z(this,t,R,N,y,{clientstyling:1,clientstylingurl:2,mbsource:3},$)}get clientstyling(){return this.$$.ctx[1]}set clientstyling(t){this.$$set({clientstyling:t}),C()}get clientstylingurl(){return this.$$.ctx[2]}set clientstylingurl(t){this.$$set({clientstylingurl:t}),C()}get mbsource(){return this.$$.ctx[3]}set mbsource(t){this.$$set({mbsource:t}),C()}}!function(t,e,n){let i=class extends j{constructor(){super(t,n,true),this.$$p_d=e}static get observedAttributes(){return Object.keys(e).map((t=>(e[t].attribute||t).toLowerCase()))}};Object.keys(e).forEach((t=>{Object.defineProperty(i.prototype,t,{get(){return this.$$c&&t in this.$$c?this.$$c[t]:this.$$d[t]},set(n){var i;n=O(t,n,e),this.$$d[t]=n,null==(i=this.$$c)||i.$set({[t]:n})}})})),[].forEach((t=>{Object.defineProperty(i.prototype,t,{get(){var e;return null==(e=this.$$c)?void 0:e[t]}})})),t.element=i}(q,{clientstyling:{},clientstylingurl:{},mbsource:{}},[]),t.default=q})(c),"undefined"!=typeof window&&(customElements.define=(l=customElements.define,function(...t){try{return l.apply(this,t)}catch(t){if(t instanceof DOMException&&t.message.includes("has already been used with this registry")||t.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw t}}),Promise.resolve().then((()=>c)).then((({default:t})=>{!customElements.get("general-animation-loading")&&customElements.define("general-animation-loading",t.element)}))),function(t){t[t.FreeSpins=0]="FreeSpins",t[t.LuckyWheel=1]="LuckyWheel",t[t.Leaderboard=2]="Leaderboard",t[t.Challenge=3]="Challenge",t[t.Custom=4]="Custom"}(a||(a={})),function(t){t[t.Completed=0]="Completed",t[t.Expired=1]="Expired",t[t.Forfeited=2]="Forfeited"}(u||(u={}));var m={};function y(){return m}function g(t){p(1,arguments);var e=f(t),n=e.getUTCDay(),i=(n<1?7:0)+n-1;return e.setUTCDate(e.getUTCDate()-i),e.setUTCHours(0,0,0,0),e}function v(t){p(1,arguments);var e=f(t),n=e.getUTCFullYear(),i=new Date(0);i.setUTCFullYear(n+1,0,4),i.setUTCHours(0,0,0,0);var r=g(i),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var s=g(o);return e.getTime()>=r.getTime()?n+1:e.getTime()>=s.getTime()?n:n-1}function w(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=y(),d=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.weekStartsOn)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.weekStartsOn)&&void 0!==r?r:c.weekStartsOn)&&void 0!==i?i:null===(u=c.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==n?n:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var m=f(t),g=m.getUTCDay(),v=(g<d?7:0)+g-d;return m.setUTCDate(m.getUTCDate()-v),m.setUTCHours(0,0,0,0),m}function b(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=f(t),d=c.getUTCFullYear(),m=y(),g=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.firstWeekContainsDate)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==r?r:m.firstWeekContainsDate)&&void 0!==i?i:null===(u=m.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==n?n:1);if(!(g>=1&&g<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var v=new Date(0);v.setUTCFullYear(d+1,0,g),v.setUTCHours(0,0,0,0);var b=w(v,e),x=new Date(0);x.setUTCFullYear(d,0,g),x.setUTCHours(0,0,0,0);var L=w(x,e);return c.getTime()>=b.getTime()?d+1:c.getTime()>=L.getTime()?d:d-1}function x(t,e){for(var n=t<0?"-":"",i=Math.abs(t).toString();i.length<e;)i="0"+i;return n+i}const L=function(t,e){var n=t.getUTCFullYear(),i=n>0?n:1-n;return x("yy"===e?i%100:i,e.length)},k=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):x(n+1,2)},W=function(t,e){return x(t.getUTCDate(),e.length)},H=function(t,e){return x(t.getUTCHours()%12||12,e.length)},E=function(t,e){return x(t.getUTCHours(),e.length)},S=function(t,e){return x(t.getUTCMinutes(),e.length)},P=function(t,e){return x(t.getUTCSeconds(),e.length)},T=function(t,e){var n=e.length,i=t.getUTCMilliseconds();return x(Math.floor(i*Math.pow(10,n-3)),e.length)};var M={G:function(t,e,n){var i=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(i,{width:"abbreviated"});case"GGGGG":return n.era(i,{width:"narrow"});default:return n.era(i,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var i=t.getUTCFullYear();return n.ordinalNumber(i>0?i:1-i,{unit:"year"})}return L(t,e)},Y:function(t,e,n,i){var r=b(t,i),o=r>0?r:1-r;return"YY"===e?x(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):x(o,e.length)},R:function(t,e){return x(v(t),e.length)},u:function(t,e){return x(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(i);case"QQ":return x(i,2);case"Qo":return n.ordinalNumber(i,{unit:"quarter"});case"QQQ":return n.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(i,{width:"narrow",context:"formatting"});default:return n.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,e,n){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(i);case"qq":return x(i,2);case"qo":return n.ordinalNumber(i,{unit:"quarter"});case"qqq":return n.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(i,{width:"narrow",context:"standalone"});default:return n.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,e,n){var i=t.getUTCMonth();switch(e){case"M":case"MM":return k(t,e);case"Mo":return n.ordinalNumber(i+1,{unit:"month"});case"MMM":return n.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(i,{width:"narrow",context:"formatting"});default:return n.month(i,{width:"wide",context:"formatting"})}},L:function(t,e,n){var i=t.getUTCMonth();switch(e){case"L":return String(i+1);case"LL":return x(i+1,2);case"Lo":return n.ordinalNumber(i+1,{unit:"month"});case"LLL":return n.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(i,{width:"narrow",context:"standalone"});default:return n.month(i,{width:"wide",context:"standalone"})}},w:function(t,e,n,i){var r=function(t,e){p(1,arguments);var n=f(t),i=w(n,e).getTime()-function(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=y(),d=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.firstWeekContainsDate)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==r?r:c.firstWeekContainsDate)&&void 0!==i?i:null===(u=c.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==n?n:1),f=b(t,e),m=new Date(0);return m.setUTCFullYear(f,0,d),m.setUTCHours(0,0,0,0),w(m,e)}(n,e).getTime();return Math.round(i/6048e5)+1}(t,i);return"wo"===e?n.ordinalNumber(r,{unit:"week"}):x(r,e.length)},I:function(t,e,n){var i=function(t){p(1,arguments);var e=f(t),n=g(e).getTime()-function(t){p(1,arguments);var e=v(t),n=new Date(0);return n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0),g(n)}(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(i,{unit:"week"}):x(i,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):W(t,e)},D:function(t,e,n){var i=function(t){p(1,arguments);var e=f(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var i=e.getTime();return Math.floor((n-i)/864e5)+1}(t);return"Do"===e?n.ordinalNumber(i,{unit:"dayOfYear"}):x(i,e.length)},E:function(t,e,n){var i=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(i,{width:"short",context:"formatting"});default:return n.day(i,{width:"wide",context:"formatting"})}},e:function(t,e,n,i){var r=t.getUTCDay(),o=(r-i.weekStartsOn+8)%7||7;switch(e){case"e":return String(o);case"ee":return x(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},c:function(t,e,n,i){var r=t.getUTCDay(),o=(r-i.weekStartsOn+8)%7||7;switch(e){case"c":return String(o);case"cc":return x(o,e.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(r,{width:"narrow",context:"standalone"});case"cccccc":return n.day(r,{width:"short",context:"standalone"});default:return n.day(r,{width:"wide",context:"standalone"})}},i:function(t,e,n){var i=t.getUTCDay(),r=0===i?7:i;switch(e){case"i":return String(r);case"ii":return x(r,e.length);case"io":return n.ordinalNumber(r,{unit:"day"});case"iii":return n.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(i,{width:"short",context:"formatting"});default:return n.day(i,{width:"wide",context:"formatting"})}},a:function(t,e,n){var i=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,n){var i,r=t.getUTCHours();switch(i=12===r?"noon":0===r?"midnight":r/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(t,e,n){var i,r=t.getUTCHours();switch(i=r>=17?"evening":r>=12?"afternoon":r>=4?"morning":"night",e){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var i=t.getUTCHours()%12;return 0===i&&(i=12),n.ordinalNumber(i,{unit:"hour"})}return H(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E(t,e)},K:function(t,e,n){var i=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(i,{unit:"hour"}):x(i,e.length)},k:function(t,e,n){var i=t.getUTCHours();return 0===i&&(i=24),"ko"===e?n.ordinalNumber(i,{unit:"hour"}):x(i,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):S(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):P(t,e)},S:function(t,e){return T(t,e)},X:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();if(0===r)return"Z";switch(e){case"X":return I(r);case"XXXX":case"XX":return D(r);default:return D(r,":")}},x:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"x":return I(r);case"xxxx":case"xx":return D(r);default:return D(r,":")}},O:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+C(r,":");default:return"GMT"+D(r,":")}},z:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+C(r,":");default:return"GMT"+D(r,":")}},t:function(t,e,n,i){return x(Math.floor((i._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,n,i){return x((i._originalDate||t).getTime(),e.length)}};function C(t,e){var n=t>0?"-":"+",i=Math.abs(t),r=Math.floor(i/60),o=i%60;if(0===o)return n+String(r);var s=e||"";return n+String(r)+s+x(o,2)}function I(t,e){return t%60==0?(t>0?"-":"+")+x(Math.abs(t)/60,2):D(t,e)}function D(t,e){var n=e||"",i=t>0?"-":"+",r=Math.abs(t);return i+x(Math.floor(r/60),2)+n+x(r%60,2)}const z=M;var j=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},O=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},B={p:O,P:function(t,e){var n,i=t.match(/(P+)(p+)?/)||[],r=i[1],o=i[2];if(!o)return j(t,e);switch(r){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;default:n=e.dateTime({width:"full"})}return n.replace("{{date}}",j(r,e)).replace("{{time}}",O(o,e))}};const $=B;var N=["D","DD"],R=["YY","YYYY"];function q(t,e,n){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Y={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function A(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.width?String(e.width):t.defaultWidth;return t.formats[n]||t.formats[t.defaultWidth]}}var G,Q={date:A({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:A({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:A({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},F={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function X(t){return function(e,n){var i;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var r=t.defaultFormattingWidth||t.defaultWidth,o=null!=n&&n.width?String(n.width):r;i=t.formattingValues[o]||t.formattingValues[r]}else{var s=t.defaultWidth,a=null!=n&&n.width?String(n.width):t.defaultWidth;i=t.values[a]||t.values[s]}return i[t.argumentCallback?t.argumentCallback(e):e]}}function J(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.width,r=e.match(i&&t.matchPatterns[i]||t.matchPatterns[t.defaultMatchWidth]);if(!r)return null;var o,s=r[0],a=i&&t.parsePatterns[i]||t.parsePatterns[t.defaultParseWidth],u=Array.isArray(a)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(s))return e}(a):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(s))return e}(a);return o=t.valueCallback?t.valueCallback(u):u,{value:o=n.valueCallback?n.valueCallback(o):o,rest:e.slice(s.length)}}}const _={code:"en-US",formatDistance:function(t,e,n){var i,r=Y[t];return i="string"==typeof r?r:1===e?r.one:r.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+i:i+" ago":i},formatLong:Q,formatRelative:function(t){return F[t]},localize:{ordinalNumber:function(t){var e=Number(t),n=e%100;if(n>20||n<10)switch(n%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:X({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:X({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:X({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:X({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:X({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(G={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.match(G.matchPattern);if(!n)return null;var i=n[0],r=t.match(G.parsePattern);if(!r)return null;var o=G.valueCallback?G.valueCallback(r[0]):r[0];return{value:o=e.valueCallback?e.valueCallback(o):o,rest:t.slice(i.length)}}),era:J({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:J({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:J({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:J({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:J({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};var U=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,K=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Z=/^'([^]*?)'?$/,V=/''/g,tt=/[a-zA-Z]/;function et(t,e,n){var i,r,o,s,a,u,l,c,m,g,v,w,b,x,L,k,W,H;p(2,arguments);var E=String(e),S=y(),P=null!==(i=null!==(r=null==n?void 0:n.locale)&&void 0!==r?r:S.locale)&&void 0!==i?i:_,T=h(null!==(o=null!==(s=null!==(a=null!==(u=null==n?void 0:n.firstWeekContainsDate)&&void 0!==u?u:null==n||null===(l=n.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==a?a:S.firstWeekContainsDate)&&void 0!==s?s:null===(m=S.locale)||void 0===m||null===(g=m.options)||void 0===g?void 0:g.firstWeekContainsDate)&&void 0!==o?o:1);if(!(T>=1&&T<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var M=h(null!==(v=null!==(w=null!==(b=null!==(x=null==n?void 0:n.weekStartsOn)&&void 0!==x?x:null==n||null===(L=n.locale)||void 0===L||null===(k=L.options)||void 0===k?void 0:k.weekStartsOn)&&void 0!==b?b:S.weekStartsOn)&&void 0!==w?w:null===(W=S.locale)||void 0===W||null===(H=W.options)||void 0===H?void 0:H.weekStartsOn)&&void 0!==v?v:0);if(!(M>=0&&M<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!P.localize)throw new RangeError("locale must contain localize property");if(!P.formatLong)throw new RangeError("locale must contain formatLong property");var C=f(t);if(!function(t){if(p(1,arguments),!function(t){return p(1,arguments),t instanceof Date||"object"===d(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=f(t);return!isNaN(Number(e))}(C))throw new RangeError("Invalid time value");var I=function(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}(C),D=function(t,e){return p(2,arguments),function(t,e){p(2,arguments);var n=f(t).getTime(),i=h(e);return new Date(n+i)}(t,-h(e))}(C,I),j={firstWeekContainsDate:T,weekStartsOn:M,locale:P,_originalDate:C};return E.match(K).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,$[e])(t,P.formatLong):t})).join("").match(U).map((function(i){if("''"===i)return"'";var r,o,s=i[0];if("'"===s)return(o=(r=i).match(Z))?o[1].replace(V,"'"):r;var a=z[s];if(a)return null!=n&&n.useAdditionalWeekYearTokens||-1===R.indexOf(i)||q(i,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!(-1!==N.indexOf(i))||q(i,e,String(t)),a(D,i,P.localize,j);if(s.match(tt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+s+"`");return i})).join("")}const nt=class{constructor(t){e(this,t),this.close=n(this,"close",7),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.tooltip=!1},this.handleLuckyWheelClick=t=>{const e=t.currentTarget.getAttribute("data-id"),n=t.currentTarget.getAttribute("data-index");window.postMessage({type:"LuckyWheelClick",id:e,index:n})},this.showTooltip=()=>{this.tooltip=!0},this.hideTooltip=()=>{this.tooltip=!1},this.handleTabChange=t=>{this.activeTab=+t.target.getAttribute("data-index"),2===this.activeTab&&this.sendHistoryRequest()},this.toggleLuckyWheelHistory=t=>{const e=t.currentTarget.getAttribute("data-id");this.openedHistoryIds.findIndex((t=>t===e))>-1?this.openedHistoryIds=this.openedHistoryIds.filter((t=>t!==e)):this.openedHistoryIds.push(e),this.openedHistoryIds=[...this.openedHistoryIds]},this.clientStyling="",this.clientStylingUrl="",this.language="en",this.device="Mobile",this.luckyWheels=[],this.translationUrl="",this.tooltip=!1,this.timers={},this.limitStylingAppends=!1,this.activeTab=1,this.historyLoading=!1,this.luckywheelHistory={},this.openedHistoryIds=[],this.historyLoaded=!1,this.isLoading=!1}handleEvent(t){var e;const n=null==t?void 0:t.data,{type:i}=n,r=function(t,e){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.indexOf(i)<0&&(n[i]=t[i]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(t);r<i.length;r++)e.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(t,i[r])&&(n[i[r]]=t[i[r]])}return n}(n,["type"]);if("BarLuckyWheelsClick"===i&&(this.activeTab=1,this.openedHistoryIds=[]),"LuckywheelHistoryResponse"===i){this.openedHistoryIds=[];const t=r.data;if(t.length>0){const n=null===(e=t[0].Draw)||void 0===e?void 0:e.LotteryProgramID;this.luckywheelHistory[n]=t}this.historyLoading=!1}}luckywheelsPropHandler(t){!this.interval&&t.length&&(this.updateTimers(),this.startCountdown()),this.interval&&!t.length&&clearInterval(this.interval)}async componentWillLoad(){var t;this.luckywheelsPropHandler(this.luckyWheels),this.translationUrl&&await(t=this.translationUrl,new Promise(((e,n)=>{fetch(t).then((t=>t.json())).then((t=>{Object.keys(t).forEach((e=>{for(let n in t[e])o[e][n]=t[e][n]})),e(o)})).catch((t=>{n(t)}))})))}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}disconnectedCallback(){this.interval&&clearInterval(this.interval)}startCountdown(){this.interval=setInterval((()=>{this.updateTimers()}),1e3)}updateTimers(){const t=(new Date).getTime();this.timers=this.luckyWheels.reduce(((e,n)=>{var i,r;const o=(null===(i=n.Current)||void 0===i?void 0:i.ExpiryTime)||(null===(r=n.Program)||void 0===r?void 0:r.Time),s=new Date(o).getTime()-t;let a="00h:00m:00s";if(s<1)this.removeLuckyWheel(n.Program.Id);else{const{days:t,hours:e,minutes:n,seconds:i}={days:String(Math.floor(s/864e5)).padStart(2,"0"),hours:String(Math.floor(s%864e5/36e5)).padStart(2,"0"),minutes:String(Math.floor(s%36e5/6e4)).padStart(2,"0"),seconds:String(Math.floor(s%6e4/1e3)).padStart(2,"0")};a="00"===t?`${e}h:${n}m:${i}s`:`${t}d:${e}h:${n}m`}return Object.assign(Object.assign({},e),{[n.Program.Id]:a})}),{})}removeLuckyWheel(t){this.luckyWheels=this.luckyWheels.filter((e=>e.Program.Id!==t)),window.postMessage({type:"LuckyWheelHasExpired",id:t})}sendHistoryRequest(){this.historyLoading=!0,this.luckyWheels.forEach((t=>{window.postMessage({type:"LuckywheelHistoryRequest",data:{lotteryProgramID:t.Program.Id}})}))}getLuckyWheelClasses(t){return{LuckyWheelsCard:!0,LuckyWheelsEmptyNumber:0===t.Current.RemainingTimes}}getLuckyWheelName(t){var e,n;return(null===(e=t.Program)||void 0===e?void 0:e.Name.en)||(null===(n=t.Program)||void 0===n?void 0:n.Name["*"])}getLuckyWheelHeaderTemplate(e){var n,i;return t("div",{class:"LuckyWheelsCardHeader"},t("div",{class:"LuckyWheelsName"},this.getLuckyWheelName(e)),t("div",{class:"LuckyWheelsCounter"},t("div",{class:(null===(n=e.Current)||void 0===n?void 0:n.RemainingTimes)?"LuckyWheelsHighlightedCounter":"LuckyWheelsEmptyCounter"},null===(i=e.Current)||void 0===i?void 0:i.RemainingTimes)))}getLuckyWheelTemplate(e,n){const i=this.timers[e.Program.Id];return t("div",{class:this.getLuckyWheelClasses(e),onClick:this.handleLuckyWheelClick,key:e.Program.Id,"data-id":e.Program.Id,"data-index":n},this.getLuckyWheelHeaderTemplate(e),t("div",{class:"LuckyWheelsCountdownWrapper"},t("span",{class:"LuckyWheelsCountdown"},i)))}getHeaderTemplate(){return t("header",{class:"LuckyWheelsListPopupHeader"},t("button",{onClick:this.showTooltip,class:"EngagementSuiteIconButton Help"}),t("div",{class:"LuckyWheelsListPopupHeaderName"},s("luckyWheel",this.language)),t("button",{class:"EngagementSuiteIconButton Close",onClick:this.handleCloseClick}))}getListTemplate(){return this.isLoading?t("general-animation-loading",null):this.luckyWheels.length?t("div",{class:"LuckyWheelsListWrapper"},t("div",{class:"LuckyWheelsList"},this.luckyWheels.map(((t,e)=>this.getLuckyWheelTemplate(t,e))))):t("div",{class:"LuckyWheelsListEmpty"},t("h2",null,s("noluckywheels",this.language)),t("p",null,s("tryOtherGames",this.language)))}getTooltipTemplate(){return this.tooltip?t("div",{class:"EngagementSuiteTooltipBackdrop"},t("div",{class:"EngagementSuiteTooltip"},t("button",{class:"EngagementSuiteIconButton Close",onClick:this.hideTooltip}),s("tooltip",this.language))):""}getTabsTemplate(){return t("div",{class:"EngagementSuiteTabsWrapper"},t("div",{class:"EngagementSuiteTabs"},t("div",{"data-index":"1",onClick:this.handleTabChange,class:"EngagementSuiteTab "+(1===this.activeTab?"Active":"")},s("luckywheels",this.language)),t("div",{"data-index":"2",onClick:this.handleTabChange,class:"EngagementSuiteTab "+(2===this.activeTab?"Active":"")},s("history",this.language))))}getHistoryTabTemplate(){return t("div",{class:"HistoryWrapper"},t("div",{class:"HistoryCols"},t("div",{class:"HistoryColName Rewards"},s("rewards",this.language)),t("div",{class:"HistoryColName Issued"},s("issued",this.language)),t("div",{class:"HistoryColName Time"},s("time",this.language))),this.historyLoading?(e=this.language,t("div",{class:"HistoryLoader"},t("casino-engagement-suite-progress-bar",{indeterminate:!0}),t("span",null,s("loading",e)))):((e,n,i,r,o)=>0===e.length?t("p",{class:"HistoryEmptyMessage"},s("noHistory",o)):t("div",{class:"HistoryList"},e.map((e=>{var o;return t("div",{key:e.Program.Id,class:"HistoryListItem "+(i.includes(e.Program.Id)?"Opened":"Closed")},t("header",{class:"HistoryListItemHeader","data-id":e.Program.Id,onClick:r},e.Program.Name.en||e.Program.Name["*"],t("button",{class:"EngagementSuiteIconButton ArrowDown"})),t("div",{class:"HistoryListItemBody"},t("div",{class:"HistoryInfoRow"},null===(o=n[e.Program.Id])||void 0===o?void 0:o.map((n=>t("div",{class:"HistoryInfo"},t("div",{class:"HistoryCol Rewards"},((e,n)=>{var i,r,o,s;const a=n.WheelOfFortunePartitionIndex||0,u=null===(r=null===(i=e.Program.WheelOfFortune)||void 0===i?void 0:i.Partitions[a])||void 0===r?void 0:r.Name,l=null===(s=null===(o=e.Program.WheelOfFortune)||void 0===o?void 0:o.Partitions[a])||void 0===s?void 0:s.Image1,c=l.en||l["*"],d=e.Program.Name.en||e.Program.Name["*"];return t("div",{class:"HistoryRewards"},u.en||u["*"]||(c?t("img",{src:c}):d))})(e,n.Draw.Result)),t("div",{class:"HistoryCol Issued"},"fulfilled"===n.Draw.State?"Success":"Failed"),t("div",{class:"HistoryCol Time"},et(new Date(n.Draw.Time),"LLL d, yyyy HH:mm:ss"))))))))}))))(this.luckyWheels,this.luckywheelHistory,this.openedHistoryIds,this.toggleLuckyWheelHistory,this.language));var e}getTabsContentTemplate(){return 1===this.activeTab?this.getListTemplate():this.getHistoryTabTemplate()}render(){return t("div",{key:"0286500986b71786315f4b0d4860e6bf0069fa0e",class:`LuckyWheelsListPopup ${this.device}`},this.getHeaderTemplate(),this.getTabsTemplate(),this.getTabsContentTemplate(),this.getTooltipTemplate())}get host(){return i(this)}static get watchers(){return{luckyWheels:["luckywheelsPropHandler"]}}};nt.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer}button:focus{outline:none}.EngagementSuiteIconButton{width:16px;height:16px}.EngagementSuiteIconButton.Help{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/help.svg) no-repeat}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.EngagementSuiteIconButton.ArrowDown{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/arrow-down.svg) no-repeat}.LuckyWheelsListPopup{display:flex;height:100%;background-color:var(--emw--color-background, #1e1638);border-radius:var(--emw--border-radius-large, 8px);overflow:hidden;flex-direction:column;position:relative;padding-bottom:20px}.LuckyWheelsListPopupHeader{display:flex;justify-content:space-between;align-items:center;padding:12px 8px 8px}.LuckyWheelsListPopupHeaderName{color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-small, 14px);font-weight:var(--emw--font-weight-medium, 500);line-height:14px}.LuckyWheelsListWrapper{overflow-y:auto;-ms-overflow-style:none;scrollbar-width:none}.LuckyWheelsListWrapper::-webkit-scrollbar{display:none}.LuckyWheelsList{display:flex;flex-direction:column;row-gap:12px;padding:8px 19px 0}.LuckyWheelsRowWrapper{display:flex;justify-content:space-between;min-width:0}.LuckyWheelsCard{padding:15px 15px 19px;border:1px solid var(--emw--button-border-color, #403956);border-radius:var(--emw--border-radius-medium, 6px);position:relative;cursor:pointer}.LuckyWheelsCard.Forfeited{cursor:auto;pointer-events:none}.LuckyWheelsCardHeader{display:flex;justify-content:space-between;gap:24px;margin-bottom:12px;flex:1;min-width:0;align-items:flex-end}.LuckyWheelsName{color:var(--emw--color-typography, #ffffff);font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);line-height:22px;font-weight:var(--emw--font-weight-bold, 700);font-size:var(--emw--font-size-medium-plus, 18px);word-break:break-word;flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.LuckyWheelsCounter{display:flex;color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-medium-plus, 18px);align-items:flex-end}.LuckyWheelsHighlightedCounter,.LuckyWheelsEmptyCounter{font-size:var(--emw--font-size-medium-plus, 18px);font-weight:var(--emw--font-weight-extra-bold, 800);margin-right:4px}.LuckyWheelsHighlightedCounter{background:var(--emw--engagement-suite-gradient-golden, linear-gradient(180deg, #ffb801 15.86%, #fef746 31.36%, #fbffe0 36.86%, #fffa60 47.86%, #ff9400 87.36%));-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.LuckyWheelsEmptyCounter{color:var(--emw--color-gray-150, #8f8b9c)}.LuckyWheelsListEmpty{padding:20px 32px}.LuckyWheelsListEmpty h2{margin:0 0 16px 0;text-align:center;font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large, 20px);line-height:24px;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);color:var(--emw--color-typography, #ffffff)}.LuckyWheelsListEmpty p{font-size:var(--emw--font-size-small, 14px);line-height:17px;color:var(--emw--color-secondary, #bbb9c3)}.LuckyWheelsCountdownWrapper{display:flex;justify-content:space-between;align-items:flex-start}.LuckyWheelsCountdown,.ForfeitedMessage{color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-x-small, 12px);line-height:12px}.ForfeitedMessage{line-height:1.2}.LuckyWheelsBalCounter{display:flex;align-items:flex-end;color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-x-small, 12px)}.LuckyWheelsRemainCounter{color:var(--emw--color-typography, #ffffff);font-weight:var(--emw--font-weight-bold, 700);margin-right:4px}.LuckyWheelLabel{min-width:35px;height:18px;background:var(--emw--engagement-suite-gradient-golden, linear-gradient(180deg, #ffb801 15.86%, #fef746 31.36%, #fbffe0 36.86%, #fffa60 47.86%, #ff9400 87.36%));border-radius:var(--emw--border-radius-x-small, 2px);display:none;position:absolute;top:-11px;right:11px;padding:0 2px;align-items:center;justify-content:center}.LuckyWheelLabel span{display:inline-block;text-transform:uppercase;font-size:var(--emw--font-size-2x-small, 10px);line-height:10px;font-weight:var(--emw--font-weight-bold, 700);font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);color:var(--emw--color-background, #1e1638)}.ShowLuckyWheelLabel{display:inline-flex}.EngagementSuiteTooltipBackdrop{padding:48px 30px 0;position:absolute;width:100%;height:100%;inset:0;background-color:rgba(0, 0, 0, 0.5)}.EngagementSuiteTooltipBackdrop .EngagementSuiteTooltip{border:1px solid var(--emw--button-border-color, #403956);background-color:var(--emw--color-background, #1e1638);border-radius:var(--emw--border-radius-large, 8px);padding:32px;font-size:var(--emw--font-size-small, 14px);line-height:17px;color:var(--emw--color-secondary, #bbb9c3);position:relative}.EngagementSuiteTooltipBackdrop .EngagementSuiteTooltip .EngagementSuiteIconButton{top:12px;right:12px;position:absolute}.LuckyWheelsEmptyNumber .LuckyWheelsName,.LuckyWheelsEmptyNumber .LuckyWheelsCountdown,.LuckyWheelsEmptyNumber .LuckyWheelsRemainCounter{color:var(--emw--color-gray-150, #8f8b9c)}.LuckyWheelsListPopup.Tablet .LuckyWheelsListPopupHeader,.LuckyWheelsListPopup.Desktop .LuckyWheelsListPopupHeader{padding-top:16px}.LuckyWheelsListPopup.Tablet .LuckyWheelsListPopupHeaderName,.LuckyWheelsListPopup.Desktop .LuckyWheelsListPopupHeaderName{font-size:var(--emw--font-size-medium, 16px);line-height:16px}.LuckyWheelsListPopup.Tablet .EngagementSuiteIconButton,.LuckyWheelsListPopup.Desktop .EngagementSuiteIconButton{width:24px;height:24px}.LuckyWheelsListPopup.Tablet .LuckyWheelsList,.LuckyWheelsListPopup.Desktop .LuckyWheelsList{padding:20px 24px 0;row-gap:20px}.LuckyWheelsListPopup.Tablet .LuckyWheelCardHeader,.LuckyWheelsListPopup.Desktop .LuckyWheelCardHeader{margin-bottom:16px}.LuckyWheelsListPopup.Tablet .LuckyWheelsName,.LuckyWheelsListPopup.Desktop .LuckyWheelsName{line-height:27px;font-size:var(--emw--font-size-large, 22px)}.LuckyWheelsListPopup.Tablet .LuckyWheelsCountdown,.LuckyWheelsListPopup.Desktop .LuckyWheelsCountdown{font-size:var(--emw--font-size-small, 14px);line-height:14px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltipBackdrop,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltipBackdrop{padding:90px 75px 0}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltip,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltip{padding:60px 65px;font-size:var(--emw--font-size-medium, 16px);line-height:20px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltip .EngagementSuiteIconButton,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltip .EngagementSuiteIconButton{top:24px;right:24px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab,.LuckyWheelsListPopup.Desktop .EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols .Rewards,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols .Rewards{flex-basis:140px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols .Issued,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols .Issued{flex-basis:100px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryListItemHeader,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryListItemHeader{font-size:var(--emw--font-size-large, 22px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo .Rewards,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo .Rewards{flex-basis:140px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo .Issued,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo .Issued{flex-basis:100px}.EngagementSuiteTabsWrapper{padding:0 24px;margin:8px 0}.EngagementSuiteTabsWrapper .EngagementSuiteTabs{display:flex;position:relative;border-bottom:2px solid var(--emw--color-secondary, #666178)}.EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab{padding:9px 16px 7px;font-weight:var(--emw--font-weight-medium, 500);font-size:var(--emw--font-size-x-small, 12px);line-height:15px;color:var(--emw--color-gray-300, #666178);cursor:pointer}.EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab.Active{color:var(--emw--color-typography, #fff);border-bottom:2px solid var(--emw--color-typography, #fff);margin-bottom:-2px}.HistoryWrapper{padding:0 24px;display:flex;flex-direction:column;height:100%;overflow:hidden}.HistoryWrapper .HistoryEmptyMessage{margin-top:8px;font-size:var(--emw--font-size-small, 14px);color:var(--emw--color-secondary, #bbb9c3);line-height:30px}.HistoryWrapper .HistoryCols{padding:12px 10px;position:relative;display:flex;border-bottom:1px solid var(--emw--color-secondary, #666178);font-size:var(--emw--font-size-x-small, 12px)}.HistoryWrapper .HistoryCols .HistoryColName{color:var(--emw--color-secondary, #bbb9c3)}.HistoryWrapper .HistoryCols .Rewards{flex-basis:80px}.HistoryWrapper .HistoryCols .Issued{flex-basis:80px}.HistoryWrapper .HistoryLoader{display:flex;flex-direction:column;justify-content:center;align-items:center;height:inherit;font-size:var(--emw--font-size-medium, 16px);color:var(--emw--color-gray-150, #8f8b9c)}.HistoryWrapper .HistoryLoader casino-engagement-suite-progress-bar{margin-bottom:8px;width:100px}.HistoryWrapper .HistoryListItem{max-height:300px;overflow:auto;margin-top:8px}.HistoryWrapper .HistoryListItem.Opened .EngagementSuiteIconButton.ArrowDown{transform:rotate(180deg)}.HistoryWrapper .HistoryListItem.Opened .HistoryListItemBody{padding-bottom:8px;grid-template-rows:1fr;border-bottom:1px solid var(--emw--color-secondary, #666178)}.HistoryWrapper .HistoryListItem .HistoryListItemHeader{padding:16px 0;display:flex;justify-content:space-between;align-items:center;color:var(--emw--color-typography, #ffffff);font-size:var(--emw--font-size-medium, 14px)}.HistoryWrapper .HistoryListItem .EngagementSuiteIconButton.ArrowDown{transition:transform 0.3s ease-out;width:24px;height:24px}.HistoryWrapper .HistoryListItem .HistoryListItemBody{position:relative;display:grid;grid-template-rows:0fr;transition:grid-template-rows 0.3s ease-out}.HistoryWrapper .HistoryListItem .HistoryListItemBody>div{overflow:hidden}.HistoryWrapper .HistoryListItem .HistoryListItemCard{padding:12px 5px}.HistoryWrapper .HistoryListItem .HistoryInfoRow{display:flex;gap:10px;flex-direction:column}.HistoryWrapper .HistoryListItem .HistoryInfo{display:flex;padding:10px;font-size:var(--emw--font-size-x-small, 12px);color:var(--emw--color-secondary, #bbb9c3)}.HistoryWrapper .HistoryListItem .HistoryInfo .HistoryCol{text-overflow:ellipsis;overflow:hidden}.HistoryWrapper .HistoryListItem .HistoryInfo .Rewards{color:var(--emw--color-typography, #ffffff);flex-basis:80px;font-weight:600}.HistoryWrapper .HistoryListItem .HistoryInfo .Issued{flex-basis:80px}';export{nt as C}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{C as casino_engagement_suite_luckywheel_list}from"./casino-engagement-suite-luckywheel-list-
|
|
1
|
+
export{C as casino_engagement_suite_luckywheel_list}from"./casino-engagement-suite-luckywheel-list-cfa2521a.js";import{r as e,h as r,g as s}from"./index-8671bc92.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:var(--emw--font-size-small, 14px);line-height:14px}@keyframes indeterminate{0%{left:-200%;right:100%}60%{left:110%;right:-10%}to{left:110%;right:-10%}}.ProgressBarBackground{height:8px;background-color:var(--emw--color-gray-300, #666178);border-radius:var(--emw--border-radius-small, 4px);position:relative;overflow:hidden}.ProgressBarLine{position:absolute;left:0;top:0;bottom:0;border-radius:var(--emw--border-radius-small, 4px);background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));transition:width ease-out 0.3s}.ProgressBarLine.Indeterminate{animation:indeterminate 1s linear infinite}.ProgressBarInfo{margin-bottom:8px;display:flex;justify-content:space-between;align-items:center}.ProgressBarPercent{font-weight:var(--emw--font-weight-bold, 700);font-size:var(--emw--font-size-x-small, 12px);line-height:12px}.HidePercent .ProgressBarPercent{display:none}.ProgressBar:not(.Disabled) .ProgressBarPercent{background:var(--emw--engagement-suite-gradient-button, 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-gray-300, #666178)}.ProgressBar.Disabled .ProgressBarLine{background:var(--emw--color-background-secondary, #474668)}";export{t as casino_engagement_suite_progress_bar}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{C as CasinoEngagementSuiteLuckyWheelList}from"./casino-engagement-suite-luckywheel-list-
|
|
1
|
+
export{C as CasinoEngagementSuiteLuckyWheelList}from"./casino-engagement-suite-luckywheel-list-cfa2521a.js";import"./index-8671bc92.js";
|
|
@@ -39,7 +39,7 @@ const TRANSLATIONS = {
|
|
|
39
39
|
new: 'new',
|
|
40
40
|
noluckywheels: 'No Unlocked LuckyWheel',
|
|
41
41
|
tryOtherGames: 'Try winning LuckyWheel as rewards or launching other booster games',
|
|
42
|
-
tooltip: '
|
|
42
|
+
tooltip: 'Get a chance to win rewards by spinning the wheel!',
|
|
43
43
|
history: 'History',
|
|
44
44
|
rewards: 'Rewards',
|
|
45
45
|
issued: 'Issued',
|
|
@@ -70,7 +70,8 @@ const getTranslations = (url) => {
|
|
|
70
70
|
}
|
|
71
71
|
});
|
|
72
72
|
resolve(TRANSLATIONS);
|
|
73
|
-
})
|
|
73
|
+
})
|
|
74
|
+
.catch((err) => {
|
|
74
75
|
reject(err);
|
|
75
76
|
});
|
|
76
77
|
});
|
|
@@ -2352,7 +2353,9 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2352
2353
|
.then((res) => res.text())
|
|
2353
2354
|
.then((data) => {
|
|
2354
2355
|
cssFile.innerHTML = data;
|
|
2355
|
-
setTimeout(() => {
|
|
2356
|
+
setTimeout(() => {
|
|
2357
|
+
this.host.prepend(cssFile);
|
|
2358
|
+
}, 1);
|
|
2356
2359
|
})
|
|
2357
2360
|
.catch((err) => {
|
|
2358
2361
|
console.log('Error ', err);
|
|
@@ -2374,14 +2377,14 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2374
2377
|
this.tooltip = false;
|
|
2375
2378
|
};
|
|
2376
2379
|
this.handleTabChange = (e) => {
|
|
2377
|
-
this.activeTab = +
|
|
2380
|
+
this.activeTab = +e.target.getAttribute('data-index');
|
|
2378
2381
|
if (this.activeTab === 2) {
|
|
2379
2382
|
this.sendHistoryRequest();
|
|
2380
2383
|
}
|
|
2381
2384
|
};
|
|
2382
2385
|
this.toggleLuckyWheelHistory = (ev) => {
|
|
2383
2386
|
const id = ev.currentTarget.getAttribute('data-id');
|
|
2384
|
-
const index = this.openedHistoryIds.findIndex(historyId => historyId === id);
|
|
2387
|
+
const index = this.openedHistoryIds.findIndex((historyId) => historyId === id);
|
|
2385
2388
|
if (index > -1) {
|
|
2386
2389
|
this.openedHistoryIds = this.openedHistoryIds.filter((historyId) => historyId !== id);
|
|
2387
2390
|
}
|
|
@@ -2458,8 +2461,9 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2458
2461
|
updateTimers() {
|
|
2459
2462
|
const now = new Date().getTime();
|
|
2460
2463
|
this.timers = this.luckyWheels.reduce((acc, luckywheel) => {
|
|
2461
|
-
var _a;
|
|
2462
|
-
const
|
|
2464
|
+
var _a, _b;
|
|
2465
|
+
const endTime = ((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.ExpiryTime) || ((_b = luckywheel.Program) === null || _b === void 0 ? void 0 : _b.Time);
|
|
2466
|
+
const expirationDate = new Date(endTime).getTime();
|
|
2463
2467
|
const diff = expirationDate - now;
|
|
2464
2468
|
let countdown = '00h:00m:00s';
|
|
2465
2469
|
if (diff < 1) {
|
|
@@ -2472,9 +2476,7 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2472
2476
|
minutes: String(Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60))).padStart(2, '0'),
|
|
2473
2477
|
seconds: String(Math.floor((diff % (1000 * 60)) / 1000)).padStart(2, '0')
|
|
2474
2478
|
};
|
|
2475
|
-
countdown = days === '00'
|
|
2476
|
-
? `${hours}h:${minutes}m:${seconds}s`
|
|
2477
|
-
: `${days}d:${hours}h:${minutes}m`;
|
|
2479
|
+
countdown = days === '00' ? `${hours}h:${minutes}m:${seconds}s` : `${days}d:${hours}h:${minutes}m`;
|
|
2478
2480
|
}
|
|
2479
2481
|
return Object.assign(Object.assign({}, acc), { [luckywheel.Program.Id]: countdown });
|
|
2480
2482
|
}, {});
|
|
@@ -2489,7 +2491,7 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2489
2491
|
window.postMessage({
|
|
2490
2492
|
type: 'LuckywheelHistoryRequest',
|
|
2491
2493
|
data: {
|
|
2492
|
-
lotteryProgramID: luckyWheel.Program.Id
|
|
2494
|
+
lotteryProgramID: luckyWheel.Program.Id
|
|
2493
2495
|
}
|
|
2494
2496
|
});
|
|
2495
2497
|
});
|
|
@@ -2506,49 +2508,47 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2506
2508
|
}
|
|
2507
2509
|
getLuckyWheelHeaderTemplate(luckywheel) {
|
|
2508
2510
|
var _a, _b;
|
|
2509
|
-
return (index.h("div", { class: "LuckyWheelsCardHeader" }, index.h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)),
|
|
2511
|
+
return (index.h("div", { class: "LuckyWheelsCardHeader" }, index.h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)), index.h("div", { class: "LuckyWheelsCounter" }, index.h("div", { class: `${((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.RemainingTimes) ? 'LuckyWheelsHighlightedCounter' : 'LuckyWheelsEmptyCounter'}` }, (_b = luckywheel.Current) === null || _b === void 0 ? void 0 : _b.RemainingTimes))));
|
|
2510
2512
|
}
|
|
2511
2513
|
getLuckyWheelTemplate(luckywheel, index$1) {
|
|
2512
2514
|
const countdown = this.timers[luckywheel.Program.Id];
|
|
2513
2515
|
return (index.h("div", { class: this.getLuckyWheelClasses(luckywheel), onClick: this.handleLuckyWheelClick, key: luckywheel.Program.Id, "data-id": luckywheel.Program.Id, "data-index": index$1 }, this.getLuckyWheelHeaderTemplate(luckywheel), index.h("div", { class: "LuckyWheelsCountdownWrapper" }, index.h("span", { class: "LuckyWheelsCountdown" }, countdown))));
|
|
2514
2516
|
}
|
|
2515
2517
|
getHeaderTemplate() {
|
|
2516
|
-
return index.h("header", { class: "LuckyWheelsListPopupHeader" }, index.h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), index.h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), index.h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick }));
|
|
2518
|
+
return (index.h("header", { class: "LuckyWheelsListPopupHeader" }, index.h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), index.h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), index.h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick })));
|
|
2517
2519
|
}
|
|
2518
2520
|
getListTemplate() {
|
|
2519
2521
|
if (this.isLoading) {
|
|
2520
2522
|
return index.h("general-animation-loading", null);
|
|
2521
2523
|
}
|
|
2522
2524
|
if (this.luckyWheels.length) {
|
|
2523
|
-
return index.h("div", { class: "LuckyWheelsListWrapper" }, index.h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index))));
|
|
2525
|
+
return (index.h("div", { class: "LuckyWheelsListWrapper" }, index.h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index)))));
|
|
2524
2526
|
}
|
|
2525
2527
|
else {
|
|
2526
|
-
return index.h("div", { class: "LuckyWheelsListEmpty" }, index.h("h2", null, translate('noluckywheels', this.language)), index.h("p", null, translate('tryOtherGames', this.language)));
|
|
2528
|
+
return (index.h("div", { class: "LuckyWheelsListEmpty" }, index.h("h2", null, translate('noluckywheels', this.language)), index.h("p", null, translate('tryOtherGames', this.language))));
|
|
2527
2529
|
}
|
|
2528
2530
|
}
|
|
2529
2531
|
getTooltipTemplate() {
|
|
2530
2532
|
if (this.tooltip) {
|
|
2531
|
-
return index.h("div", { class: "EngagementSuiteTooltipBackdrop" }, index.h("div", { class: "EngagementSuiteTooltip" }, index.h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language)));
|
|
2533
|
+
return (index.h("div", { class: "EngagementSuiteTooltipBackdrop" }, index.h("div", { class: "EngagementSuiteTooltip" }, index.h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language))));
|
|
2532
2534
|
}
|
|
2533
2535
|
else {
|
|
2534
2536
|
return '';
|
|
2535
2537
|
}
|
|
2536
2538
|
}
|
|
2537
2539
|
getTabsTemplate() {
|
|
2538
|
-
return index.h("div", { class: "EngagementSuiteTabsWrapper" }, index.h("div", { class: "EngagementSuiteTabs" }, index.h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), index.h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language))));
|
|
2540
|
+
return (index.h("div", { class: "EngagementSuiteTabsWrapper" }, index.h("div", { class: "EngagementSuiteTabs" }, index.h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), index.h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language)))));
|
|
2539
2541
|
}
|
|
2540
2542
|
getHistoryTabTemplate() {
|
|
2541
|
-
return index.h("div", { class: "HistoryWrapper" }, index.h("div", { class: "HistoryCols" }, index.h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), index.h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), index.h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
2543
|
+
return (index.h("div", { class: "HistoryWrapper" }, index.h("div", { class: "HistoryCols" }, index.h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), index.h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), index.h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
2542
2544
|
? getHistoryLoaderTemplate(this.language)
|
|
2543
|
-
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language));
|
|
2545
|
+
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language)));
|
|
2544
2546
|
}
|
|
2545
2547
|
getTabsContentTemplate() {
|
|
2546
|
-
return this.activeTab === 1
|
|
2547
|
-
? this.getListTemplate()
|
|
2548
|
-
: this.getHistoryTabTemplate();
|
|
2548
|
+
return this.activeTab === 1 ? this.getListTemplate() : this.getHistoryTabTemplate();
|
|
2549
2549
|
}
|
|
2550
2550
|
render() {
|
|
2551
|
-
return index.h("div", { key: '
|
|
2551
|
+
return (index.h("div", { key: '0286500986b71786315f4b0d4860e6bf0069fa0e', class: `LuckyWheelsListPopup ${this.device}` }, this.getHeaderTemplate(), this.getTabsTemplate(), this.getTabsContentTemplate(), this.getTooltipTemplate()));
|
|
2552
2552
|
}
|
|
2553
2553
|
get host() { return index.getElement(this); }
|
|
2554
2554
|
static get watchers() { return {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const casinoEngagementSuiteLuckywheelList = require('./casino-engagement-suite-luckywheel-list-
|
|
5
|
+
const casinoEngagementSuiteLuckywheelList = require('./casino-engagement-suite-luckywheel-list-8d3dd746.js');
|
|
6
6
|
const index = require('./index-c93b88f6.js');
|
|
7
7
|
|
|
8
8
|
const casinoEngagementSuiteProgressBarCss = ":host{display:block;font-family:inherit}:host(.Desktop) .ProgressBarPercent{font-size:var(--emw--font-size-small, 14px);line-height:14px}@keyframes indeterminate{0%{left:-200%;right:100%}60%{left:110%;right:-10%}to{left:110%;right:-10%}}.ProgressBarBackground{height:8px;background-color:var(--emw--color-gray-300, #666178);border-radius:var(--emw--border-radius-small, 4px);position:relative;overflow:hidden}.ProgressBarLine{position:absolute;left:0;top:0;bottom:0;border-radius:var(--emw--border-radius-small, 4px);background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));transition:width ease-out 0.3s}.ProgressBarLine.Indeterminate{animation:indeterminate 1s linear infinite}.ProgressBarInfo{margin-bottom:8px;display:flex;justify-content:space-between;align-items:center}.ProgressBarPercent{font-weight:var(--emw--font-weight-bold, 700);font-size:var(--emw--font-size-x-small, 12px);line-height:12px}.HidePercent .ProgressBarPercent{display:none}.ProgressBar:not(.Disabled) .ProgressBarPercent{background:var(--emw--engagement-suite-gradient-button, 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-gray-300, #666178)}.ProgressBar.Disabled .ProgressBarLine{background:var(--emw--color-background-secondary, #474668)}";
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const casinoEngagementSuiteLuckywheelList = require('./casino-engagement-suite-luckywheel-list-
|
|
5
|
+
const casinoEngagementSuiteLuckywheelList = require('./casino-engagement-suite-luckywheel-list-8d3dd746.js');
|
|
6
6
|
require('./index-c93b88f6.js');
|
|
7
7
|
|
|
8
8
|
|
|
@@ -18,7 +18,9 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
18
18
|
.then((res) => res.text())
|
|
19
19
|
.then((data) => {
|
|
20
20
|
cssFile.innerHTML = data;
|
|
21
|
-
setTimeout(() => {
|
|
21
|
+
setTimeout(() => {
|
|
22
|
+
this.host.prepend(cssFile);
|
|
23
|
+
}, 1);
|
|
22
24
|
})
|
|
23
25
|
.catch((err) => {
|
|
24
26
|
console.log('Error ', err);
|
|
@@ -40,14 +42,14 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
40
42
|
this.tooltip = false;
|
|
41
43
|
};
|
|
42
44
|
this.handleTabChange = (e) => {
|
|
43
|
-
this.activeTab = +
|
|
45
|
+
this.activeTab = +e.target.getAttribute('data-index');
|
|
44
46
|
if (this.activeTab === 2) {
|
|
45
47
|
this.sendHistoryRequest();
|
|
46
48
|
}
|
|
47
49
|
};
|
|
48
50
|
this.toggleLuckyWheelHistory = (ev) => {
|
|
49
51
|
const id = ev.currentTarget.getAttribute('data-id');
|
|
50
|
-
const index = this.openedHistoryIds.findIndex(historyId => historyId === id);
|
|
52
|
+
const index = this.openedHistoryIds.findIndex((historyId) => historyId === id);
|
|
51
53
|
if (index > -1) {
|
|
52
54
|
this.openedHistoryIds = this.openedHistoryIds.filter((historyId) => historyId !== id);
|
|
53
55
|
}
|
|
@@ -124,8 +126,9 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
124
126
|
updateTimers() {
|
|
125
127
|
const now = new Date().getTime();
|
|
126
128
|
this.timers = this.luckyWheels.reduce((acc, luckywheel) => {
|
|
127
|
-
var _a;
|
|
128
|
-
const
|
|
129
|
+
var _a, _b;
|
|
130
|
+
const endTime = ((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.ExpiryTime) || ((_b = luckywheel.Program) === null || _b === void 0 ? void 0 : _b.Time);
|
|
131
|
+
const expirationDate = new Date(endTime).getTime();
|
|
129
132
|
const diff = expirationDate - now;
|
|
130
133
|
let countdown = '00h:00m:00s';
|
|
131
134
|
if (diff < 1) {
|
|
@@ -138,9 +141,7 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
138
141
|
minutes: String(Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60))).padStart(2, '0'),
|
|
139
142
|
seconds: String(Math.floor((diff % (1000 * 60)) / 1000)).padStart(2, '0')
|
|
140
143
|
};
|
|
141
|
-
countdown = days === '00'
|
|
142
|
-
? `${hours}h:${minutes}m:${seconds}s`
|
|
143
|
-
: `${days}d:${hours}h:${minutes}m`;
|
|
144
|
+
countdown = days === '00' ? `${hours}h:${minutes}m:${seconds}s` : `${days}d:${hours}h:${minutes}m`;
|
|
144
145
|
}
|
|
145
146
|
return Object.assign(Object.assign({}, acc), { [luckywheel.Program.Id]: countdown });
|
|
146
147
|
}, {});
|
|
@@ -155,7 +156,7 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
155
156
|
window.postMessage({
|
|
156
157
|
type: 'LuckywheelHistoryRequest',
|
|
157
158
|
data: {
|
|
158
|
-
lotteryProgramID: luckyWheel.Program.Id
|
|
159
|
+
lotteryProgramID: luckyWheel.Program.Id
|
|
159
160
|
}
|
|
160
161
|
});
|
|
161
162
|
});
|
|
@@ -172,49 +173,47 @@ export class CasinoEngagementSuiteLuckyWheelList {
|
|
|
172
173
|
}
|
|
173
174
|
getLuckyWheelHeaderTemplate(luckywheel) {
|
|
174
175
|
var _a, _b;
|
|
175
|
-
return (h("div", { class: "LuckyWheelsCardHeader" }, h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)),
|
|
176
|
+
return (h("div", { class: "LuckyWheelsCardHeader" }, h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)), h("div", { class: "LuckyWheelsCounter" }, h("div", { class: `${((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.RemainingTimes) ? 'LuckyWheelsHighlightedCounter' : 'LuckyWheelsEmptyCounter'}` }, (_b = luckywheel.Current) === null || _b === void 0 ? void 0 : _b.RemainingTimes))));
|
|
176
177
|
}
|
|
177
178
|
getLuckyWheelTemplate(luckywheel, index) {
|
|
178
179
|
const countdown = this.timers[luckywheel.Program.Id];
|
|
179
180
|
return (h("div", { class: this.getLuckyWheelClasses(luckywheel), onClick: this.handleLuckyWheelClick, key: luckywheel.Program.Id, "data-id": luckywheel.Program.Id, "data-index": index }, this.getLuckyWheelHeaderTemplate(luckywheel), h("div", { class: "LuckyWheelsCountdownWrapper" }, h("span", { class: "LuckyWheelsCountdown" }, countdown))));
|
|
180
181
|
}
|
|
181
182
|
getHeaderTemplate() {
|
|
182
|
-
return h("header", { class: "LuckyWheelsListPopupHeader" }, h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick }));
|
|
183
|
+
return (h("header", { class: "LuckyWheelsListPopupHeader" }, h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick })));
|
|
183
184
|
}
|
|
184
185
|
getListTemplate() {
|
|
185
186
|
if (this.isLoading) {
|
|
186
187
|
return h("general-animation-loading", null);
|
|
187
188
|
}
|
|
188
189
|
if (this.luckyWheels.length) {
|
|
189
|
-
return h("div", { class: "LuckyWheelsListWrapper" }, h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index))));
|
|
190
|
+
return (h("div", { class: "LuckyWheelsListWrapper" }, h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index)))));
|
|
190
191
|
}
|
|
191
192
|
else {
|
|
192
|
-
return h("div", { class: "LuckyWheelsListEmpty" }, h("h2", null, translate('noluckywheels', this.language)), h("p", null, translate('tryOtherGames', this.language)));
|
|
193
|
+
return (h("div", { class: "LuckyWheelsListEmpty" }, h("h2", null, translate('noluckywheels', this.language)), h("p", null, translate('tryOtherGames', this.language))));
|
|
193
194
|
}
|
|
194
195
|
}
|
|
195
196
|
getTooltipTemplate() {
|
|
196
197
|
if (this.tooltip) {
|
|
197
|
-
return h("div", { class: "EngagementSuiteTooltipBackdrop" }, h("div", { class: "EngagementSuiteTooltip" }, h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language)));
|
|
198
|
+
return (h("div", { class: "EngagementSuiteTooltipBackdrop" }, h("div", { class: "EngagementSuiteTooltip" }, h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language))));
|
|
198
199
|
}
|
|
199
200
|
else {
|
|
200
201
|
return '';
|
|
201
202
|
}
|
|
202
203
|
}
|
|
203
204
|
getTabsTemplate() {
|
|
204
|
-
return h("div", { class: "EngagementSuiteTabsWrapper" }, h("div", { class: "EngagementSuiteTabs" }, h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language))));
|
|
205
|
+
return (h("div", { class: "EngagementSuiteTabsWrapper" }, h("div", { class: "EngagementSuiteTabs" }, h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language)))));
|
|
205
206
|
}
|
|
206
207
|
getHistoryTabTemplate() {
|
|
207
|
-
return h("div", { class: "HistoryWrapper" }, h("div", { class: "HistoryCols" }, h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
208
|
+
return (h("div", { class: "HistoryWrapper" }, h("div", { class: "HistoryCols" }, h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
208
209
|
? getHistoryLoaderTemplate(this.language)
|
|
209
|
-
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language));
|
|
210
|
+
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language)));
|
|
210
211
|
}
|
|
211
212
|
getTabsContentTemplate() {
|
|
212
|
-
return this.activeTab === 1
|
|
213
|
-
? this.getListTemplate()
|
|
214
|
-
: this.getHistoryTabTemplate();
|
|
213
|
+
return this.activeTab === 1 ? this.getListTemplate() : this.getHistoryTabTemplate();
|
|
215
214
|
}
|
|
216
215
|
render() {
|
|
217
|
-
return h("div", { key: '
|
|
216
|
+
return (h("div", { key: '0286500986b71786315f4b0d4860e6bf0069fa0e', class: `LuckyWheelsListPopup ${this.device}` }, this.getHeaderTemplate(), this.getTabsTemplate(), this.getTabsContentTemplate(), this.getTooltipTemplate()));
|
|
218
217
|
}
|
|
219
218
|
static get is() { return "casino-engagement-suite-luckywheel-list"; }
|
|
220
219
|
static get encapsulation() { return "shadow"; }
|
|
@@ -8,7 +8,7 @@ const TRANSLATIONS = {
|
|
|
8
8
|
new: 'new',
|
|
9
9
|
noluckywheels: 'No Unlocked LuckyWheel',
|
|
10
10
|
tryOtherGames: 'Try winning LuckyWheel as rewards or launching other booster games',
|
|
11
|
-
tooltip: '
|
|
11
|
+
tooltip: 'Get a chance to win rewards by spinning the wheel!',
|
|
12
12
|
history: 'History',
|
|
13
13
|
rewards: 'Rewards',
|
|
14
14
|
issued: 'Issued',
|
|
@@ -39,7 +39,8 @@ export const getTranslations = (url) => {
|
|
|
39
39
|
}
|
|
40
40
|
});
|
|
41
41
|
resolve(TRANSLATIONS);
|
|
42
|
-
})
|
|
42
|
+
})
|
|
43
|
+
.catch((err) => {
|
|
43
44
|
reject(err);
|
|
44
45
|
});
|
|
45
46
|
});
|
|
@@ -37,7 +37,7 @@ const TRANSLATIONS = {
|
|
|
37
37
|
new: 'new',
|
|
38
38
|
noluckywheels: 'No Unlocked LuckyWheel',
|
|
39
39
|
tryOtherGames: 'Try winning LuckyWheel as rewards or launching other booster games',
|
|
40
|
-
tooltip: '
|
|
40
|
+
tooltip: 'Get a chance to win rewards by spinning the wheel!',
|
|
41
41
|
history: 'History',
|
|
42
42
|
rewards: 'Rewards',
|
|
43
43
|
issued: 'Issued',
|
|
@@ -68,7 +68,8 @@ const getTranslations = (url) => {
|
|
|
68
68
|
}
|
|
69
69
|
});
|
|
70
70
|
resolve(TRANSLATIONS);
|
|
71
|
-
})
|
|
71
|
+
})
|
|
72
|
+
.catch((err) => {
|
|
72
73
|
reject(err);
|
|
73
74
|
});
|
|
74
75
|
});
|
|
@@ -2350,7 +2351,9 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2350
2351
|
.then((res) => res.text())
|
|
2351
2352
|
.then((data) => {
|
|
2352
2353
|
cssFile.innerHTML = data;
|
|
2353
|
-
setTimeout(() => {
|
|
2354
|
+
setTimeout(() => {
|
|
2355
|
+
this.host.prepend(cssFile);
|
|
2356
|
+
}, 1);
|
|
2354
2357
|
})
|
|
2355
2358
|
.catch((err) => {
|
|
2356
2359
|
console.log('Error ', err);
|
|
@@ -2372,14 +2375,14 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2372
2375
|
this.tooltip = false;
|
|
2373
2376
|
};
|
|
2374
2377
|
this.handleTabChange = (e) => {
|
|
2375
|
-
this.activeTab = +
|
|
2378
|
+
this.activeTab = +e.target.getAttribute('data-index');
|
|
2376
2379
|
if (this.activeTab === 2) {
|
|
2377
2380
|
this.sendHistoryRequest();
|
|
2378
2381
|
}
|
|
2379
2382
|
};
|
|
2380
2383
|
this.toggleLuckyWheelHistory = (ev) => {
|
|
2381
2384
|
const id = ev.currentTarget.getAttribute('data-id');
|
|
2382
|
-
const index = this.openedHistoryIds.findIndex(historyId => historyId === id);
|
|
2385
|
+
const index = this.openedHistoryIds.findIndex((historyId) => historyId === id);
|
|
2383
2386
|
if (index > -1) {
|
|
2384
2387
|
this.openedHistoryIds = this.openedHistoryIds.filter((historyId) => historyId !== id);
|
|
2385
2388
|
}
|
|
@@ -2456,8 +2459,9 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2456
2459
|
updateTimers() {
|
|
2457
2460
|
const now = new Date().getTime();
|
|
2458
2461
|
this.timers = this.luckyWheels.reduce((acc, luckywheel) => {
|
|
2459
|
-
var _a;
|
|
2460
|
-
const
|
|
2462
|
+
var _a, _b;
|
|
2463
|
+
const endTime = ((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.ExpiryTime) || ((_b = luckywheel.Program) === null || _b === void 0 ? void 0 : _b.Time);
|
|
2464
|
+
const expirationDate = new Date(endTime).getTime();
|
|
2461
2465
|
const diff = expirationDate - now;
|
|
2462
2466
|
let countdown = '00h:00m:00s';
|
|
2463
2467
|
if (diff < 1) {
|
|
@@ -2470,9 +2474,7 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2470
2474
|
minutes: String(Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60))).padStart(2, '0'),
|
|
2471
2475
|
seconds: String(Math.floor((diff % (1000 * 60)) / 1000)).padStart(2, '0')
|
|
2472
2476
|
};
|
|
2473
|
-
countdown = days === '00'
|
|
2474
|
-
? `${hours}h:${minutes}m:${seconds}s`
|
|
2475
|
-
: `${days}d:${hours}h:${minutes}m`;
|
|
2477
|
+
countdown = days === '00' ? `${hours}h:${minutes}m:${seconds}s` : `${days}d:${hours}h:${minutes}m`;
|
|
2476
2478
|
}
|
|
2477
2479
|
return Object.assign(Object.assign({}, acc), { [luckywheel.Program.Id]: countdown });
|
|
2478
2480
|
}, {});
|
|
@@ -2487,7 +2489,7 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2487
2489
|
window.postMessage({
|
|
2488
2490
|
type: 'LuckywheelHistoryRequest',
|
|
2489
2491
|
data: {
|
|
2490
|
-
lotteryProgramID: luckyWheel.Program.Id
|
|
2492
|
+
lotteryProgramID: luckyWheel.Program.Id
|
|
2491
2493
|
}
|
|
2492
2494
|
});
|
|
2493
2495
|
});
|
|
@@ -2504,49 +2506,47 @@ const CasinoEngagementSuiteLuckyWheelList = class {
|
|
|
2504
2506
|
}
|
|
2505
2507
|
getLuckyWheelHeaderTemplate(luckywheel) {
|
|
2506
2508
|
var _a, _b;
|
|
2507
|
-
return (h("div", { class: "LuckyWheelsCardHeader" }, h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)),
|
|
2509
|
+
return (h("div", { class: "LuckyWheelsCardHeader" }, h("div", { class: `LuckyWheelsName` }, this.getLuckyWheelName(luckywheel)), h("div", { class: "LuckyWheelsCounter" }, h("div", { class: `${((_a = luckywheel.Current) === null || _a === void 0 ? void 0 : _a.RemainingTimes) ? 'LuckyWheelsHighlightedCounter' : 'LuckyWheelsEmptyCounter'}` }, (_b = luckywheel.Current) === null || _b === void 0 ? void 0 : _b.RemainingTimes))));
|
|
2508
2510
|
}
|
|
2509
2511
|
getLuckyWheelTemplate(luckywheel, index) {
|
|
2510
2512
|
const countdown = this.timers[luckywheel.Program.Id];
|
|
2511
2513
|
return (h("div", { class: this.getLuckyWheelClasses(luckywheel), onClick: this.handleLuckyWheelClick, key: luckywheel.Program.Id, "data-id": luckywheel.Program.Id, "data-index": index }, this.getLuckyWheelHeaderTemplate(luckywheel), h("div", { class: "LuckyWheelsCountdownWrapper" }, h("span", { class: "LuckyWheelsCountdown" }, countdown))));
|
|
2512
2514
|
}
|
|
2513
2515
|
getHeaderTemplate() {
|
|
2514
|
-
return h("header", { class: "LuckyWheelsListPopupHeader" }, h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick }));
|
|
2516
|
+
return (h("header", { class: "LuckyWheelsListPopupHeader" }, h("button", { onClick: this.showTooltip, class: "EngagementSuiteIconButton Help" }), h("div", { class: "LuckyWheelsListPopupHeaderName" }, translate('luckyWheel', this.language)), h("button", { class: "EngagementSuiteIconButton Close", onClick: this.handleCloseClick })));
|
|
2515
2517
|
}
|
|
2516
2518
|
getListTemplate() {
|
|
2517
2519
|
if (this.isLoading) {
|
|
2518
2520
|
return h("general-animation-loading", null);
|
|
2519
2521
|
}
|
|
2520
2522
|
if (this.luckyWheels.length) {
|
|
2521
|
-
return h("div", { class: "LuckyWheelsListWrapper" }, h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index))));
|
|
2523
|
+
return (h("div", { class: "LuckyWheelsListWrapper" }, h("div", { class: "LuckyWheelsList" }, this.luckyWheels.map((luckywheel, index) => this.getLuckyWheelTemplate(luckywheel, index)))));
|
|
2522
2524
|
}
|
|
2523
2525
|
else {
|
|
2524
|
-
return h("div", { class: "LuckyWheelsListEmpty" }, h("h2", null, translate('noluckywheels', this.language)), h("p", null, translate('tryOtherGames', this.language)));
|
|
2526
|
+
return (h("div", { class: "LuckyWheelsListEmpty" }, h("h2", null, translate('noluckywheels', this.language)), h("p", null, translate('tryOtherGames', this.language))));
|
|
2525
2527
|
}
|
|
2526
2528
|
}
|
|
2527
2529
|
getTooltipTemplate() {
|
|
2528
2530
|
if (this.tooltip) {
|
|
2529
|
-
return h("div", { class: "EngagementSuiteTooltipBackdrop" }, h("div", { class: "EngagementSuiteTooltip" }, h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language)));
|
|
2531
|
+
return (h("div", { class: "EngagementSuiteTooltipBackdrop" }, h("div", { class: "EngagementSuiteTooltip" }, h("button", { class: "EngagementSuiteIconButton Close", onClick: this.hideTooltip }), translate('tooltip', this.language))));
|
|
2530
2532
|
}
|
|
2531
2533
|
else {
|
|
2532
2534
|
return '';
|
|
2533
2535
|
}
|
|
2534
2536
|
}
|
|
2535
2537
|
getTabsTemplate() {
|
|
2536
|
-
return h("div", { class: "EngagementSuiteTabsWrapper" }, h("div", { class: "EngagementSuiteTabs" }, h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language))));
|
|
2538
|
+
return (h("div", { class: "EngagementSuiteTabsWrapper" }, h("div", { class: "EngagementSuiteTabs" }, h("div", { "data-index": "1", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 1 ? 'Active' : ''}` }, translate('luckywheels', this.language)), h("div", { "data-index": "2", onClick: this.handleTabChange, class: `EngagementSuiteTab ${this.activeTab === 2 ? 'Active' : ''}` }, translate('history', this.language)))));
|
|
2537
2539
|
}
|
|
2538
2540
|
getHistoryTabTemplate() {
|
|
2539
|
-
return h("div", { class: "HistoryWrapper" }, h("div", { class: "HistoryCols" }, h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
2541
|
+
return (h("div", { class: "HistoryWrapper" }, h("div", { class: "HistoryCols" }, h("div", { class: "HistoryColName Rewards" }, translate('rewards', this.language)), h("div", { class: "HistoryColName Issued" }, translate('issued', this.language)), h("div", { class: "HistoryColName Time" }, translate('time', this.language))), this.historyLoading
|
|
2540
2542
|
? getHistoryLoaderTemplate(this.language)
|
|
2541
|
-
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language));
|
|
2543
|
+
: getLuckyWheelsHistoryTemplate(this.luckyWheels, this.luckywheelHistory, this.openedHistoryIds, this.toggleLuckyWheelHistory, this.language)));
|
|
2542
2544
|
}
|
|
2543
2545
|
getTabsContentTemplate() {
|
|
2544
|
-
return this.activeTab === 1
|
|
2545
|
-
? this.getListTemplate()
|
|
2546
|
-
: this.getHistoryTabTemplate();
|
|
2546
|
+
return this.activeTab === 1 ? this.getListTemplate() : this.getHistoryTabTemplate();
|
|
2547
2547
|
}
|
|
2548
2548
|
render() {
|
|
2549
|
-
return h("div", { key: '
|
|
2549
|
+
return (h("div", { key: '0286500986b71786315f4b0d4860e6bf0069fa0e', class: `LuckyWheelsListPopup ${this.device}` }, this.getHeaderTemplate(), this.getTabsTemplate(), this.getTabsContentTemplate(), this.getTooltipTemplate()));
|
|
2550
2550
|
}
|
|
2551
2551
|
get host() { return getElement(this); }
|
|
2552
2552
|
static get watchers() { return {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { C as casino_engagement_suite_luckywheel_list } from './casino-engagement-suite-luckywheel-list-
|
|
1
|
+
export { C as casino_engagement_suite_luckywheel_list } from './casino-engagement-suite-luckywheel-list-cfa2521a.js';
|
|
2
2
|
import { r as registerInstance, h, g as getElement } from './index-8671bc92.js';
|
|
3
3
|
|
|
4
4
|
const casinoEngagementSuiteProgressBarCss = ":host{display:block;font-family:inherit}:host(.Desktop) .ProgressBarPercent{font-size:var(--emw--font-size-small, 14px);line-height:14px}@keyframes indeterminate{0%{left:-200%;right:100%}60%{left:110%;right:-10%}to{left:110%;right:-10%}}.ProgressBarBackground{height:8px;background-color:var(--emw--color-gray-300, #666178);border-radius:var(--emw--border-radius-small, 4px);position:relative;overflow:hidden}.ProgressBarLine{position:absolute;left:0;top:0;bottom:0;border-radius:var(--emw--border-radius-small, 4px);background:var(--emw--engagement-suite-gradient-button, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%));transition:width ease-out 0.3s}.ProgressBarLine.Indeterminate{animation:indeterminate 1s linear infinite}.ProgressBarInfo{margin-bottom:8px;display:flex;justify-content:space-between;align-items:center}.ProgressBarPercent{font-weight:var(--emw--font-weight-bold, 700);font-size:var(--emw--font-size-x-small, 12px);line-height:12px}.HidePercent .ProgressBarPercent{display:none}.ProgressBar:not(.Disabled) .ProgressBarPercent{background:var(--emw--engagement-suite-gradient-button, 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-gray-300, #666178)}.ProgressBar.Disabled .ProgressBarLine{background:var(--emw--color-background-secondary, #474668)}";
|
package/dist/esm/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { C as CasinoEngagementSuiteLuckyWheelList } from './casino-engagement-suite-luckywheel-list-
|
|
1
|
+
export { C as CasinoEngagementSuiteLuckyWheelList } from './casino-engagement-suite-luckywheel-list-cfa2521a.js';
|
|
2
2
|
import './index-8671bc92.js';
|
package/package.json
CHANGED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import{h as t,r as e,c as n,g as i}from"./index-8671bc92.js";
|
|
2
|
-
/*! *****************************************************************************
|
|
3
|
-
Copyright (c) Microsoft Corporation.
|
|
4
|
-
|
|
5
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
-
purpose with or without fee is hereby granted.
|
|
7
|
-
|
|
8
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
9
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
10
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
11
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
12
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
13
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
15
|
-
***************************************************************************** */const r=["en"],o={en:{luckywheels:"LuckyWheels",join:"Join",unjoin:"Unjoin",new:"new",noluckywheels:"No Unlocked LuckyWheel",tryOtherGames:"Try winning LuckyWheel as rewards or launching other booster games",tooltip:"LuckyWheels where your real money bets contribute towards the level progress to achieve the level reward",history:"History",rewards:"Rewards",issued:"Issued",time:"Time",loading:"Loading...",noHistory:"No LuckyWheels’ history available (last 30 days)",freeSpins:"Free Spins",luckyWheel:"LuckyWheel",leaderboard:"Leaderboard",mission:"Mission",canceled:"The luckywheel has been canceled.",support:"Please, contact support."}},s=(t,e)=>{const n=e;return o[void 0!==n&&r.includes(n)?n:"en"][t]};var a,u,l,c={};function d(t){return d="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},d(t)}function h(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function p(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function f(t){p(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===d(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(t){var e=Object.defineProperty,n=Object.defineProperties,i=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,a=(t,n,i)=>n in t?e(t,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[n]=i,u=(t,e)=>{for(var n in e||(e={}))o.call(e,n)&&a(t,n,e[n]);if(r)for(var n of r(e))s.call(e,n)&&a(t,n,e[n]);return t},l=(t,e)=>n(t,i(e)),c=(t,e,n)=>(a(t,"symbol"!=typeof e?e+"":e,n),n);function d(){}function h(t){return t()}function p(){return Object.create(null)}function f(t){t.forEach(h)}function m(t){return"function"==typeof t}function y(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function g(t,e,n){t.insertBefore(e,n||null)}function v(t){t.parentNode&&t.parentNode.removeChild(t)}function w(t){return document.createElement(t)}let b;function x(t){b=t}Object.defineProperty(t,Symbol.toStringTag,{value:"Module"});const L=[],k=[];let W=[];const H=[],E=Promise.resolve();let S=!1;function P(t){W.push(t)}const T=new Set;let M=0;function C(){if(0!==M)return;const t=b;do{try{for(;M<L.length;){const t=L[M];M++,x(t),I(t.$$)}}catch(t){throw L.length=0,M=0,t}for(x(null),L.length=0,M=0;k.length;)k.pop()();for(let t=0;t<W.length;t+=1){const e=W[t];T.has(e)||(T.add(e),e())}W.length=0}while(L.length);for(;H.length;)H.pop()();S=!1,T.clear(),x(t)}function I(t){if(null!==t.fragment){t.update(),f(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(P)}}const D=new Set;function z(t,e,n,i,r,o,s=null,a=[-1]){const u=b;x(t);const l=t.$$={fragment:null,ctx:[],props:o,update:d,not_equal:r,bound:p(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(u?u.$$.context:[])),callbacks:p(),dirty:a,skip_bound:!1,root:e.target||u.$$.root};s&&s(l.root);let c=!1;if(l.ctx=n?n(t,e.props||{},((e,n,...i)=>{const o=i.length?i[0]:n;return l.ctx&&r(l.ctx[e],l.ctx[e]=o)&&(!l.skip_bound&&l.bound[e]&&l.bound[e](o),c&&function(t,e){-1===t.$$.dirty[0]&&(L.push(t),S||(S=!0,E.then(C)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}(t,e)),n})):[],l.update(),c=!0,f(l.before_update),l.fragment=!!i&&i(l.ctx),e.target){if(e.hydrate){const t=function(t){return Array.from(t.childNodes)}(e.target);l.fragment&&l.fragment.l(t),t.forEach(v)}else l.fragment&&l.fragment.c();e.intro&&function(t){t&&t.i&&(D.delete(t),t.i(void 0))}(t.$$.fragment),function(t,e,n){const{fragment:i,after_update:r}=t.$$;i&&i.m(e,n),P((()=>{const e=t.$$.on_mount.map(h).filter(m);t.$$.on_destroy?t.$$.on_destroy.push(...e):f(e),t.$$.on_mount=[]})),r.forEach(P)}(t,e.target,e.anchor),C()}x(u)}let j;function O(t,e,n,i){var r;const o=null==(r=n[t])?void 0:r.type;if(e="Boolean"===o&&"boolean"!=typeof e?null!=e:e,!i||!n[t])return e;if("toAttribute"===i)switch(o){case"Object":case"Array":return null==e?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return null==e?null:e;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":default:return e;case"Number":return null!=e?+e:e}}"function"==typeof HTMLElement&&(j=class extends HTMLElement{constructor(t,e,n){super(),c(this,"$$ctor"),c(this,"$$s"),c(this,"$$c"),c(this,"$$cn",!1),c(this,"$$d",{}),c(this,"$$r",!1),c(this,"$$p_d",{}),c(this,"$$l",{}),c(this,"$$l_u",new Map),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){const n=this.$$c.$on(t,e);this.$$l_u.set(e,n)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){const t=this.$$l_u.get(e);t&&(t(),this.$$l_u.delete(e))}}connectedCallback(){return t=this,e=function*(){if(this.$$cn=!0,!this.$$c){let t=function(t){return()=>{let e;return{c:function(){e=w("slot"),"default"!==t&&function(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}(e,"name",t)},m:function(t,n){g(t,e,n)},d:function(t){t&&v(e)}}}};if(yield Promise.resolve(),!this.$$cn||this.$$c)return;const e={},n=function(t){const e={};return t.childNodes.forEach((t=>{e[t.slot||"default"]=!0})),e}(this);for(const i of this.$$s)i in n&&(e[i]=[t(i)]);for(const t of this.attributes){const e=this.$$g_p(t.name);e in this.$$d||(this.$$d[e]=O(e,t.value,this.$$p_d,"toProp"))}for(const t in this.$$p_d)!(t in this.$$d)&&void 0!==this[t]&&(this.$$d[t]=this[t],delete this[t]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:l(u({},this.$$d),{$$slots:e,$$scope:{ctx:[]}})});const i=()=>{this.$$r=!0;for(const t in this.$$p_d)if(this.$$d[t]=this.$$c.$$.ctx[this.$$c.$$.props[t]],this.$$p_d[t].reflect){const e=O(t,this.$$d[t],this.$$p_d,"toAttribute");null==e?this.removeAttribute(this.$$p_d[t].attribute||t):this.setAttribute(this.$$p_d[t].attribute||t,e)}this.$$r=!1};this.$$c.$$.after_update.push(i),i();for(const t in this.$$l)for(const e of this.$$l[t]){const n=this.$$c.$on(t,e);this.$$l_u.set(e,n)}this.$$l={}}},new Promise(((n,i)=>{var r=t=>{try{s(e.next(t))}catch(t){i(t)}},o=t=>{try{s(e.throw(t))}catch(t){i(t)}},s=t=>t.done?n(t.value):Promise.resolve(t.value).then(r,o);s((e=e.apply(t,null)).next())}));var t,e}attributeChangedCallback(t,e,n){var i;this.$$r||(t=this.$$g_p(t),this.$$d[t]=O(t,n,this.$$p_d,"toProp"),null==(i=this.$$c)||i.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then((()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)}))}$$g_p(t){return Object.keys(this.$$p_d).find((e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t))||t}});class B{constructor(){c(this,"$$"),c(this,"$$set")}$destroy(){(function(t,e){const n=t.$$;null!==n.fragment&&(function(t){const e=[],n=[];W.forEach((i=>-1===t.indexOf(i)?e.push(i):n.push(i))),n.forEach((t=>t())),W=e}(n.after_update),f(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])})(this,1),this.$destroy=d}$on(t,e){if(!m(e))return d;const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){this.$$set&&0!==Object.keys(t).length&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function $(t){!function(t,e,n){const i=function(t){if(!t)return document;const e=t.getRootNode?t.getRootNode():t.ownerDocument;return e&&e.host?e:t.ownerDocument}(t);if(!i.getElementById(e)){const t=w("style");t.id=e,t.textContent=n,function(t,e){!function(t,e){t.appendChild(e)}(t.head||t,e)}(i,t)}}(t,"svelte-gnt082",".LoaderContainer{display:flex;justify-content:center}.lds-ellipsis{display:inline-block;position:relative;width:80px;height:80px}.lds-ellipsis div{position:absolute;top:33px;width:13px;height:13px;border-radius:50%;background:#d1d1d1;animation-timing-function:cubic-bezier(0, 1, 1, 0)}.lds-ellipsis div:nth-child(1){left:8px;animation:lds-ellipsis1 0.6s infinite}.lds-ellipsis div:nth-child(2){left:8px;animation:lds-ellipsis2 0.6s infinite}.lds-ellipsis div:nth-child(3){left:32px;animation:lds-ellipsis2 0.6s infinite}.lds-ellipsis div:nth-child(4){left:56px;animation:lds-ellipsis3 0.6s infinite}@keyframes lds-ellipsis1{0%{transform:scale(0)}100%{transform:scale(1)}}@keyframes lds-ellipsis3{0%{transform:scale(1)}100%{transform:scale(0)}}@keyframes lds-ellipsis2{0%{transform:translate(0, 0)}100%{transform:translate(24px, 0)}}")}function N(t){let e;return{c(){e=w("div"),e.innerHTML='<section class="LoaderContainer"><div class="lds-ellipsis"><div></div><div></div><div></div><div></div></div></section>'},m(n,i){g(n,e,i),t[4](e)},p:d,i:d,o:d,d(n){n&&v(e),t[4](null)}}}function R(t,e,n){let i,{clientstyling:r=""}=e,{clientstylingurl:o=""}=e,{mbsource:s}=e;return function(t){(function(){if(!b)throw new Error("Function called outside component initialization");return b})().$$.on_mount.push(t)}((()=>()=>{})),t.$$set=t=>{"clientstyling"in t&&n(1,r=t.clientstyling),"clientstylingurl"in t&&n(2,o=t.clientstylingurl),"mbsource"in t&&n(3,s=t.mbsource)},t.$$.update=()=>{3&t.$$.dirty&&r&&i&&function(t,e){if(t){const n=document.createElement("style");n.innerHTML=e,t.appendChild(n)}}(i,r),5&t.$$.dirty&&o&&i&&function(t,e){const n=new URL(e);fetch(n.href).then((t=>t.text())).then((e=>{const n=document.createElement("style");n.innerHTML=e,t&&t.appendChild(n)})).catch((t=>{console.error("There was an error while trying to load client styling from URL",t)}))}(i,o),9&t.$$.dirty&&s&&i&&function(t,e){if(window.emMessageBus){const n=document.createElement("style");window.emMessageBus.subscribe(e,(e=>{n.innerHTML=e,t&&t.appendChild(n)}))}}(i,`${s}.Style`)},[i,r,o,s,function(t){k[t?"unshift":"push"]((()=>{i=t,n(0,i)}))}]}"undefined"!=typeof window&&(window.__svelte||(window.__svelte={v:new Set})).v.add("4");class q extends B{constructor(t){super(),z(this,t,R,N,y,{clientstyling:1,clientstylingurl:2,mbsource:3},$)}get clientstyling(){return this.$$.ctx[1]}set clientstyling(t){this.$$set({clientstyling:t}),C()}get clientstylingurl(){return this.$$.ctx[2]}set clientstylingurl(t){this.$$set({clientstylingurl:t}),C()}get mbsource(){return this.$$.ctx[3]}set mbsource(t){this.$$set({mbsource:t}),C()}}!function(t,e,n){let i=class extends j{constructor(){super(t,n,true),this.$$p_d=e}static get observedAttributes(){return Object.keys(e).map((t=>(e[t].attribute||t).toLowerCase()))}};Object.keys(e).forEach((t=>{Object.defineProperty(i.prototype,t,{get(){return this.$$c&&t in this.$$c?this.$$c[t]:this.$$d[t]},set(n){var i;n=O(t,n,e),this.$$d[t]=n,null==(i=this.$$c)||i.$set({[t]:n})}})})),[].forEach((t=>{Object.defineProperty(i.prototype,t,{get(){var e;return null==(e=this.$$c)?void 0:e[t]}})})),t.element=i}(q,{clientstyling:{},clientstylingurl:{},mbsource:{}},[]),t.default=q})(c),"undefined"!=typeof window&&(customElements.define=(l=customElements.define,function(...t){try{return l.apply(this,t)}catch(t){if(t instanceof DOMException&&t.message.includes("has already been used with this registry")||t.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw t}}),Promise.resolve().then((()=>c)).then((({default:t})=>{!customElements.get("general-animation-loading")&&customElements.define("general-animation-loading",t.element)}))),function(t){t[t.FreeSpins=0]="FreeSpins",t[t.LuckyWheel=1]="LuckyWheel",t[t.Leaderboard=2]="Leaderboard",t[t.Challenge=3]="Challenge",t[t.Custom=4]="Custom"}(a||(a={})),function(t){t[t.Completed=0]="Completed",t[t.Expired=1]="Expired",t[t.Forfeited=2]="Forfeited"}(u||(u={}));var m={};function y(){return m}function g(t){p(1,arguments);var e=f(t),n=e.getUTCDay(),i=(n<1?7:0)+n-1;return e.setUTCDate(e.getUTCDate()-i),e.setUTCHours(0,0,0,0),e}function v(t){p(1,arguments);var e=f(t),n=e.getUTCFullYear(),i=new Date(0);i.setUTCFullYear(n+1,0,4),i.setUTCHours(0,0,0,0);var r=g(i),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var s=g(o);return e.getTime()>=r.getTime()?n+1:e.getTime()>=s.getTime()?n:n-1}function w(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=y(),d=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.weekStartsOn)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.weekStartsOn)&&void 0!==r?r:c.weekStartsOn)&&void 0!==i?i:null===(u=c.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==n?n:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var m=f(t),g=m.getUTCDay(),v=(g<d?7:0)+g-d;return m.setUTCDate(m.getUTCDate()-v),m.setUTCHours(0,0,0,0),m}function b(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=f(t),d=c.getUTCFullYear(),m=y(),g=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.firstWeekContainsDate)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==r?r:m.firstWeekContainsDate)&&void 0!==i?i:null===(u=m.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==n?n:1);if(!(g>=1&&g<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var v=new Date(0);v.setUTCFullYear(d+1,0,g),v.setUTCHours(0,0,0,0);var b=w(v,e),x=new Date(0);x.setUTCFullYear(d,0,g),x.setUTCHours(0,0,0,0);var L=w(x,e);return c.getTime()>=b.getTime()?d+1:c.getTime()>=L.getTime()?d:d-1}function x(t,e){for(var n=t<0?"-":"",i=Math.abs(t).toString();i.length<e;)i="0"+i;return n+i}const L=function(t,e){var n=t.getUTCFullYear(),i=n>0?n:1-n;return x("yy"===e?i%100:i,e.length)},k=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):x(n+1,2)},W=function(t,e){return x(t.getUTCDate(),e.length)},H=function(t,e){return x(t.getUTCHours()%12||12,e.length)},E=function(t,e){return x(t.getUTCHours(),e.length)},S=function(t,e){return x(t.getUTCMinutes(),e.length)},P=function(t,e){return x(t.getUTCSeconds(),e.length)},T=function(t,e){var n=e.length,i=t.getUTCMilliseconds();return x(Math.floor(i*Math.pow(10,n-3)),e.length)};var M={G:function(t,e,n){var i=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(i,{width:"abbreviated"});case"GGGGG":return n.era(i,{width:"narrow"});default:return n.era(i,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var i=t.getUTCFullYear();return n.ordinalNumber(i>0?i:1-i,{unit:"year"})}return L(t,e)},Y:function(t,e,n,i){var r=b(t,i),o=r>0?r:1-r;return"YY"===e?x(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):x(o,e.length)},R:function(t,e){return x(v(t),e.length)},u:function(t,e){return x(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(i);case"QQ":return x(i,2);case"Qo":return n.ordinalNumber(i,{unit:"quarter"});case"QQQ":return n.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(i,{width:"narrow",context:"formatting"});default:return n.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,e,n){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(i);case"qq":return x(i,2);case"qo":return n.ordinalNumber(i,{unit:"quarter"});case"qqq":return n.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(i,{width:"narrow",context:"standalone"});default:return n.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,e,n){var i=t.getUTCMonth();switch(e){case"M":case"MM":return k(t,e);case"Mo":return n.ordinalNumber(i+1,{unit:"month"});case"MMM":return n.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(i,{width:"narrow",context:"formatting"});default:return n.month(i,{width:"wide",context:"formatting"})}},L:function(t,e,n){var i=t.getUTCMonth();switch(e){case"L":return String(i+1);case"LL":return x(i+1,2);case"Lo":return n.ordinalNumber(i+1,{unit:"month"});case"LLL":return n.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(i,{width:"narrow",context:"standalone"});default:return n.month(i,{width:"wide",context:"standalone"})}},w:function(t,e,n,i){var r=function(t,e){p(1,arguments);var n=f(t),i=w(n,e).getTime()-function(t,e){var n,i,r,o,s,a,u,l;p(1,arguments);var c=y(),d=h(null!==(n=null!==(i=null!==(r=null!==(o=null==e?void 0:e.firstWeekContainsDate)&&void 0!==o?o:null==e||null===(s=e.locale)||void 0===s||null===(a=s.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==r?r:c.firstWeekContainsDate)&&void 0!==i?i:null===(u=c.locale)||void 0===u||null===(l=u.options)||void 0===l?void 0:l.firstWeekContainsDate)&&void 0!==n?n:1),f=b(t,e),m=new Date(0);return m.setUTCFullYear(f,0,d),m.setUTCHours(0,0,0,0),w(m,e)}(n,e).getTime();return Math.round(i/6048e5)+1}(t,i);return"wo"===e?n.ordinalNumber(r,{unit:"week"}):x(r,e.length)},I:function(t,e,n){var i=function(t){p(1,arguments);var e=f(t),n=g(e).getTime()-function(t){p(1,arguments);var e=v(t),n=new Date(0);return n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0),g(n)}(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(i,{unit:"week"}):x(i,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):W(t,e)},D:function(t,e,n){var i=function(t){p(1,arguments);var e=f(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var i=e.getTime();return Math.floor((n-i)/864e5)+1}(t);return"Do"===e?n.ordinalNumber(i,{unit:"dayOfYear"}):x(i,e.length)},E:function(t,e,n){var i=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(i,{width:"short",context:"formatting"});default:return n.day(i,{width:"wide",context:"formatting"})}},e:function(t,e,n,i){var r=t.getUTCDay(),o=(r-i.weekStartsOn+8)%7||7;switch(e){case"e":return String(o);case"ee":return x(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},c:function(t,e,n,i){var r=t.getUTCDay(),o=(r-i.weekStartsOn+8)%7||7;switch(e){case"c":return String(o);case"cc":return x(o,e.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(r,{width:"narrow",context:"standalone"});case"cccccc":return n.day(r,{width:"short",context:"standalone"});default:return n.day(r,{width:"wide",context:"standalone"})}},i:function(t,e,n){var i=t.getUTCDay(),r=0===i?7:i;switch(e){case"i":return String(r);case"ii":return x(r,e.length);case"io":return n.ordinalNumber(r,{unit:"day"});case"iii":return n.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(i,{width:"short",context:"formatting"});default:return n.day(i,{width:"wide",context:"formatting"})}},a:function(t,e,n){var i=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,n){var i,r=t.getUTCHours();switch(i=12===r?"noon":0===r?"midnight":r/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(t,e,n){var i,r=t.getUTCHours();switch(i=r>=17?"evening":r>=12?"afternoon":r>=4?"morning":"night",e){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var i=t.getUTCHours()%12;return 0===i&&(i=12),n.ordinalNumber(i,{unit:"hour"})}return H(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E(t,e)},K:function(t,e,n){var i=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(i,{unit:"hour"}):x(i,e.length)},k:function(t,e,n){var i=t.getUTCHours();return 0===i&&(i=24),"ko"===e?n.ordinalNumber(i,{unit:"hour"}):x(i,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):S(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):P(t,e)},S:function(t,e){return T(t,e)},X:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();if(0===r)return"Z";switch(e){case"X":return I(r);case"XXXX":case"XX":return D(r);default:return D(r,":")}},x:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"x":return I(r);case"xxxx":case"xx":return D(r);default:return D(r,":")}},O:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+C(r,":");default:return"GMT"+D(r,":")}},z:function(t,e,n,i){var r=(i._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+C(r,":");default:return"GMT"+D(r,":")}},t:function(t,e,n,i){return x(Math.floor((i._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,n,i){return x((i._originalDate||t).getTime(),e.length)}};function C(t,e){var n=t>0?"-":"+",i=Math.abs(t),r=Math.floor(i/60),o=i%60;if(0===o)return n+String(r);var s=e||"";return n+String(r)+s+x(o,2)}function I(t,e){return t%60==0?(t>0?"-":"+")+x(Math.abs(t)/60,2):D(t,e)}function D(t,e){var n=e||"",i=t>0?"-":"+",r=Math.abs(t);return i+x(Math.floor(r/60),2)+n+x(r%60,2)}const z=M;var j=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},O=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},B={p:O,P:function(t,e){var n,i=t.match(/(P+)(p+)?/)||[],r=i[1],o=i[2];if(!o)return j(t,e);switch(r){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;default:n=e.dateTime({width:"full"})}return n.replace("{{date}}",j(r,e)).replace("{{time}}",O(o,e))}};const $=B;var N=["D","DD"],R=["YY","YYYY"];function q(t,e,n){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Y={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function A(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.width?String(e.width):t.defaultWidth;return t.formats[n]||t.formats[t.defaultWidth]}}var G,Q={date:A({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:A({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:A({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},F={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function X(t){return function(e,n){var i;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var r=t.defaultFormattingWidth||t.defaultWidth,o=null!=n&&n.width?String(n.width):r;i=t.formattingValues[o]||t.formattingValues[r]}else{var s=t.defaultWidth,a=null!=n&&n.width?String(n.width):t.defaultWidth;i=t.values[a]||t.values[s]}return i[t.argumentCallback?t.argumentCallback(e):e]}}function J(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.width,r=e.match(i&&t.matchPatterns[i]||t.matchPatterns[t.defaultMatchWidth]);if(!r)return null;var o,s=r[0],a=i&&t.parsePatterns[i]||t.parsePatterns[t.defaultParseWidth],u=Array.isArray(a)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(s))return e}(a):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(s))return e}(a);return o=t.valueCallback?t.valueCallback(u):u,{value:o=n.valueCallback?n.valueCallback(o):o,rest:e.slice(s.length)}}}const _={code:"en-US",formatDistance:function(t,e,n){var i,r=Y[t];return i="string"==typeof r?r:1===e?r.one:r.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+i:i+" ago":i},formatLong:Q,formatRelative:function(t){return F[t]},localize:{ordinalNumber:function(t){var e=Number(t),n=e%100;if(n>20||n<10)switch(n%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:X({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:X({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:X({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:X({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:X({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(G={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.match(G.matchPattern);if(!n)return null;var i=n[0],r=t.match(G.parsePattern);if(!r)return null;var o=G.valueCallback?G.valueCallback(r[0]):r[0];return{value:o=e.valueCallback?e.valueCallback(o):o,rest:t.slice(i.length)}}),era:J({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:J({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:J({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:J({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:J({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};var U=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,K=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Z=/^'([^]*?)'?$/,V=/''/g,tt=/[a-zA-Z]/;function et(t,e,n){var i,r,o,s,a,u,l,c,m,g,v,w,b,x,L,k,W,H;p(2,arguments);var E=String(e),S=y(),P=null!==(i=null!==(r=null==n?void 0:n.locale)&&void 0!==r?r:S.locale)&&void 0!==i?i:_,T=h(null!==(o=null!==(s=null!==(a=null!==(u=null==n?void 0:n.firstWeekContainsDate)&&void 0!==u?u:null==n||null===(l=n.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==a?a:S.firstWeekContainsDate)&&void 0!==s?s:null===(m=S.locale)||void 0===m||null===(g=m.options)||void 0===g?void 0:g.firstWeekContainsDate)&&void 0!==o?o:1);if(!(T>=1&&T<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var M=h(null!==(v=null!==(w=null!==(b=null!==(x=null==n?void 0:n.weekStartsOn)&&void 0!==x?x:null==n||null===(L=n.locale)||void 0===L||null===(k=L.options)||void 0===k?void 0:k.weekStartsOn)&&void 0!==b?b:S.weekStartsOn)&&void 0!==w?w:null===(W=S.locale)||void 0===W||null===(H=W.options)||void 0===H?void 0:H.weekStartsOn)&&void 0!==v?v:0);if(!(M>=0&&M<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!P.localize)throw new RangeError("locale must contain localize property");if(!P.formatLong)throw new RangeError("locale must contain formatLong property");var C=f(t);if(!function(t){if(p(1,arguments),!function(t){return p(1,arguments),t instanceof Date||"object"===d(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=f(t);return!isNaN(Number(e))}(C))throw new RangeError("Invalid time value");var I=function(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}(C),D=function(t,e){return p(2,arguments),function(t,e){p(2,arguments);var n=f(t).getTime(),i=h(e);return new Date(n+i)}(t,-h(e))}(C,I),j={firstWeekContainsDate:T,weekStartsOn:M,locale:P,_originalDate:C};return E.match(K).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,$[e])(t,P.formatLong):t})).join("").match(U).map((function(i){if("''"===i)return"'";var r,o,s=i[0];if("'"===s)return(o=(r=i).match(Z))?o[1].replace(V,"'"):r;var a=z[s];if(a)return null!=n&&n.useAdditionalWeekYearTokens||-1===R.indexOf(i)||q(i,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!(-1!==N.indexOf(i))||q(i,e,String(t)),a(D,i,P.localize,j);if(s.match(tt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+s+"`");return i})).join("")}const nt=class{constructor(t){e(this,t),this.close=n(this,"close",7),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.tooltip=!1},this.handleLuckyWheelClick=t=>{const e=t.currentTarget.getAttribute("data-id"),n=t.currentTarget.getAttribute("data-index");window.postMessage({type:"LuckyWheelClick",id:e,index:n})},this.showTooltip=()=>{this.tooltip=!0},this.hideTooltip=()=>{this.tooltip=!1},this.handleTabChange=t=>{this.activeTab=+t.target.getAttribute("data-index"),2===this.activeTab&&this.sendHistoryRequest()},this.toggleLuckyWheelHistory=t=>{const e=t.currentTarget.getAttribute("data-id");this.openedHistoryIds.findIndex((t=>t===e))>-1?this.openedHistoryIds=this.openedHistoryIds.filter((t=>t!==e)):this.openedHistoryIds.push(e),this.openedHistoryIds=[...this.openedHistoryIds]},this.clientStyling="",this.clientStylingUrl="",this.language="en",this.device="Mobile",this.luckyWheels=[],this.translationUrl="",this.tooltip=!1,this.timers={},this.limitStylingAppends=!1,this.activeTab=1,this.historyLoading=!1,this.luckywheelHistory={},this.openedHistoryIds=[],this.historyLoaded=!1,this.isLoading=!1}handleEvent(t){var e;const n=null==t?void 0:t.data,{type:i}=n,r=function(t,e){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.indexOf(i)<0&&(n[i]=t[i]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(t);r<i.length;r++)e.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(t,i[r])&&(n[i[r]]=t[i[r]])}return n}(n,["type"]);if("BarLuckyWheelsClick"===i&&(this.activeTab=1,this.openedHistoryIds=[]),"LuckywheelHistoryResponse"===i){this.openedHistoryIds=[];const t=r.data;if(t.length>0){const n=null===(e=t[0].Draw)||void 0===e?void 0:e.LotteryProgramID;this.luckywheelHistory[n]=t}this.historyLoading=!1}}luckywheelsPropHandler(t){!this.interval&&t.length&&(this.updateTimers(),this.startCountdown()),this.interval&&!t.length&&clearInterval(this.interval)}async componentWillLoad(){var t;this.luckywheelsPropHandler(this.luckyWheels),this.translationUrl&&await(t=this.translationUrl,new Promise(((e,n)=>{fetch(t).then((t=>t.json())).then((t=>{Object.keys(t).forEach((e=>{for(let n in t[e])o[e][n]=t[e][n]})),e(o)})).catch((t=>{n(t)}))})))}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}disconnectedCallback(){this.interval&&clearInterval(this.interval)}startCountdown(){this.interval=setInterval((()=>{this.updateTimers()}),1e3)}updateTimers(){const t=(new Date).getTime();this.timers=this.luckyWheels.reduce(((e,n)=>{var i;const r=new Date(null===(i=n.Current)||void 0===i?void 0:i.EndTime).getTime()-t;let o="00h:00m:00s";if(r<1)this.removeLuckyWheel(n.Program.Id);else{const{days:t,hours:e,minutes:n,seconds:i}={days:String(Math.floor(r/864e5)).padStart(2,"0"),hours:String(Math.floor(r%864e5/36e5)).padStart(2,"0"),minutes:String(Math.floor(r%36e5/6e4)).padStart(2,"0"),seconds:String(Math.floor(r%6e4/1e3)).padStart(2,"0")};o="00"===t?`${e}h:${n}m:${i}s`:`${t}d:${e}h:${n}m`}return Object.assign(Object.assign({},e),{[n.Program.Id]:o})}),{})}removeLuckyWheel(t){this.luckyWheels=this.luckyWheels.filter((e=>e.Program.Id!==t)),window.postMessage({type:"LuckyWheelHasExpired",id:t})}sendHistoryRequest(){this.historyLoading=!0,this.luckyWheels.forEach((t=>{window.postMessage({type:"LuckywheelHistoryRequest",data:{lotteryProgramID:t.Program.Id}})}))}getLuckyWheelClasses(t){return{LuckyWheelsCard:!0,LuckyWheelsEmptyNumber:0===t.Current.RemainingTimes}}getLuckyWheelName(t){var e,n;return(null===(e=t.Program)||void 0===e?void 0:e.Name.en)||(null===(n=t.Program)||void 0===n?void 0:n.Name["*"])}getLuckyWheelHeaderTemplate(e){var n,i;return t("div",{class:"LuckyWheelsCardHeader"},t("div",{class:"LuckyWheelsName"},this.getLuckyWheelName(e)),t("div",{class:"LuckyWheelsCounter"},t("div",{class:(null===(n=e.Current)||void 0===n?void 0:n.RemainingTimes)?"LuckyWheelsHighlightedCounter":"LuckyWheelsEmptyCounter"},null===(i=e.Current)||void 0===i?void 0:i.RemainingTimes)))}getLuckyWheelTemplate(e,n){const i=this.timers[e.Program.Id];return t("div",{class:this.getLuckyWheelClasses(e),onClick:this.handleLuckyWheelClick,key:e.Program.Id,"data-id":e.Program.Id,"data-index":n},this.getLuckyWheelHeaderTemplate(e),t("div",{class:"LuckyWheelsCountdownWrapper"},t("span",{class:"LuckyWheelsCountdown"},i)))}getHeaderTemplate(){return t("header",{class:"LuckyWheelsListPopupHeader"},t("button",{onClick:this.showTooltip,class:"EngagementSuiteIconButton Help"}),t("div",{class:"LuckyWheelsListPopupHeaderName"},s("luckyWheel",this.language)),t("button",{class:"EngagementSuiteIconButton Close",onClick:this.handleCloseClick}))}getListTemplate(){return this.isLoading?t("general-animation-loading",null):this.luckyWheels.length?t("div",{class:"LuckyWheelsListWrapper"},t("div",{class:"LuckyWheelsList"},this.luckyWheels.map(((t,e)=>this.getLuckyWheelTemplate(t,e))))):t("div",{class:"LuckyWheelsListEmpty"},t("h2",null,s("noluckywheels",this.language)),t("p",null,s("tryOtherGames",this.language)))}getTooltipTemplate(){return this.tooltip?t("div",{class:"EngagementSuiteTooltipBackdrop"},t("div",{class:"EngagementSuiteTooltip"},t("button",{class:"EngagementSuiteIconButton Close",onClick:this.hideTooltip}),s("tooltip",this.language))):""}getTabsTemplate(){return t("div",{class:"EngagementSuiteTabsWrapper"},t("div",{class:"EngagementSuiteTabs"},t("div",{"data-index":"1",onClick:this.handleTabChange,class:"EngagementSuiteTab "+(1===this.activeTab?"Active":"")},s("luckywheels",this.language)),t("div",{"data-index":"2",onClick:this.handleTabChange,class:"EngagementSuiteTab "+(2===this.activeTab?"Active":"")},s("history",this.language))))}getHistoryTabTemplate(){return t("div",{class:"HistoryWrapper"},t("div",{class:"HistoryCols"},t("div",{class:"HistoryColName Rewards"},s("rewards",this.language)),t("div",{class:"HistoryColName Issued"},s("issued",this.language)),t("div",{class:"HistoryColName Time"},s("time",this.language))),this.historyLoading?(e=this.language,t("div",{class:"HistoryLoader"},t("casino-engagement-suite-progress-bar",{indeterminate:!0}),t("span",null,s("loading",e)))):((e,n,i,r,o)=>0===e.length?t("p",{class:"HistoryEmptyMessage"},s("noHistory",o)):t("div",{class:"HistoryList"},e.map((e=>{var o;return t("div",{key:e.Program.Id,class:"HistoryListItem "+(i.includes(e.Program.Id)?"Opened":"Closed")},t("header",{class:"HistoryListItemHeader","data-id":e.Program.Id,onClick:r},e.Program.Name.en||e.Program.Name["*"],t("button",{class:"EngagementSuiteIconButton ArrowDown"})),t("div",{class:"HistoryListItemBody"},t("div",{class:"HistoryInfoRow"},null===(o=n[e.Program.Id])||void 0===o?void 0:o.map((n=>t("div",{class:"HistoryInfo"},t("div",{class:"HistoryCol Rewards"},((e,n)=>{var i,r,o,s;const a=n.WheelOfFortunePartitionIndex||0,u=null===(r=null===(i=e.Program.WheelOfFortune)||void 0===i?void 0:i.Partitions[a])||void 0===r?void 0:r.Name,l=null===(s=null===(o=e.Program.WheelOfFortune)||void 0===o?void 0:o.Partitions[a])||void 0===s?void 0:s.Image1,c=l.en||l["*"],d=e.Program.Name.en||e.Program.Name["*"];return t("div",{class:"HistoryRewards"},u.en||u["*"]||(c?t("img",{src:c}):d))})(e,n.Draw.Result)),t("div",{class:"HistoryCol Issued"},"fulfilled"===n.Draw.State?"Success":"Failed"),t("div",{class:"HistoryCol Time"},et(new Date(n.Draw.Time),"LLL d, yyyy HH:mm:ss"))))))))}))))(this.luckyWheels,this.luckywheelHistory,this.openedHistoryIds,this.toggleLuckyWheelHistory,this.language));var e}getTabsContentTemplate(){return 1===this.activeTab?this.getListTemplate():this.getHistoryTabTemplate()}render(){return t("div",{key:"1cf093e57c0baf84d3ab42d9ec95624a0373629c",class:`LuckyWheelsListPopup ${this.device}`},this.getHeaderTemplate(),this.getTabsTemplate(),this.getTabsContentTemplate(),this.getTooltipTemplate())}get host(){return i(this)}static get watchers(){return{luckyWheels:["luckywheelsPropHandler"]}}};nt.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer}button:focus{outline:none}.EngagementSuiteIconButton{width:16px;height:16px}.EngagementSuiteIconButton.Help{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/help.svg) no-repeat}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.EngagementSuiteIconButton.ArrowDown{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/arrow-down.svg) no-repeat}.LuckyWheelsListPopup{display:flex;height:100%;background-color:var(--emw--color-background, #1e1638);border-radius:var(--emw--border-radius-large, 8px);overflow:hidden;flex-direction:column;position:relative;padding-bottom:20px}.LuckyWheelsListPopupHeader{display:flex;justify-content:space-between;align-items:center;padding:12px 8px 8px}.LuckyWheelsListPopupHeaderName{color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-small, 14px);font-weight:var(--emw--font-weight-medium, 500);line-height:14px}.LuckyWheelsListWrapper{overflow-y:auto;-ms-overflow-style:none;scrollbar-width:none}.LuckyWheelsListWrapper::-webkit-scrollbar{display:none}.LuckyWheelsList{display:flex;flex-direction:column;row-gap:12px;padding:8px 19px 0}.LuckyWheelsRowWrapper{display:flex;justify-content:space-between;min-width:0}.LuckyWheelsCard{padding:15px 15px 19px;border:1px solid var(--emw--button-border-color, #403956);border-radius:var(--emw--border-radius-medium, 6px);position:relative;cursor:pointer}.LuckyWheelsCard.Forfeited{cursor:auto;pointer-events:none}.LuckyWheelsCardHeader{display:flex;justify-content:space-between;gap:24px;margin-bottom:12px;flex:1;min-width:0;align-items:flex-end}.LuckyWheelsName{color:var(--emw--color-typography, #ffffff);font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);line-height:22px;font-weight:var(--emw--font-weight-bold, 700);font-size:var(--emw--font-size-medium-plus, 18px);word-break:break-word;flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.LuckyWheelsCounter{display:flex;color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-medium-plus, 18px);align-items:flex-end}.LuckyWheelsHighlightedCounter,.LuckyWheelsEmptyCounter{font-size:var(--emw--font-size-medium-plus, 18px);font-weight:var(--emw--font-weight-extra-bold, 800);margin-right:4px}.LuckyWheelsHighlightedCounter{background:var(--emw--engagement-suite-gradient-golden, linear-gradient(180deg, #ffb801 15.86%, #fef746 31.36%, #fbffe0 36.86%, #fffa60 47.86%, #ff9400 87.36%));-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}.LuckyWheelsEmptyCounter{color:var(--emw--color-gray-150, #8f8b9c)}.LuckyWheelsListEmpty{padding:20px 32px}.LuckyWheelsListEmpty h2{margin:0 0 16px 0;text-align:center;font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large, 20px);line-height:24px;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);color:var(--emw--color-typography, #ffffff)}.LuckyWheelsListEmpty p{font-size:var(--emw--font-size-small, 14px);line-height:17px;color:var(--emw--color-secondary, #bbb9c3)}.LuckyWheelsCountdownWrapper{display:flex;justify-content:space-between;align-items:flex-start}.LuckyWheelsCountdown,.ForfeitedMessage{color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-x-small, 12px);line-height:12px}.ForfeitedMessage{line-height:1.2}.LuckyWheelsBalCounter{display:flex;align-items:flex-end;color:var(--emw--color-secondary, #bbb9c3);font-size:var(--emw--font-size-x-small, 12px)}.LuckyWheelsRemainCounter{color:var(--emw--color-typography, #ffffff);font-weight:var(--emw--font-weight-bold, 700);margin-right:4px}.LuckyWheelLabel{min-width:35px;height:18px;background:var(--emw--engagement-suite-gradient-golden, linear-gradient(180deg, #ffb801 15.86%, #fef746 31.36%, #fbffe0 36.86%, #fffa60 47.86%, #ff9400 87.36%));border-radius:var(--emw--border-radius-x-small, 2px);display:none;position:absolute;top:-11px;right:11px;padding:0 2px;align-items:center;justify-content:center}.LuckyWheelLabel span{display:inline-block;text-transform:uppercase;font-size:var(--emw--font-size-2x-small, 10px);line-height:10px;font-weight:var(--emw--font-weight-bold, 700);font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);color:var(--emw--color-background, #1e1638)}.ShowLuckyWheelLabel{display:inline-flex}.EngagementSuiteTooltipBackdrop{padding:48px 30px 0;position:absolute;width:100%;height:100%;inset:0;background-color:rgba(0, 0, 0, 0.5)}.EngagementSuiteTooltipBackdrop .EngagementSuiteTooltip{border:1px solid var(--emw--button-border-color, #403956);background-color:var(--emw--color-background, #1e1638);border-radius:var(--emw--border-radius-large, 8px);padding:32px;font-size:var(--emw--font-size-small, 14px);line-height:17px;color:var(--emw--color-secondary, #bbb9c3);position:relative}.EngagementSuiteTooltipBackdrop .EngagementSuiteTooltip .EngagementSuiteIconButton{top:12px;right:12px;position:absolute}.LuckyWheelsEmptyNumber .LuckyWheelsName,.LuckyWheelsEmptyNumber .LuckyWheelsCountdown,.LuckyWheelsEmptyNumber .LuckyWheelsRemainCounter{color:var(--emw--color-gray-150, #8f8b9c)}.LuckyWheelsListPopup.Tablet .LuckyWheelsListPopupHeader,.LuckyWheelsListPopup.Desktop .LuckyWheelsListPopupHeader{padding-top:16px}.LuckyWheelsListPopup.Tablet .LuckyWheelsListPopupHeaderName,.LuckyWheelsListPopup.Desktop .LuckyWheelsListPopupHeaderName{font-size:var(--emw--font-size-medium, 16px);line-height:16px}.LuckyWheelsListPopup.Tablet .EngagementSuiteIconButton,.LuckyWheelsListPopup.Desktop .EngagementSuiteIconButton{width:24px;height:24px}.LuckyWheelsListPopup.Tablet .LuckyWheelsList,.LuckyWheelsListPopup.Desktop .LuckyWheelsList{padding:20px 24px 0;row-gap:20px}.LuckyWheelsListPopup.Tablet .LuckyWheelCardHeader,.LuckyWheelsListPopup.Desktop .LuckyWheelCardHeader{margin-bottom:16px}.LuckyWheelsListPopup.Tablet .LuckyWheelsName,.LuckyWheelsListPopup.Desktop .LuckyWheelsName{line-height:27px;font-size:var(--emw--font-size-large, 22px)}.LuckyWheelsListPopup.Tablet .LuckyWheelsCountdown,.LuckyWheelsListPopup.Desktop .LuckyWheelsCountdown{font-size:var(--emw--font-size-small, 14px);line-height:14px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltipBackdrop,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltipBackdrop{padding:90px 75px 0}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltip,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltip{padding:60px 65px;font-size:var(--emw--font-size-medium, 16px);line-height:20px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTooltip .EngagementSuiteIconButton,.LuckyWheelsListPopup.Desktop .EngagementSuiteTooltip .EngagementSuiteIconButton{top:24px;right:24px}.LuckyWheelsListPopup.Tablet .EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab,.LuckyWheelsListPopup.Desktop .EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols .Rewards,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols .Rewards{flex-basis:140px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryCols .Issued,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryCols .Issued{flex-basis:100px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryListItemHeader,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryListItemHeader{font-size:var(--emw--font-size-large, 22px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo{font-size:var(--emw--font-size-medium, 16px)}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo .Rewards,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo .Rewards{flex-basis:140px}.LuckyWheelsListPopup.Tablet .HistoryWrapper .HistoryListItem .HistoryInfo .Issued,.LuckyWheelsListPopup.Desktop .HistoryWrapper .HistoryListItem .HistoryInfo .Issued{flex-basis:100px}.EngagementSuiteTabsWrapper{padding:0 24px;margin:8px 0}.EngagementSuiteTabsWrapper .EngagementSuiteTabs{display:flex;position:relative;border-bottom:2px solid var(--emw--color-secondary, #666178)}.EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab{padding:9px 16px 7px;font-weight:var(--emw--font-weight-medium, 500);font-size:var(--emw--font-size-x-small, 12px);line-height:15px;color:var(--emw--color-gray-300, #666178);cursor:pointer}.EngagementSuiteTabsWrapper .EngagementSuiteTabs .EngagementSuiteTab.Active{color:var(--emw--color-typography, #fff);border-bottom:2px solid var(--emw--color-typography, #fff);margin-bottom:-2px}.HistoryWrapper{padding:0 24px;display:flex;flex-direction:column;height:100%;overflow:hidden}.HistoryWrapper .HistoryEmptyMessage{margin-top:8px;font-size:var(--emw--font-size-small, 14px);color:var(--emw--color-secondary, #bbb9c3);line-height:30px}.HistoryWrapper .HistoryCols{padding:12px 10px;position:relative;display:flex;border-bottom:1px solid var(--emw--color-secondary, #666178);font-size:var(--emw--font-size-x-small, 12px)}.HistoryWrapper .HistoryCols .HistoryColName{color:var(--emw--color-secondary, #bbb9c3)}.HistoryWrapper .HistoryCols .Rewards{flex-basis:80px}.HistoryWrapper .HistoryCols .Issued{flex-basis:80px}.HistoryWrapper .HistoryLoader{display:flex;flex-direction:column;justify-content:center;align-items:center;height:inherit;font-size:var(--emw--font-size-medium, 16px);color:var(--emw--color-gray-150, #8f8b9c)}.HistoryWrapper .HistoryLoader casino-engagement-suite-progress-bar{margin-bottom:8px;width:100px}.HistoryWrapper .HistoryListItem{max-height:300px;overflow:auto;margin-top:8px}.HistoryWrapper .HistoryListItem.Opened .EngagementSuiteIconButton.ArrowDown{transform:rotate(180deg)}.HistoryWrapper .HistoryListItem.Opened .HistoryListItemBody{padding-bottom:8px;grid-template-rows:1fr;border-bottom:1px solid var(--emw--color-secondary, #666178)}.HistoryWrapper .HistoryListItem .HistoryListItemHeader{padding:16px 0;display:flex;justify-content:space-between;align-items:center;color:var(--emw--color-typography, #ffffff);font-size:var(--emw--font-size-medium, 14px)}.HistoryWrapper .HistoryListItem .EngagementSuiteIconButton.ArrowDown{transition:transform 0.3s ease-out;width:24px;height:24px}.HistoryWrapper .HistoryListItem .HistoryListItemBody{position:relative;display:grid;grid-template-rows:0fr;transition:grid-template-rows 0.3s ease-out}.HistoryWrapper .HistoryListItem .HistoryListItemBody>div{overflow:hidden}.HistoryWrapper .HistoryListItem .HistoryListItemCard{padding:12px 5px}.HistoryWrapper .HistoryListItem .HistoryInfoRow{display:flex;gap:10px;flex-direction:column}.HistoryWrapper .HistoryListItem .HistoryInfo{display:flex;padding:10px;font-size:var(--emw--font-size-x-small, 12px);color:var(--emw--color-secondary, #bbb9c3)}.HistoryWrapper .HistoryListItem .HistoryInfo .HistoryCol{text-overflow:ellipsis;overflow:hidden}.HistoryWrapper .HistoryListItem .HistoryInfo .Rewards{color:var(--emw--color-typography, #ffffff);flex-basis:80px;font-weight:600}.HistoryWrapper .HistoryListItem .HistoryInfo .Issued{flex-basis:80px}';export{nt as C}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|