@everymatrix/lottery-tipping-ticket-buy 0.5.56 → 0.5.59

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.
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-8a0b513b.js');
6
- const lotteryTippingTicketBuy = require('./lottery-tipping-ticket-buy-164a217a.js');
6
+ const lotteryTippingTicketBuy = require('./lottery-tipping-ticket-buy-29b4469c.js');
7
7
 
8
8
  /**
9
9
  * @name addMilliseconds
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const lotteryTippingTicketBuy = require('./lottery-tipping-ticket-buy-164a217a.js');
5
+ const lotteryTippingTicketBuy = require('./lottery-tipping-ticket-buy-29b4469c.js');
6
6
  require('./index-8a0b513b.js');
7
7
 
8
8
 
@@ -853,7 +853,7 @@ const LotterySegmented = class {
853
853
  };
854
854
  LotterySegmented.style = LotterySegmentedStyle0;
855
855
 
856
- var qr=Object.defineProperty,Yr=Object.defineProperties;var Kr=Object.getOwnPropertyDescriptors;var lo=Object.getOwnPropertySymbols;var Gr=Object.prototype.hasOwnProperty,Xr=Object.prototype.propertyIsEnumerable;var Mt=(s,t,e)=>t in s?qr(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,we=(s,t)=>{for(var e in t||(t={}))Gr.call(t,e)&&Mt(s,e,t[e]);if(lo)for(var e of lo(t))Xr.call(t,e)&&Mt(s,e,t[e]);return s},Nt=(s,t)=>Yr(s,Kr(t));var k=(s,t,e)=>(Mt(s,typeof t!="symbol"?t+"":t,e),e);var Ce=(s,t,e)=>new Promise((i,o)=>{var r=l=>{try{a(e.next(l));}catch(d){o(d);}},n=l=>{try{a(e.throw(l));}catch(d){o(d);}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,n);a((e=e.apply(s,t)).next());});/**
856
+ var qr=Object.defineProperty,Yr=Object.defineProperties;var Kr=Object.getOwnPropertyDescriptors;var lo=Object.getOwnPropertySymbols;var Gr=Object.prototype.hasOwnProperty,Xr=Object.prototype.propertyIsEnumerable;var Mt=(s,t,e)=>t in s?qr(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,we=(s,t)=>{for(var e in t||(t={}))Gr.call(t,e)&&Mt(s,e,t[e]);if(lo)for(var e of lo(t))Xr.call(t,e)&&Mt(s,e,t[e]);return s},Nt=(s,t)=>Yr(s,Kr(t));var k=(s,t,e)=>Mt(s,typeof t!="symbol"?t+"":t,e);var Ce=(s,t,e)=>new Promise((i,o)=>{var r=l=>{try{a(e.next(l));}catch(d){o(d);}},n=l=>{try{a(e.throw(l));}catch(d){o(d);}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,n);a((e=e.apply(s,t)).next());});/**
857
857
  * @license
858
858
  * Copyright (c) 2021 - 2024 Vaadin Ltd.
859
859
  * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, h, g as getElement, c as createEvent, a as getAssetPath } from './index-c24f96b9.js';
2
- import { r as requiredArgs, t as toDate, a as toInteger, _ as _typeof, s as setClientStyling, b as setClientStylingURL, c as setStreamStyling, p as parseISO, i as isBefore } from './lottery-tipping-ticket-buy-04819204.js';
3
- export { d as lottery_segmented, L as lottery_tipping_ticket_buy } from './lottery-tipping-ticket-buy-04819204.js';
2
+ import { r as requiredArgs, t as toDate, a as toInteger, _ as _typeof, s as setClientStyling, b as setClientStylingURL, c as setStreamStyling, p as parseISO, i as isBefore } from './lottery-tipping-ticket-buy-d6e60365.js';
3
+ export { d as lottery_segmented, L as lottery_tipping_ticket_buy } from './lottery-tipping-ticket-buy-d6e60365.js';
4
4
 
5
5
  /**
6
6
  * @name addMilliseconds
package/dist/esm/index.js CHANGED
@@ -1,2 +1,2 @@
1
- export { L as LotteryTippingTicketBuy } from './lottery-tipping-ticket-buy-04819204.js';
1
+ export { L as LotteryTippingTicketBuy } from './lottery-tipping-ticket-buy-d6e60365.js';
2
2
  import './index-c24f96b9.js';
@@ -851,7 +851,7 @@ const LotterySegmented = class {
851
851
  };
852
852
  LotterySegmented.style = LotterySegmentedStyle0;
853
853
 
854
- var qr=Object.defineProperty,Yr=Object.defineProperties;var Kr=Object.getOwnPropertyDescriptors;var lo=Object.getOwnPropertySymbols;var Gr=Object.prototype.hasOwnProperty,Xr=Object.prototype.propertyIsEnumerable;var Mt=(s,t,e)=>t in s?qr(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,we=(s,t)=>{for(var e in t||(t={}))Gr.call(t,e)&&Mt(s,e,t[e]);if(lo)for(var e of lo(t))Xr.call(t,e)&&Mt(s,e,t[e]);return s},Nt=(s,t)=>Yr(s,Kr(t));var k=(s,t,e)=>(Mt(s,typeof t!="symbol"?t+"":t,e),e);var Ce=(s,t,e)=>new Promise((i,o)=>{var r=l=>{try{a(e.next(l));}catch(d){o(d);}},n=l=>{try{a(e.throw(l));}catch(d){o(d);}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,n);a((e=e.apply(s,t)).next());});/**
854
+ var qr=Object.defineProperty,Yr=Object.defineProperties;var Kr=Object.getOwnPropertyDescriptors;var lo=Object.getOwnPropertySymbols;var Gr=Object.prototype.hasOwnProperty,Xr=Object.prototype.propertyIsEnumerable;var Mt=(s,t,e)=>t in s?qr(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,we=(s,t)=>{for(var e in t||(t={}))Gr.call(t,e)&&Mt(s,e,t[e]);if(lo)for(var e of lo(t))Xr.call(t,e)&&Mt(s,e,t[e]);return s},Nt=(s,t)=>Yr(s,Kr(t));var k=(s,t,e)=>Mt(s,typeof t!="symbol"?t+"":t,e);var Ce=(s,t,e)=>new Promise((i,o)=>{var r=l=>{try{a(e.next(l));}catch(d){o(d);}},n=l=>{try{a(e.throw(l));}catch(d){o(d);}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,n);a((e=e.apply(s,t)).next());});/**
855
855
  * @license
856
856
  * Copyright (c) 2021 - 2024 Vaadin Ltd.
857
857
  * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
@@ -1 +1 @@
1
- import{r as t,h as e,g as n,c as r,a as i}from"./index-c24f96b9.js";import{r as o,t as a,a as s,_ as l,s as c,b as h,c as u,p as m,i as b}from"./lottery-tipping-ticket-buy-04819204.js";export{d as lottery_segmented,L as lottery_tipping_ticket_buy}from"./lottery-tipping-ticket-buy-04819204.js";var f={};function g(){return f}function p(t){o(1,arguments);var e=a(t),n=e.getUTCDay(),r=(n<1?7:0)+n-1;return e.setUTCDate(e.getUTCDate()-r),e.setUTCHours(0,0,0,0),e}function y(t){o(1,arguments);var e=a(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=p(r),s=new Date(0);s.setUTCFullYear(n,0,4),s.setUTCHours(0,0,0,0);var l=p(s);return e.getTime()>=i.getTime()?n+1:e.getTime()>=l.getTime()?n:n-1}function v(t,e){var n,r,i,l,c,d,h,u;o(1,arguments);var m=g(),b=s(null!==(n=null!==(r=null!==(i=null!==(l=null==e?void 0:e.weekStartsOn)&&void 0!==l?l:null==e||null===(c=e.locale)||void 0===c||null===(d=c.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==i?i:m.weekStartsOn)&&void 0!==r?r:null===(h=m.locale)||void 0===h||null===(u=h.options)||void 0===u?void 0:u.weekStartsOn)&&void 0!==n?n:0);if(!(b>=0&&b<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=a(t),p=f.getUTCDay(),y=(p<b?7:0)+p-b;return f.setUTCDate(f.getUTCDate()-y),f.setUTCHours(0,0,0,0),f}function w(t,e){var n,r,i,l,c,d,h,u;o(1,arguments);var m=a(t),b=m.getUTCFullYear(),f=g(),p=s(null!==(n=null!==(r=null!==(i=null!==(l=null==e?void 0:e.firstWeekContainsDate)&&void 0!==l?l:null==e||null===(c=e.locale)||void 0===c||null===(d=c.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==i?i:f.firstWeekContainsDate)&&void 0!==r?r:null===(h=f.locale)||void 0===h||null===(u=h.options)||void 0===u?void 0:u.firstWeekContainsDate)&&void 0!==n?n:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var y=new Date(0);y.setUTCFullYear(b+1,0,p),y.setUTCHours(0,0,0,0);var w=v(y,e),x=new Date(0);x.setUTCFullYear(b,0,p),x.setUTCHours(0,0,0,0);var k=v(x,e);return m.getTime()>=w.getTime()?b+1:m.getTime()>=k.getTime()?b:b-1}function x(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}const k=function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return x("yy"===e?r%100:r,e.length)},_=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):x(n+1,2)},S=function(t,e){return x(t.getUTCDate(),e.length)},C=function(t,e){return x(t.getUTCHours()%12||12,e.length)},T=function(t,e){return x(t.getUTCHours(),e.length)},M=function(t,e){return x(t.getUTCMinutes(),e.length)},D=function(t,e){return x(t.getUTCSeconds(),e.length)},z=function(t,e){var n=e.length,r=t.getUTCMilliseconds();return x(Math.floor(r*Math.pow(10,n-3)),e.length)};var B={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear();return n.ordinalNumber(r>0?r:1-r,{unit:"year"})}return k(t,e)},Y:function(t,e,n,r){var i=w(t,r),o=i>0?i:1-i;return"YY"===e?x(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):x(o,e.length)},R:function(t,e){return x(y(t),e.length)},u:function(t,e){return x(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return x(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return x(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return _(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return x(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var i=function(t,e){o(1,arguments);var n=a(t),r=v(n,e).getTime()-function(t,e){var n,r,i,a,l,c,d,h;o(1,arguments);var u=g(),m=s(null!==(n=null!==(r=null!==(i=null!==(a=null==e?void 0:e.firstWeekContainsDate)&&void 0!==a?a:null==e||null===(l=e.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==i?i:u.firstWeekContainsDate)&&void 0!==r?r:null===(d=u.locale)||void 0===d||null===(h=d.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==n?n:1),b=w(t,e),f=new Date(0);return f.setUTCFullYear(b,0,m),f.setUTCHours(0,0,0,0),v(f,e)}(n,e).getTime();return Math.round(r/6048e5)+1}(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):x(i,e.length)},I:function(t,e,n){var r=function(t){o(1,arguments);var e=a(t),n=p(e).getTime()-function(t){o(1,arguments);var e=y(t),n=new Date(0);return n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0),p(n)}(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):x(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):S(t,e)},D:function(t,e,n){var r=function(t){o(1,arguments);var e=a(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime();return Math.floor((n-r)/864e5)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):x(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":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"})}},e:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.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(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"})}},c:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.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(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),i=0===r?7:r;switch(e){case"i":return String(i);case"ii":return x(i,e.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?"noon":0===i?"midnight":i/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,i=t.getUTCHours();switch(r=i>=17?"evening":i>=12?"afternoon":i>=4?"morning":"night",e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return C(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):T(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):M(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):D(t,e)},S:function(t,e){return z(t,e)},X:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();if(0===i)return"Z";switch(e){case"X":return O(i);case"XXXX":case"XX":return P(i);default:return P(i,":")}},x:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return O(i);case"xxxx":case"xx":return P(i);default:return P(i,":")}},O:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+j(i,":");default:return"GMT"+P(i,":")}},z:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+j(i,":");default:return"GMT"+P(i,":")}},t:function(t,e,n,r){return x(Math.floor((r._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,n,r){return x((r._originalDate||t).getTime(),e.length)}};function j(t,e){var n=t>0?"-":"+",r=Math.abs(t),i=Math.floor(r/60),o=r%60;if(0===o)return n+String(i);var a=e||"";return n+String(i)+a+x(o,2)}function O(t,e){return t%60==0?(t>0?"-":"+")+x(Math.abs(t)/60,2):P(t,e)}function P(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t);return r+x(Math.floor(i/60),2)+n+x(i%60,2)}const A=B;var H=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"})}},E=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"})}},G={p:E,P:function(t,e){var n,r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return H(t,e);switch(i){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}}",H(i,e)).replace("{{time}}",E(o,e))}};const N=G;var U=["D","DD"],$=["YY","YYYY"];function I(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 W(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 X,V={date:W({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:W({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:W({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},R={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function q(t){return function(e,n){var r;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var i=t.defaultFormattingWidth||t.defaultWidth,o=null!=n&&n.width?String(n.width):i;r=t.formattingValues[o]||t.formattingValues[i]}else{var a=t.defaultWidth,s=null!=n&&n.width?String(n.width):t.defaultWidth;r=t.values[s]||t.values[a]}return r[t.argumentCallback?t.argumentCallback(e):e]}}function F(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.width,i=e.match(r&&t.matchPatterns[r]||t.matchPatterns[t.defaultMatchWidth]);if(!i)return null;var o,a=i[0],s=r&&t.parsePatterns[r]||t.parsePatterns[t.defaultParseWidth],l=Array.isArray(s)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(a))return e}(s):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(a))return e}(s);return o=t.valueCallback?t.valueCallback(l):l,{value:o=n.valueCallback?n.valueCallback(o):o,rest:e.slice(a.length)}}}const Q={code:"en-US",formatDistance:function(t,e,n){var r,i=Y[t];return r="string"==typeof i?i:1===e?i.one:i.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r},formatLong:V,formatRelative:function(t){return R[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:q({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:q({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:q({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:q({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:q({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:(X={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(X.matchPattern);if(!n)return null;var r=n[0],i=t.match(X.parsePattern);if(!i)return null;var o=X.valueCallback?X.valueCallback(i[0]):i[0];return{value:o=e.valueCallback?e.valueCallback(o):o,rest:t.slice(r.length)}}),era:F({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:F({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:F({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:F({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:F({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 J=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,K=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Z=/^'([^]*?)'?$/,tt=/''/g,et=/[a-zA-Z]/;function nt(t,e,n){var r,i,c,d,h,u,m,b,f,p,y,v,w,x,k,_,S,C;o(2,arguments);var T=String(e),M=g(),L=null!==(r=null!==(i=null==n?void 0:n.locale)&&void 0!==i?i:M.locale)&&void 0!==r?r:Q,D=s(null!==(c=null!==(d=null!==(h=null!==(u=null==n?void 0:n.firstWeekContainsDate)&&void 0!==u?u:null==n||null===(m=n.locale)||void 0===m||null===(b=m.options)||void 0===b?void 0:b.firstWeekContainsDate)&&void 0!==h?h:M.firstWeekContainsDate)&&void 0!==d?d:null===(f=M.locale)||void 0===f||null===(p=f.options)||void 0===p?void 0:p.firstWeekContainsDate)&&void 0!==c?c:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var z=s(null!==(y=null!==(v=null!==(w=null!==(x=null==n?void 0:n.weekStartsOn)&&void 0!==x?x:null==n||null===(k=n.locale)||void 0===k||null===(_=k.options)||void 0===_?void 0:_.weekStartsOn)&&void 0!==w?w:M.weekStartsOn)&&void 0!==v?v:null===(S=M.locale)||void 0===S||null===(C=S.options)||void 0===C?void 0:C.weekStartsOn)&&void 0!==y?y:0);if(!(z>=0&&z<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!L.localize)throw new RangeError("locale must contain localize property");if(!L.formatLong)throw new RangeError("locale must contain formatLong property");var B=a(t);if(!function(t){if(o(1,arguments),!function(t){return o(1,arguments),t instanceof Date||"object"===l(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=a(t);return!isNaN(Number(e))}(B))throw new RangeError("Invalid time value");var j=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()}(B),O=function(t,e){return o(2,arguments),function(t,e){o(2,arguments);var n=a(t).getTime(),r=s(e);return new Date(n+r)}(t,-s(e))}(B,j),P={firstWeekContainsDate:D,weekStartsOn:z,locale:L,_originalDate:B};return T.match(K).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,N[e])(t,L.formatLong):t})).join("").match(J).map((function(r){if("''"===r)return"'";var i,o,a=r[0];if("'"===a)return(o=(i=r).match(Z))?o[1].replace(tt,"'"):i;var s=A[a];if(s)return null!=n&&n.useAdditionalWeekYearTokens||-1===$.indexOf(r)||I(r,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!(-1!==U.indexOf(r))||I(r,e,String(t)),s(O,r,L.localize,P);if(a.match(et))throw new RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");return r})).join("")}const rt=class{constructor(e){t(this,e),this.show=()=>this.visible=!0,this.hide=()=>this.visible=!1,this.visible=!1}componentDidLoad(){this.trigger=this.host.querySelector('[slot="trigger"]'),this.trigger&&(this.trigger.addEventListener("mouseenter",this.show),this.trigger.addEventListener("mouseleave",this.hide),this.trigger.addEventListener("focus",this.show),this.trigger.addEventListener("blur",this.hide))}disconnectedCallback(){this.trigger&&(this.trigger.removeEventListener("mouseenter",this.show),this.trigger.removeEventListener("mouseleave",this.hide),this.trigger.removeEventListener("focus",this.show),this.trigger.removeEventListener("blur",this.hide))}render(){return e("div",{key:"e56695ac60fcd7903127179423e9954ef40f05c0",class:"tooltip-wrapper"},e("slot",{key:"4e2472a395ceeb2b911692739d326c031df07e29",name:"trigger"}),e("div",{key:"f77bd72da94eb17d12e42ebb86c395c55801b728",class:{"tooltip-content-wrapper":!0,visible:this.visible}},e("div",{key:"988399e2b42988622d46eaf255f17c6221eb9697",class:"tooltip-content"},e("slot",{key:"05de0572ab1331d965e61947c5c15775e225197a",name:"content"}))))}get host(){return n(this)}};rt.style=":host{display:inline-flex;position:relative}.tooltip-wrapper{position:relative;display:inline-flex}.tooltip-content-wrapper{position:absolute;z-index:10;bottom:125%;left:50%;transform:translateX(-50%);opacity:0;visibility:hidden;transition:opacity 0.2s, visibility 0.2s}.tooltip-content-wrapper.visible{opacity:1;visibility:visible}.tooltip-content{background-color:var(--emw--tooltip-background-color, #000);color:var(--emw--tooltip-text-color, #fff);border-radius:4px;box-shadow:0 2px 8px rgba(0, 0, 0, 0.15);white-space:nowrap;padding:4px}";const it=class{constructor(e){t(this,e),this.countDownChange=r(this,"countDownChange",7),this.countDownFinish=r(this,"countDownFinish",7),this.value=void 0,this.format="HH:mm:ss",this.prefix=void 0,this.suffix=void 0,this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.endTime=void 0,this.timeObj={day:{str:"00",unit:""},hour:{str:"00",unit:""},minute:{str:"00",unit:""},second:{str:"00",unit:""}}}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}handleValueChange(t){this.setEndTime(t),t?this.startCountDown():this.clearCountDown()}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl)),this.setEndTime(this.value),this.value&&this.startCountDown()}setEndTime(t){if("string"==typeof t){const e=m(t).getTime();this.endTime=isNaN(e)?null:e}else this.endTime=t}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe(),this.clearCountDown()}startCountDown(){this.clearCountDown(),this.tick(),this.timer=setInterval((()=>{this.tick()}),1e3)}clearCountDown(){this.timer&&(clearInterval(this.timer),this.timer=null)}tick(){if(!this.endTime)return;let t=this.endTime-Date.now();t<=0&&(t=0,this.clearCountDown(),this.countDownFinish.emit());const e=Math.floor(t/864e5),n=Math.floor(t/36e5%24),r=Math.floor(t/1e3/60%60),i=Math.floor(t/1e3%60),o=t=>t<10?`0${t}`:`${t}`;this.timeObj={day:{str:o(e),unit:"d"},hour:{str:o(n),unit:"h"},minute:{str:o(r),unit:"m"},second:{str:o(i),unit:"s"}};const a=this.getFormatTime();this.countDownChange.emit({leftTime:t,formatTime:a,legalTime:a})}getFormatTime(){return this.format.replace("DD",this.timeObj.day.str).replace("HH",this.timeObj.hour.str).replace("mm",this.timeObj.minute.str).replace("ss",this.timeObj.second.str)}renderItems(){const t=/(DD|HH|mm|ss)|([\s\S]+?)(?=(DD|HH|mm|ss)|$)/g,n=[];let r;for(;null!==(r=t.exec(this.format));)if(r[1]){let t="";switch(r[1]){case"DD":t=this.timeObj.day.str;break;case"HH":t=this.timeObj.hour.str;break;case"mm":t=this.timeObj.minute.str;break;case"ss":t=this.timeObj.second.str}n.push({val:t,unit:""})}else r[2]&&n.length>0&&(n[n.length-1].unit=r[2]);return n.map(((t,n)=>e("div",{key:n+t.unit,class:"helper-count-down-item",part:"item"},e("div",{class:"helper-count-down-item-num"},t.val),e("div",{class:"helper-count-down-item-unit"},t.unit))))}render(){return e("div",{key:"b360412e045020b5ac0263c6ca56458f31eedb2c",class:"helper-count-down-container",ref:t=>this.stylingContainer=t},e("slot",{key:"c72bed87fba869c842407b04e0cbfe038e5b7ea8"}),this.prefix&&e("div",{key:"8d3ba9d60577421f81bae7bc76f52a774b17e1fe",class:"helper-count-down-prefix"},this.prefix),e("div",{key:"187edf3b8eb6de85efe1a748fd8ef47a68e19611",class:"helper-count-down-values",part:"values"},this.renderItems()),this.suffix&&e("div",{key:"3a8e5d9561ecd3f52eff423bd43c8b60a261a17c",class:"helper-count-down-suffix"},this.suffix))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],value:["handleValueChange"]}}};it.style=":host{display:block}.helper-count-down-container{display:flex;align-items:center}.helper-count-down-prefix{margin-right:4px}.helper-count-down-suffix{margin-left:4px}.helper-count-down-values{display:flex;align-items:center}.helper-count-down-item{display:flex;align-items:center;justify-content:center}.helper-count-down-item-num{font-variant-numeric:tabular-nums}";const ot=["ro","en","fr","ar","hr"],at={en:{stop:"Stop",at:"at",turnover:"Turnover: ",startIn:"Sales Start in:"},ro:{stop:"Oprește",at:"la"},fr:{stop:"Arrêtez",at:"à"},ar:{stop:"توقف",at:"في"},hr:{stop:"Stop",at:"u"}},st=(t,e)=>{const n=e;return at[void 0!==n&&ot.includes(n)?n:"en"][t]},lt=class{constructor(e){t(this,e),this.lotteryBannerWagerStarted=r(this,"lotteryBannerWagerStarted",7),this.handleCountdownFinish=()=>{this.isWagerStarted=!0,this.lotteryBannerWagerStarted.emit()},this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.language="en",this.logoUrl=void 0,this.stopTime="",this.startTime="",this.bannerTitle=void 0,this.turnover=void 0,this.layout="logo,title,info",this.isWagerStarted=!1,this.formattedStopTime=void 0}handleClientStylingChange(t,e){t!==e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!==e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!==e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}handleTimeChange(){this.checkWagerStatus()}async componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])at[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl),this.checkWagerStatus()}checkWagerStatus(){this.isWagerStarted=!this.startTime||!b(new Date,m(this.startTime)),this.stopTime&&(this.formattedStopTime=nt(m(this.stopTime),"dd/MM/yyyy HH:mm"))}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}renderElement(t,n=""){const r=i("../static/poolGameLogo.webp");switch(t){case"logo":return e("div",{class:`lottery-banner__logo-wrapper ${n}`},r&&e("img",{alt:"logo",src:r,class:"lottery-banner__logo"}));case"title":return this.bannerTitle&&e("div",{class:`lottery-banner__title ${n}`},this.bannerTitle);case"info":return e("div",{class:`lottery-banner__info ${n}`},this.isWagerStarted?e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},e("span",{class:"lottery-banner__info-item-label__strong"},st("stop",this.language))," ",st("at",this.language)),e("span",{class:"lottery-banner__info-item-value"},this.formattedStopTime)):e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},e("span",{class:"lottery-banner__info-item-label__strong"},st("startIn",this.language))," "),e("helper-count-down",{class:"lottery-banner__info-item-value lottery-banner__info-item-value__strong",value:this.startTime,format:"DDD HHH mmM ssS",onCountDownFinish:this.handleCountdownFinish})),this.isWagerStarted&&null!=this.turnover&&e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},st("turnover",this.language)),e("span",{class:"lottery-banner__info-item-value"},this.turnover)));default:return null}}render(){const t=this.layout.split(",").map((t=>t.trim()));return e("section",{key:"8714d4136821b8afd6079da769bb9cc94149ed9d",ref:t=>this.stylingContainer=t,class:"lottery-banner"},t.map(((e,n)=>this.renderElement(e,3===t.length&&1===n?"lottery-banner__item--center":""))))}static get assetsDirs(){return["../static"]}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],startTime:["handleTimeChange"],stopTime:["handleTimeChange"]}}};lt.style=":host {\n display: block;\n container-type: inline-size;\n}\n\n.lottery-banner {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--lottery-banner-gap, 0.5rem);\n padding: var(--lottery-banner-padding, 0px 20px);\n background: var(--lottery-banner-background, var(--emw--color-primary, #fed275));\n border-top: var(--lottery-banner-border-width, 2px) var(--lottery-banner-border-style, solid) var(--lottery-banner-border-color, var(--emw--color-primary, #fed275));\n border-bottom: var(--lottery-banner-border-width, 2px) var(--lottery-banner-border-style, solid) var(--lottery-banner-border-color, var(--emw--color-primary, #fed275));\n border-left: var(--lottery-banner-border-left, none);\n border-right: var(--lottery-banner-border-right, none);\n border-radius: var(--lottery-banner-border-radius, 0);\n white-space: nowrap;\n height: var(--lottery-banner-height, 50px);\n position: relative;\n box-sizing: border-box;\n}\n\n.lottery-banner__logo-wrapper {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n}\n.lottery-banner__logo-wrapper img {\n height: 100%;\n max-width: 32vw;\n object-fit: var(--lottery-banner-logo-object-fit, contain);\n}\n\n.lottery-banner__item--center {\n position: absolute;\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n}\n\n.lottery-banner__title {\n text-align: center;\n font-size: var(--lottery-banner-title-font-size, 1.5rem);\n font-weight: 800;\n font-style: italic;\n letter-spacing: var(--lottery-banner-title-font-letter-spacing, 0.04em);\n color: var(--emw--color-typography, #000);\n}\n\n.lottery-banner__info {\n display: flex;\n align-items: center;\n gap: var(--lottery-banner-info-gap, 0.75rem);\n}\n\n.lottery-banner__info-item {\n font-size: var(--lottery-banner-info-font-size, 0.9rem);\n color: var(--lottery-banner-info-color, var(--emw--color-typography, #000));\n display: inline-flex;\n align-items: center;\n gap: 0.3rem;\n}\n\n.lottery-banner__info-item-label {\n color: var(--lottery-banner-info-label-color, var(--emw--color-typography, #000));\n}\n.lottery-banner__info-item-label__strong {\n font-weight: var(--lottery-banner-info-label-font-weight, 700);\n}\n\n.lottery-banner__info-item-value {\n font-weight: var(--lottery-banner-info-value-font-weight, inherit);\n color: var(--lottery-banner-info-value-color, var(--emw--color-typography, #000));\n}\n.lottery-banner__info-item-value__strong {\n font-weight: var(--lottery-banner-info-label-font-weight, 700);\n}\n\nhelper-count-down::part(values) {\n gap: 8px;\n}\n\n@container (max-width: 700px) {\n .lottery-banner {\n height: auto;\n padding: var(--lottery-banner-mobile-padding, 0.5rem 0.2rem);\n }\n .lottery-banner__title {\n flex-basis: 100%;\n text-align: var(--lottery-banner-mobile-title-text-align, left);\n font-size: var(--emw--font-size-small, 0.875rem);\n }\n .lottery-banner__info {\n flex-direction: column;\n align-items: flex-start;\n gap: var(--lottery-banner-mobile-info-gap, 0.1rem);\n }\n .lottery-banner__info-item {\n font-size: var(--emw--font-size-x-small, 0.75rem);\n }\n}";const ct=["ro","en","fr","ar","hr","zh"],dt={en:{loading:"Loading"},ro:{},fr:{},ar:{},hr:{}},ht=class{constructor(e){t(this,e),this.handleClick=t=>{if(this.disabled)return;const e=this.host.shadowRoot.querySelector(".btn");if(!e)return;const n=e.getBoundingClientRect(),r=Math.max(n.width,n.height),i={top:t.clientY-n.top-r/2,left:t.clientX-n.left-r/2,size:r};this.ripples=[...this.ripples,i],setTimeout((()=>{this.ripples=this.ripples.filter((t=>t!==i))}),600)},this.variant="primary",this.size="medium",this.color=void 0,this.disabled=!1,this.loading=!1,this.text=void 0,this.mbSource=void 0,this.language="en",this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.ripples=[]}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])dt[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}render(){const{variant:t,disabled:n,size:r,color:i}=this,o=n||this.loading,a={};if(i)switch(t){case"primary":default:Object.assign(a,{backgroundColor:i,borderColor:i});break;case"outline":case"dashed":Object.assign(a,{color:i,borderColor:i});break;case"text":Object.assign(a,{color:i})}return e("button",{key:"aa74ad98c90e7548228557bf8a8d26b125d4a83a",class:{btn:!0,[`btn--${t}`]:!0,[`btn--${r}`]:!0,"btn--loading":this.loading},style:i?a:void 0,disabled:o,onClick:this.handleClick,ref:t=>this.stylingContainer=t},this.loading?e("div",{class:"loading-container"},e("span",{class:"content"},this.text||(()=>{const t=this.language;let e=dt[void 0!==t&&ct.includes(t)?t:"en"].loading;return e})()),e("span",{class:"spinner"})):e("span",{class:"content"},e("slot",{name:"icon-left"}),this.text||e("slot",null),e("slot",{name:"icon-right"})),e("div",{key:"302ea02be395bb24989d4abc040a513e23fa029a",class:"ripple-container"},this.ripples.map(((t,n)=>e("span",{key:n,class:"ripple",style:{top:`${t.top}px`,left:`${t.left}px`,width:`${t.size}px`,height:`${t.size}px`}})))))}get host(){return n(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};var ut;ht.style=":host{display:inline-block}.btn{font:inherit;position:relative;display:inline-flex;align-items:center;justify-content:center;border:1px solid transparent;border-radius:var(--lottery-button-border-radius, 6px);font-weight:var(--lottery-button-font-weight, 500);cursor:pointer;outline:none;overflow:hidden;transition:var(--lottery-button-transition, background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s);user-select:none;-webkit-tap-highlight-color:transparent;box-shadow:var(--lottery-button-box-shadow, 0 2px 4px 0 rgba(0, 0, 0, 0.5))}.btn .content{position:relative;display:inline-flex;align-items:center;gap:var(--lottery-button-content-gap, 0.5em)}.btn .content ::slotted(span){display:inline-flex;align-items:center}.btn:hover:not(:disabled){box-shadow:var(--lottery-button-hover-box-shadow, 0 4px 8px 0 rgba(0, 0, 0, 0.5))}.btn:disabled{cursor:not-allowed;opacity:var(--lottery-button-disabled-opacity, 0.5)}.btn .loading-container{display:flex;align-items:center}.btn--loading{position:relative}.btn .spinner{display:inline-block;width:1em;height:1em;border:var(--lottery-button-spinner-border, 2px solid rgba(255, 255, 255, 0.3));border-radius:50%;border-top-color:var(--lottery-button-spinner-color, white);animation:spin 1s ease-in-out infinite;margin-left:0.5em;vertical-align:middle}.btn--small .spinner{width:0.8em;height:0.8em}.btn--large .spinner{width:1.2em;height:1.2em}@keyframes spin{to{transform:rotate(360deg)}}.btn--primary{background-color:var(--emw--color-primary, #0d196e);color:var(--emw--color-typography-inverse, #fff)}.btn--primary:hover:not(:disabled){background-color:var(--emw--color-primary-variant, #1367e7)}.btn--primary:active:not(:disabled){background-color:var(--lottery-button-primary-active-bg, #08104a)}.btn--outline .spinner,.btn--dashed .spinner,.btn--text .spinner{border-top-color:currentColor;border-color:var(--lottery-button-spinner-inverse-border-color, rgba(0, 0, 0, 0.2))}.btn--outline{background-color:var(--emw--color-background, #fff);border-color:var(--lottery-button-outline-border-color, #dcdcdc);color:var(--emw--color-typography, #000)}.btn--outline:hover:not(:disabled){background-color:var(--emw--color-background-tertiary, #ccc);border-color:var(--lottery-button-outline-hover-border-color, #a6a6a6)}.btn--outline:active:not(:disabled){background-color:var(--lottery-button-outline-active-bg, #e6e6e6)}.btn--dashed{background-color:transparent;border-style:dashed;border-color:var(--lottery-button-dashed-border-color, #dcdcdc);color:var(--lottery-button-dashed-color, #333)}.btn--dashed:hover:not(:disabled){border-color:var(--lottery-button-dashed-hover-border-color, #a6a6a6);color:var(--lottery-button-dashed-hover-color, #0052d9)}.btn--text{background-color:transparent;color:var(--lottery-button-text-color, #0052d9);border-color:transparent}.btn--text:hover:not(:disabled){background-color:var(--lottery-button-text-hover-bg, #f2f2f2)}.btn--text:active:not(:disabled){background-color:var(--lottery-button-text-active-bg, #e6e6e6)}.btn--custom-color:hover:not(:disabled){opacity:var(--lottery-button-custom-hover-opacity, 0.9)}.btn--custom-color:active:not(:disabled){opacity:var(--lottery-button-custom-active-opacity, 0.8)}.btn--small{height:var(--lottery-button-small-height, 28px);font-size:var(--lottery-button-small-font-size, 12px);padding:var(--lottery-button-small-padding, 0 12px)}.btn--medium{height:var(--lottery-button-medium-height, 34px);font-size:var(--lottery-button-medium-font-size, 14px);padding:var(--lottery-button-medium-padding, 0 18px)}.btn--large{height:var(--lottery-button-large-height, 40px);font-size:var(--lottery-button-large-font-size, 16px);padding:var(--lottery-button-large-padding, 0 24px)}.ripple-container{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;pointer-events:none;border-radius:inherit}.ripple{position:absolute;border-radius:50%;background-color:var(--lottery-button-ripple-light, rgba(255, 255, 255, 0.3));transform:scale(0);animation:ripple-animation 600ms linear}.btn--outline .ripple,.btn--dashed .ripple,.btn--text .ripple{background-color:var(--lottery-button-ripple-dark, rgba(0, 0, 0, 0.03))}@keyframes ripple-animation{to{transform:scale(4);opacity:0}}",function(t){t.PURCHASED="Purchased",t.SETTLED="Settled",t.CANCELED="Canceled",t.ERROR="Error"}(ut||(ut={}));const mt=class{constructor(e){t(this,e),this.orderSummarySubmit=r(this,"orderSummarySubmit",7),this.submitSuccess=r(this,"lotteryTicketSubmitSuccess",7),this.submitError=r(this,"lotteryTicketSubmitError",7),this.sessionExpired=r(this,"sessionExpired",7),this.endpoint=void 0,this.sessionId=void 0,this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.language="en",this.orderSummaryTitle=void 0,this.ticketsLabel=void 0,this.totalLabel=void 0,this.showColon=!0,this.showDivider=!1,this.submitDisabled=!1,this.submitButtonText=void 0,this.submitLoading=!1}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}handleLotteryTicketParamsReady(t){if(t.detail&&this.isValidTicketSubmitParam(t.detail))this.handleSubmitTickets(t.detail);else{const e="Invalid ticket data received before submission.";console.error(e,t.detail),this.submitError.emit({message:e,dataOrigin:t.detail,status:400})}}isValidTicketSubmitParam(t){return t&&Array.isArray(t.tickets)&&t.tickets.length>0&&t.tickets.every((t=>this.isValidTicketParam(t)))}isValidTicketParam(t){return t&&void 0!==t.gameName&&void 0!==t.startingDrawId&&void 0!==t.amount&&void 0!==t.currency&&void 0!==t.selection}async handleSubmitTickets(t){try{this.submitLoading=!0;const e=await function(t,e="GET",n=null,r={}){return new Promise(((i,o)=>{const a="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)})),s=Object.assign({"Content-Type":"application/json"},r);"GET"!==e&&"HEAD"!==e&&(s["X-Idempotency-Key"]=a);const l={method:e,headers:s,body:null};n&&"GET"!==e&&"HEAD"!==e?l.body=JSON.stringify(n):delete l.body,fetch(t,l).then((t=>t.ok?t.json():o(t))).then((t=>i(t))).catch((t=>o(t)))}))}(`${this.endpoint}/tickets`,"POST",t,{Authorization:`Bearer ${this.sessionId}`});e.tickets.every((t=>t.state===ut.PURCHASED))?this.submitSuccess.emit({dataOrigin:e,status:200}):this.submitError.emit({message:"Failed to purchase ticket",dataOrigin:e,status:200})}catch(t){401===t.status&&this.sessionExpired.emit(),(t.status>300||!t.status)&&this.submitError.emit({dataOrigin:t,status:t.status||0})}finally{this.submitLoading=!1}}handleSubmit(){this.orderSummarySubmit.emit()}render(){return e("div",{key:"bdab321b9336f47e16057d240b3226d7cba59b97",ref:t=>this.stylingContainer=t},e("div",{key:"de7ffcc9f96d8c7cfc7bdb3a3c7225ee78c33483",class:"order-summary"},e("h3",{key:"9500cd69a6eba0855d4981cdad8eaa91b9c98567",class:"order-summary__title"},this.orderSummaryTitle),e("div",{key:"ce29c82eef1d12bc63e94e4fa2d5474700860af2",class:"order-summary__ticket"},e("div",{key:"9db79da17590c7f847f46c3b3b66489ea9a0e268",class:"order-summary__ticket-info"},e("div",{key:"4b5a2df807aeb421cf3c1ebf33f410a92f39ccaf",class:"order-summary__ticket-label"},e("div",{key:"feb73e9f849d2e3d6b77e4c848657f27e6a82323",class:"order-summary__ticket"},this.ticketsLabel),e("span",{key:"51f70dcdda2154d8ce97d8e1a7c0f61a6198afbb",class:"order-summary__colon"},this.showColon?":":null)),e("div",{key:"4fed2d63cd7a881c8844055fe1fde99c8c7aa9fb",class:"order-summary__details"},e("slot",{key:"6a7969738546ee4aca81a075f6174556e78d2c31",name:"orderSummaryTicketDetail"}))),this.showDivider&&e("hr",{key:"029803fa93960d5098a24d5ca18e77e14562b29f",class:"order-summary__divider"}),e("div",{key:"738096c5b605a97851dbf24a972d93d9533ad48b",class:"order-summary__ticket-info"},e("div",{key:"acd8a7f3e64c97f58c79f57a90143151c996abf8",class:"order-summary__ticket-label"},e("div",{key:"44e6b29978ca4fc2b22ca9d95ee4facfc883f292",class:"order-summary__ticket"},this.totalLabel),e("span",{key:"330a00a4b39e578a1b0d80211d2b68d44c5235c9",class:"order-summary__colon"},this.showColon?":":null)),e("span",{key:"294046815a62a80366458aade4ec5d5476577a93",class:"order-summary__details"},e("slot",{key:"02d129ef0caf523ec0c9da34318df46d3b008376",name:"orderSummaryTotalDetail"})))),e("slot",{key:"9395396883f0594ad8db216a9aa9fa0aeff45c10",name:"orderSummaryChoice"}),e("div",{key:"462672abc490cde00fea90ea585f48875ca2ec47",class:"order-summary__button-wrapper"},e("lottery-button",{key:"1885bee3570ce6b58d4ae1977c635f418485fdbe",onClick:this.handleSubmit.bind(this),loading:this.submitLoading,disabled:this.submitDisabled,text:this.submitButtonText}))))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};mt.style=":host{width:100%}.order-summary{width:100%;background:var(--emw--color-background, #fff);border-radius:var(--lottery-order-summary-border-radius, 8px);border:var(--lottery-order-summary-border, none);box-shadow:var(--lottery-order-summary-box-shadow, none);box-sizing:border-box}.order-summary__title{margin:var(--lottery-order-summary-title-margin, 0 0 30px 0);text-align:var(--lottery-order-summary-title-text-align, center);color:var(--emw--color-typography, #000);text-transform:uppercase;font-weight:var(--lottery-order-summary-title-font-weight, 700)}.order-summary__ticket-info{display:flex;align-items:center;margin-bottom:var(--lottery-order-summary-row-gap, 16px);gap:var(--lottery-order-summary-col-gap, 10px);color:var(--emw--color-typography, #000)}.order-summary__ticket-label{display:flex;flex-direction:row;align-items:center;width:var(--lottery-order-summary-label-width, 50px);max-width:var(--lottery-order-summary-label-max-width, 100%);flex-shrink:0}.order-summary__colon{margin-left:2px}.order-summary__ticket{font-weight:var(--lottery-order-summary-label-font-weight, 500);color:var(--emw--color-typography, #000);overflow-wrap:break-word}.order-summary__details{display:flex;align-items:center;color:var(--emw--color-typography, #000);font-weight:var(--lottery-order-summary-details-font-weight, 400)}.order-summary__divider{border:none;border-top:var(--lottery-order-summary-divider-border, 1px solid var(--emw--color-gray-100, #e6e6e6));margin:var(--lottery-order-summary-divider-margin, 20px 0)}.order-summary__button-wrapper{display:flex;justify-content:center;margin:var(--lottery-order-summary-button-wrapper-margin, 0);padding:var(--lottery-order-summary-button-wrapper-padding, 0)}";const bt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 256H736v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zm-200 0H360v-72h304v72z"}}]},name:"delete",theme:"filled"},ft={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"},gt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"},pt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},yt={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},vt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"plus-square",theme:"outlined"},wt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"};var xt=function(){return xt=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},xt.apply(this,arguments)},kt={primaryColor:"#333",secondaryColor:"#E6E6E6"};function _t(t,e){if(void 0===e&&(e={}),"function"==typeof t.icon){var n=e.placeholders||kt;return St(t.icon(n.primaryColor,n.secondaryColor),e)}return St(t.icon,e)}function St(t,e){var n="svg"===t.tag?xt(xt({},t.attrs),e.extraSVGAttrs||{}):t.attrs,r=Object.keys(n).reduce((function(t,e){var r=n[e],i="".concat(e,'="').concat(r,'"');return t.push(i),t}),[]),i=r.length?" "+r.join(" "):"",o=(t.children||[]).map((function(t){return St(t,e)})).join("");return o&&o.length?"<".concat(t.tag).concat(i,">").concat(o,"</").concat(t.tag,">"):"<".concat(t.tag).concat(i," />")}const Ct=class{constructor(e){t(this,e),this.lotteryBulletClickHandler=r(this,"lotteryBulletClick",7),this.value=0,this.text=void 0,this.idx=void 0,this.type="toggle",this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.hasBorder=!0,this.hasBackground=!0,this.deleteIconSvg="",this.deleteIconWidth="16px",this.deleteIconHeight="16px"}handleClientStylingChange(t,e){t!==e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!==e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!==e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}handleClick(){"disabled"!==this.type&&"readonly"!==this.type&&(console.log("bullet clicked",this.type,this.idx,this.text,this.value),this.lotteryBulletClickHandler.emit({type:this.type,idx:this.idx,text:this.text,value:this.value}))}render(){let t;return t=this.deleteIconSvg?function(t){let e=t.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,"");return e=e.replace(/on[a-z]+=[\"'][^\"']*[\"']/gi,""),e=e.replace(/javascript:/gi,""),e}(this.deleteIconSvg):_t(bt,{extraSVGAttrs:{width:this.deleteIconWidth,height:this.deleteIconHeight,fill:"currentColor"}}),e("div",{key:"0d1e8aaa80a907a7467410f6b27b4b6175e82299",class:"lottery-selection",ref:t=>this.stylingContainer=t},e("button",{key:"11a2402abbc290dc877ad95f3433092c3a0d8419",class:{"lottery-selection__button":!0,"lottery-selection__button--selected":1==this.value,"lottery-selection__button--disabled":"disabled"===this.type,"lottery-selection__button--no-border":!this.hasBorder,"lottery-selection__button--no-background":!this.hasBackground,isDeleteByIcon:"delete"===this.type,isCallDialogBtn:"input"===this.type||"readonly"===this.type},onClick:this.handleClick.bind(this),disabled:"disabled"===this.type},"delete"===this.type&&e("span",{key:"f99001d936a8f7bdf8adc5c46e82caf730a9442a",class:"lottery-selection__delete-icon",innerHTML:t}),e("span",{key:"55775e2492a1fe45cc8a457ac0a0d206744461ab",class:"lottery-selection__text"},this.text)))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};Ct.style=":host{display:inline-block}.lottery-selection__button{display:flex;align-items:center;justify-content:center;width:var(--lottery-selection-width, 32px);height:var(--lottery-selection-height, 32px);padding:var(--lottery-selection-padding, 0);box-sizing:border-box;background:var(--lottery-selection-background, var(--emw--color-background, #fff));border:var(--lottery-selection-border-width, 2px) var(--lottery-selection-border-style, solid) var(--lottery-selection-border-color, var(--emw--color-primary, #0d196e));border-radius:var(--lottery-selection-border-radius, var(--emw--border-radius-medium, 8px));color:var(--lottery-selection-color, var(--emw--color-typography, #000));font-weight:var(--lottery-selection-font-weight, bold);font-size:var(--lottery-selection-font-size, 1em);cursor:pointer;user-select:none;}.lottery-selection__button:hover{background:var(--lottery-selection-hover-background, var(--emw--color-background, #fff));border-color:var(--lottery-selection-hover-border-color, var(--emw--color-primary, #0d196e));color:var(--lottery-selection-hover-color, var(--emw--color-typography, #000))}.lottery-selection__button .lottery-selection__delete-icon{display:none}.lottery-selection__button.isDeleteByIcon:hover .lottery-selection__text{display:none}.lottery-selection__button.isDeleteByIcon:hover .lottery-selection__delete-icon{display:flex;align-items:center;justify-content:center;fill:var(--lottery-selection-delete-icon-color, var(--emw--color-typography, #000));vertical-align:middle}.lottery-selection__button.lottery-selection__button--selected{background-color:var(--lottery-selection-selected-background, var(--emw--color-primary, #0d196e));border-color:var(--lottery-selection-selected-border-color, var(--emw--color-primary, #0d196e));color:var(--lottery-selection-selected-color, var(--emw--color-typography-inverse, #fff))}.lottery-selection__button.lottery-selection__button--disabled{background-color:var(--lottery-selection-disabled-background, var(--emw--color-gray-50, #f5f5f5));border-color:var(--lottery-selection-disabled-border-color, var(--emw--color-gray-100, #e6e6e6));color:var(--lottery-selection-disabled-color, var(--emw--color-gray-150, #6f6f6f));cursor:not-allowed;pointer-events:none;}.lottery-selection__button.lottery-selection__button--no-border{border:none}.lottery-selection__button.lottery-selection__button--no-background{background:transparent}";const Tt=["ro","en","fr","ar","hr","zh"],Mt={en:{noTicketBoard:"No ticket board available.",selectionCleared:"Your selection has been cleared.",clearAll:"Clear All",stopAt:"Stop at",turnover:"Turnover: ",pleaseFillIn:"Please fill in all the selection input!",fillIn:"Fill in",noBets:"Sorry. No bets have been placed so far. Check back later!",search:"Search",clear:"Clear",oddsChart:"Odds Chart",ticketSuccess:"Ticket purchased successfully.",stakePerLine:"Stake per Line:",lowestOdds:"Lowest Odds:",highestOdds:"Highest Odds:",orderSummary:"ORDER SUMMARY",ticket:"Ticket",lines:"Lines",total:"Total",submit:"Submit",loading:"Loading",enterValidNumber:"Please enter a valid number.",enterNumberBetween:"Please enter a number between {min} and {max}.",numberAlreadySelected:"This number has already been selected.",enterScoreUpTo:"Please enter the score (Up to {maxScore})",enterValue:"Please enter a value",myChoices:"My Choices",teams:"Teams",scores:"Scores",euro:"Euro",cancel:"Cancel",confirm:"Confirm"},ro:{},fr:{},ar:{},hr:{}},Lt=(t,e,n)=>{const r=e;let i=Mt[void 0!==r&&Tt.includes(r)?r:"en"][t];return n&&Object.keys(n).forEach((t=>{i=i.replace(`{${t}}`,n[t])})),i};function Dt(t,e){return new Set(t?t.split(e):[])}function zt(t,e){return e.filter((e=>e!==t))}function Bt(t,e){return e.concat([t])}const jt=class{constructor(e){t(this,e),this.bulletGroupUpdateSelectedBulletTexts=r(this,"bulletGroupUpdateSelection",7),this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.language="en",this.translationUrl="",this.splitToken=",",this.selectionGroupId=void 0,this.selectionGroupLabel=void 0,this.type="bet",this.selectedBulletTexts=null,this.maxSelectedCount=null,this.maxDisplayBulletsCount=11,this.bulletTexts=null,this.maxIntegerBulletText=null,this.minIntegerBulletText=0,this.bulletTextType="integer",this.hasBorder=!0,this.hasBackground=!0,this.dialogTitle=void 0,this.dialogInputPlaceholder=void 0,this.disabledBulletTexts="",this.dialogConfig={width:"400px",visible:!1,onConfirm:()=>this.handleFillInAddMore(),onCancel:()=>this.handleCloseAddMoreDialog()},this.inputInfo={valid:!0,errorMessage:"",value:""}}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentWillLoad(){var t;this.translationUrl&&(t=JSON.parse(this.translationUrl),Object.keys(t).forEach((e=>{for(let n in t[e])Mt[e][n]=t[e][n]})))}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}lotteryBulletClickHandler(t){if(t.stopPropagation(),"input"!==t.detail.type)if(["delete","toggle"].includes(t.detail.type))this.bulletGroupUpdateSelectedBulletTexts.emit({newSelectedBulletTexts:(e=t.detail,n=Array.from(this.selectedSet),r=this.maxSelectedCount,"delete"===e.type?zt(e.text,n):"toggle"===e.type?n.includes(e.text)?zt(e.text,n):n.length>=r?function(t,e,n){return e.slice(e.length-(n-1)).concat([t])}(e.text,n,r):Bt(e.text,n):[]).join(this.splitToken),selectionGroupId:this.selectionGroupId});else var e,n,r;else this.dialogConfig=Object.assign(Object.assign({},this.dialogConfig),{visible:!0})}get selectedSet(){return Dt(this.selectedBulletTexts,this.splitToken)}get disabledSet(){return Dt(this.disabledBulletTexts,this.splitToken)}get bulletTextsSet(){return this.bulletTexts?Dt(this.bulletTexts,this.splitToken):"integer"===this.bulletTextType&&null!=this.maxIntegerBulletText?Dt(Array.from({length:Number(this.lastDisplayBulletText)-this.minIntegerBulletText+1},((t,e)=>this.minIntegerBulletText+e)).join(this.splitToken),this.splitToken):new Set}get lastDisplayBulletText(){if("integer"===this.bulletTextType)return null!=this.maxIntegerBulletText?Math.min(this.maxIntegerBulletText,this.minIntegerBulletText+this.maxDisplayBulletsCount-1):this.minIntegerBulletText+this.maxDisplayBulletsCount-1;if(this.bulletTextsSet.size>0){const t=Array.from(this.bulletTextsSet);return t.length>=this.maxDisplayBulletsCount?t[this.maxDisplayBulletsCount-1]:t[t.length-1]}return null}get isSingleSelectionMode(){return 1===this.maxSelectedCount}getBulletToRender(){const t=Array.from(this.bulletTextsSet);let e=t,n=!1;return"text"===this.bulletTextType?t.length>this.maxDisplayBulletsCount?(n=!0,e=t.slice(0,this.maxDisplayBulletsCount-1)):e=t:(n=null!=this.maxIntegerBulletText&&this.maxIntegerBulletText>Number(this.lastDisplayBulletText),e=t),{bulletsToRender:e,showInputButton:n}}renderBulletGroup(){let t=[];if("bet"===this.type){const e=null!==this.maxSelectedCount&&this.selectedSet.size>=this.maxSelectedCount,{bulletsToRender:n,showInputButton:r}=this.getBulletToRender();if(n.forEach(((n,r)=>{let i="toggle";this.disabledSet.has(String(n))?i="disabled":this.selectedSet.has(String(n))||!e||this.isSingleSelectionMode||(i="disabled"),t.push({value:this.selectedSet.has(String(n))?1:0,text:String(n),idx:r,type:i})})),r){let n="input";e&&!this.isSingleSelectionMode&&(n="disabled");const r="text"===this.bulletTextType?"...":`${this.lastDisplayBulletText}+`,i="text"===this.bulletTextType?-1:Number(this.lastDisplayBulletText)+1;"integer"===this.bulletTextType&&t.length>=this.maxDisplayBulletsCount&&t.pop(),t.push({value:0,text:r,idx:i,type:n})}}else if(["choice","preview"].includes(this.type)){const{bulletsToRender:e}=this.getBulletToRender();e.forEach(((e,n)=>{let r="toggle";this.disabledSet.has(String(e))?r="disabled":"preview"===this.type?r="readonly":this.selectedSet.has(String(e))&&(r="delete"),t.push({value:this.selectedSet.has(String(e))?1:0,text:e,idx:n,type:r})}))}return e("div",{class:"lottery-selection-group__item--right"},t.map((t=>e("lottery-selection",{clientStyling:this.clientStyling,clientStylingUrl:this.clientStylingUrl,mbSource:this.mbSource,text:t.text,idx:t.idx,value:t.value,type:t.type,hasBorder:this.hasBorder,hasBackground:this.hasBackground}))))}handleCloseAddMoreDialog(){this.dialogConfig=Object.assign(Object.assign({},this.dialogConfig),{visible:!1}),this.inputInfo={value:"",errorMessage:"",valid:!0}}handleInputChange(t){const e=t.target.value;this.inputInfo=Object.assign(Object.assign({},this.inputInfo),{value:e}),this.inputInfo=function({value:t,selectedSet:e,maxValue:n,minValue:r,language:i,type:o="integer"}){const a=t.trim();if("integer"===o){if(!/^-?\d+$/.test(a))return{valid:!1,errorMessage:Lt("enterValidNumber",i),value:t};const o=Number(a);if(isNaN(o))return{valid:!1,errorMessage:Lt("enterValidNumber",i),value:t};if(void 0!==r&&o<r||void 0!==n&&o>n)return{valid:!1,errorMessage:Lt("enterNumberBetween",i,{min:r,max:n}),value:t};const s=String(o);if(e.has(s))return{valid:!1,errorMessage:Lt("numberAlreadySelected",i),value:t}}else if(e.has(a))return{valid:!1,errorMessage:Lt("numberAlreadySelected",i),value:t};return{valid:!0,errorMessage:"",value:t}}({value:e,selectedSet:this.selectedSet,maxValue:this.maxIntegerBulletText,minValue:"integer"===this.bulletTextType?Number(this.lastDisplayBulletText)+1:void 0,language:this.language,type:this.bulletTextType})}handleFillInAddMore(){if(this.inputInfo.valid){const{value:t}=this.inputInfo;let e,n=t;n="integer"===this.bulletTextType?String(Number(t)):t.trim(),e=this.isSingleSelectionMode?n:Bt(n,Array.from(this.selectedSet)).join(this.splitToken),this.bulletGroupUpdateSelectedBulletTexts.emit({newSelectedBulletTexts:e,selectionGroupId:this.selectionGroupId}),this.handleCloseAddMoreDialog()}}render(){return e("div",{key:"39225bad75cf435b166269367df570732eff7ef4",class:"lottery-selection-group",ref:t=>this.stylingContainer=t},e("div",{key:"2bb2bc539c9fc05aeece7145b13f722756bc054e",class:"lottery-selection-group__item"},this.selectionGroupLabel&&e("div",{key:"dc15197dca90375bd4eb50e87d96402d1ef694d2",class:"lottery-selection-group__item--left"},this.selectionGroupLabel),this.renderBulletGroup()),e("lottery-tipping-dialog",{key:"9526dbb5d1656d6724e6566465febde778437c64",visible:this.dialogConfig.visible,width:this.dialogConfig.width,onCancel:this.dialogConfig.onCancel},e("div",{key:"ecf5800430e92be4a2af279f1d8c5075d5965b7e",class:"addSelectionDialog"},e("div",{key:"3e8a2f445679ef5fe2ada60d4a6832f472f27dfa",class:"addSelectionDialog-title"},this.dialogTitle||("text"===this.bulletTextType?Lt("enterValue",this.language):Lt("enterScoreUpTo",this.language,{maxScore:this.maxIntegerBulletText}))),e("input",{key:"46462ee8f27410639d45970a76fc3d90a03f3a10",type:"text",class:{"dialog-input":!0,invalid:!this.inputInfo.valid},value:this.inputInfo.value,onInput:this.handleInputChange.bind(this),placeholder:this.dialogInputPlaceholder}),e("div",{key:"2e66988e4186f8f4f773ed548fc76e53085be946",class:"error-message"},this.inputInfo.errorMessage)),e("div",{key:"81dc64f0b7cba422a54af8ecff4734aa19832583",slot:"footer",class:"addSelectionDialog-footer"},e("lottery-button",{key:"3027240894aef525dc9fc50db79597cf29f9cb99",onClick:this.dialogConfig.onCancel,text:Lt("cancel",this.language),variant:"outline"}),e("lottery-button",{key:"ab8c6deed9ab4a7d79d71ed6fe8122b23af5741b",onClick:this.dialogConfig.onConfirm,text:Lt("confirm",this.language),variant:"primary",disabled:!this.inputInfo.valid||!this.inputInfo.value}))))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};jt.style=":host {\n width: 100%;\n}\n\n.lottery-selection-group {\n container-type: inline-size;\n padding: var(--lottery-selection-group-padding, 0);\n background: var(--lottery-selection-group-background, transparent);\n border: var(--lottery-selection-group-border, none);\n border-radius: var(--lottery-selection-group-border-radius, 0);\n}\n.lottery-selection-group__item {\n display: flex;\n flex-direction: var(--lottery-selection-group-flex-direction, row);\n align-items: var(--lottery-selection-group-item-align, center);\n justify-content: var(--lottery-selection-group-item-justify, flex-start);\n gap: var(--lottery-selection-group-item-gap, 16px);\n width: 100%;\n}\n.lottery-selection-group__item--left {\n width: var(--lottery-selection-group-label-width, 130px);\n min-width: var(--lottery-selection-group-label-min-width, auto);\n max-width: var(--lottery-selection-group-label-max-width, none);\n color: var(--lottery-selection-group-label-color, var(--emw--color-typography, #000));\n font-size: var(--lottery-selection-group-label-font-size, 1em);\n font-weight: var(--lottery-selection-group-label-font-weight, bold);\n text-align: var(--lottery-selection-group-label-align, left);\n white-space: var(--lottery-selection-group-label-white-space, normal);\n}\n.lottery-selection-group__item--right {\n flex: 1;\n display: flex;\n flex-wrap: var(--lottery-selection-group-bullets-wrap, wrap); /* Allow items to wrap */\n gap: var(--lottery-selection-group-bullets-gap, 8px); /* Gap between bullets */\n align-items: var(--lottery-selection-group-bullets-align, center);\n justify-content: var(--lottery-selection-group-bullets-justify, flex-start); /* Align bullets to start */\n}\n@container (max-width: 320px) {\n .lottery-selection-group__item--left {\n width: 100px;\n max-width: 100px;\n }\n}\n\n.dialog-input {\n width: 100%;\n padding: var(--lottery-selection-group-input-padding, 8px);\n border: var(--lottery-selection-group-input-border-width, 1px) var(--lottery-selection-group-input-border-style, solid) var(--lottery-selection-group-input-border-color, var(--emw--color-gray-100, #e6e6e6));\n border-radius: var(--lottery-selection-group-input-radius, 4px);\n background-color: var(--lottery-selection-group-input-bg, #fff);\n color: var(--lottery-selection-group-input-color, #000);\n box-sizing: border-box;\n margin-top: var(--lottery-selection-group-input-margin-top, 10px);\n font-size: var(--lottery-selection-group-input-font-size, 1em);\n}\n.dialog-input::placeholder {\n color: var(--lottery-selection-group-input-placeholder-color, #999);\n}\n\n.dialog-input.invalid,\n.dialog-input.invalid:focus {\n border-color: var(--emw--color-error, #ff3d00);\n outline-color: var(--emw--color-error, #ff3d00);\n}\n\n.error-message {\n color: var(--lottery-selection-group-error-color, var(--emw--color-error, #ff3d00));\n font-size: var(--lottery-selection-group-error-font-size, 12px);\n font-weight: var(--lottery-selection-group-error-font-weight, normal);\n margin-top: 4px;\n}\n\n.addSelectionDialog-title {\n color: var(--lottery-selection-group-dialog-title-color, var(--emw--color-typography, #000));\n font-size: var(--lottery-selection-group-dialog-title-font-size, 1.2em);\n font-weight: var(--lottery-selection-group-dialog-title-font-weight, bold);\n margin-bottom: var(--lottery-selection-group-dialog-title-margin-bottom, 0);\n}\n.addSelectionDialog-footer {\n display: flex;\n justify-content: var(--lottery-selection-group-dialog-footer-justify, flex-end);\n gap: var(--lottery-selection-group-dialog-footer-gap, 18px);\n margin-top: var(--lottery-selection-group-dialog-footer-margin-top, 0);\n}";const Ot=["ro","en","fr","ar","hr"],Pt={en:{homeTeam:"Home team:",awayTeam:"Away team:",loading:"Loading...",error:"Error!",noData:"No data available.",lineInfo:"Line {currentPage} of {totalPages}",clearAll:"Clear All"},ro:{homeTeam:"Echipa gazdă:",awayTeam:"Echipa oaspete:",selectionCleared:"Selecția dvs. a fost ștearsă.",selectionOnLineCleared:"Selecția dvs. de pe această linie va fi ștearsă.",loading:"Se încarcă...',n error: 'Eroare!",noData:"Nu sunt date disponibile.",lineInfo:"Linia {currentPage} din {totalPages}",clearAll:"Șterge tot",cancel:"Anulează",confirm:"Confirmă"},fr:{homeTeam:"Équipe à domicile:",awayTeam:"Équipe à l'extérieur:",selectionCleared:"Votre sélection a été effacée.",selectionOnLineCleared:"Votre sélection sur cette ligne sera effacée.",loading:"Chargement...',n error: 'Erreur!",noData:"Aucune donnée disponible.",lineInfo:"Ligne {currentPage} sur {totalPages}",clearAll:"Tout effacer",cancel:"Annuler",confirm:"Confirmer"},ar:{homeTeam:"الفريق المضيف:",awayTeam:"الفريق الضيف:",selectionCleared:"تم مسح اختيارك.",selectionOnLineCleared:"سيتم مسح اختيارك في هذا السطر.",loading:"جار التحميل...',n error: 'خطأ!",noData:"لا توجد بيانات متاحة.",lineInfo:"السطر {currentPage} من {totalPages}",clearAll:"مسح الكل",cancel:"إلغاء",confirm:"تأكيد"},hr:{homeTeam:"Domaći tim:",awayTeam:"Gostujući tim:",selectionCleared:"Vaš odabir je obrisan.",selectionOnLineCleared:"Vaš odabir na ovoj liniji bit će obrisan.",loading:"Učitavanje...',n error: 'Greška!",noData:"Nema dostupnih podataka.",lineInfo:"Linija {currentPage} od {totalPages}",clearAll:"Očisti sve",cancel:"Odustani",confirm:"Potvrdi"}},At=(t,e,n)=>{const r=e;let i=Pt[void 0!==r&&Ot.includes(r)?r:"en"][t];return n&&Object.keys(n).forEach((t=>{i=i.replace(`{${t}}`,n[t])})),i},Ht=async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])Pt[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e},Et=({columns:t,dataSource:n,hideHead:r=!1,grid:i=!0,bordered:o=!0})=>e("table",{class:{bordered:o,grid:i,"my-table-component":!0}},!r&&e("thead",null,e("tr",null,t.map((t=>{var n;return e("th",{key:t.value,style:{width:t.width+"%",textAlign:t.align}},"string"==typeof t.title?t.title:null===(n=t.title)||void 0===n?void 0:n.call(t))})))),e("tbody",null,n.map(((n,r)=>e("tr",{key:r},t.map((t=>e("td",{key:t.value,style:{width:t.width+"%",textAlign:t.align},class:{"no-wrap":t.nowrap}},t.render?t.render(n,n[t.value],r):n[t.value])))))))),Gt=class{constructor(n){t(this,n),this.selectionChangeHandler=r(this,"lotteryTippingBetSelectionChange",7),this.clearAll=r(this,"lotteryTippingBetClearAll",7),this.addLine=r(this,"lotteryTippingBetAddLine",7),this.removeLine=r(this,"lotteryTippingBetRemoveLine",7),this.pageChange=r(this,"lotteryTippingBetPageChange",7),this.columns=[{title:"",value:"index",width:3},{title:"",value:"eventName",width:65,render:(t,e)=>this.renderEventName(t,e)},{title:"",value:"startTime",width:22,align:"right",nowrap:!0,render:(t,e)=>(({date:t,type:e="date",format:n})=>{try{const r=m(t);if(isNaN(r.getTime()))throw new Error(`Invalid date: ${t}`);if(n)return nt(r,n);let i="dd/MM/yyyy";return"time"===e?i="dd/MM/yyyy HH:mm:ss":"week"===e&&(i="ccc dd/MM/yyyy HH:mm:ss"),nt(r,i)}catch(t){return console.error("Error formatting date:",t.message),""}})({date:e,format:"ccc HH:mm"})},{title:()=>e("lottery-selection-group",{language:this.language,"translation-url":this.translationUrl,"client-styling":this.clientStyling,clientStylingUrl:this.clientStylingUrl,type:"preview",splitToken:this.bulletTextsSplitToken,"bullet-texts":this.bulletNames,bulletTextType:"text",hasBackground:!1,hasBorder:!1}),value:"results",width:10,render:(t,n,r)=>e("lottery-selection-group",{language:this.language,"translation-url":this.translationUrl,"client-styling":this.clientStyling,clientStylingUrl:this.clientStylingUrl,"mb-source":this.mbSource,selectionGroupId:`${this.currentPage-1}${this.bulletTextsSplitToken}${r}`,type:this.readPretty?"preview":"bet","selected-bullet-texts":this.selectedBulletTexts(r),"disabled-bullet-texts":this.getBulletDisabledOptions(r),"max-selected-count":"single"===this.mode?1:this.bulletTexts.split(this.bulletTextsSplitToken).length,"bullet-texts":this.bulletTexts,splitToken:this.bulletTextsSplitToken,bulletTextType:"text"})}],this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.language="en",this.totalPages=1,this.minTotalPages=1,this.maxTotalPages=3,this.bulletTexts="1,X,2",this.bulletNames="Home,Draw,Away",this.bulletTextsSplitToken=",",this.showClearButton=!0,this.addImage=_t(vt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.deleteImage=_t(ft,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.infoImage=_t(gt,{extraSVGAttrs:{width:"16px",height:"16px",fill:"currentColor"}}),this.leftImage=_t(pt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.rightImage=_t(wt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.mode="multi",this.readPretty=!1,this.ticketDataSourceStr="[]",this.bulletSelectionsLineGroupStr="[]",this.currentPage=1,this.bulletSelectionsLineGroup=[],this.ticketDataSource=[],this.betIsLoading=!1,this.betHasErrors=!1}renderEventName(t,n){const[r,i]=n.split(" vs ");return e("div",{class:"flex gap-1 eventNameContainer__item"},e("span",{class:"eventNameContainer__item--title"},n),e("app-tooltip",null,e("span",{slot:"trigger",class:"icon info-icon",innerHTML:this.infoImage,style:{width:"18px"}}),e("div",{slot:"content"},e("div",{class:"match-info"},e("div",{class:"match-info-item"},e("div",{class:"match-info-item-label"},At("homeTeam",this.language)),e("div",{class:"match-info-item-value"},r)),e("div",{class:"match-info-item"},e("div",{class:"match-info-item-label"},At("awayTeam",this.language)),e("div",{class:"match-info-item-value"},i))))))}selectedBulletTexts(t){var e,n,r;return(null===(r=null===(n=null===(e=this.bulletSelectionsLineGroup)||void 0===e?void 0:e[this.currentPage-1])||void 0===n?void 0:n[t])||void 0===r?void 0:r.join(this.bulletTextsSplitToken))||""}getBulletDisabledOptions(t){const{outcomes:e}=this.ticketDataSource[t],n=e.map((t=>t.betOn));return this.bulletTexts.split(this.bulletTextsSplitToken).filter((t=>!n.includes(t))).join(this.bulletTextsSplitToken)}handleNewTranslations(){Ht(this.translationUrl)}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}parseTicketDataSource(t){try{this.ticketDataSource=JSON.parse(t||"[]")}catch(t){console.error("Failed to parse ticketDataSourceStr:",t)}}parseBulletSelectionsLineGroup(t){try{this.bulletSelectionsLineGroup=JSON.parse(t||"[]")}catch(t){console.error("Failed to parse bulletSelectionsLineGroupStr:",t)}}connectedCallback(){this.boundMessageHandler=this.messageHandler.bind(this),window.addEventListener("message",this.boundMessageHandler)}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe(),this.boundMessageHandler&&window.removeEventListener("message",this.boundMessageHandler)}messageHandler(){}componentWillLoad(){Ht(this.translationUrl),this.parseTicketDataSource(this.ticketDataSourceStr),this.parseBulletSelectionsLineGroup(this.bulletSelectionsLineGroupStr)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}handleClearAll(){this.clearAll.emit()}bulletGroupUpdateSelectionHandler(t){t.stopPropagation();const{newSelectedBulletTexts:e,selectionGroupId:n}=t.detail;if(!n)return void console.error("Miss selectionGroupId");const r=n.split(this.bulletTextsSplitToken);if(2!==r.length)return void console.error("Invalid selectionGroupId format:",n);const[i,o]=r;this.selectionChangeHandler.emit({newSelections:e.split(this.bulletTextsSplitToken),matchId:o,boardId:i})}prevPage(){this.swapCard("prev",(()=>{this.pageChange.emit({newPage:this.currentPage-1})}))}nextPage(){this.swapCard("next",(()=>{this.pageChange.emit({newPage:this.currentPage+1})}))}handleAddLine(){this.swapCard("add",(()=>{this.addLine.emit()}))}handleRemoveLine(){this.removeLine.emit({boardId:this.currentPage-1,close:t=>{t&&this.swapCard("remove",t)}})}swapCard(t,e){const n=this.mainContainer;if(!n)return;if(Array.from(n.classList).some((t=>t.startsWith("card-out-")||t.startsWith("card-in-"))))return;const{out:r,in:i}={next:{out:"card-out-left",in:"card-in-left"},prev:{out:"card-out-right",in:"card-in-right"},remove:{out:"card-out-down",in:"card-in-right"},add:{out:"card-out-left",in:"card-in-up"}}[t];n.classList.add(r),n.addEventListener("animationend",(()=>{n.classList.remove(r),e();const t=this.mainContainer;t&&(t.classList.add(i),t.addEventListener("animationend",(()=>t.classList.remove(i)),{once:!0}))}),{once:!0})}renderLoading(){return e("div",{class:"loading-wrap"},e("section",{class:"dots-container"},e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"})))}renderErrorContent(){return e("p",null,At("error",this.language))}renderEmptyContent(){return e("div",{class:"LotteryTippingTicketBet__empty"},e("p",null,At("noData",this.language)))}renderPageFooter(){return this.totalPages<=1?null:e("div",null,e("div",{class:"border-line"}),e("div",{class:"LotteryTippingTicketBet__footer"},e("div",{class:"my-pagination flex justify-between"},e("span",null,At("lineInfo",this.language,{currentPage:this.currentPage,totalPages:this.totalPages})),e("div",{class:"flex gap-1"},e("button",{type:"button",class:"btn "+(1===this.currentPage?"disabled":""),onClick:()=>this.prevPage(),disabled:1===this.currentPage},e("span",{class:"icon",innerHTML:this.leftImage})),e("button",{type:"button",class:"btn "+(this.currentPage===this.totalPages?"disabled":""),onClick:()=>this.nextPage(),disabled:this.currentPage===this.totalPages},e("span",{class:"icon",innerHTML:this.rightImage}))))))}renderReadPrettyContent(){var t;return e("div",{class:"LotteryTippingTicketBet__main",ref:t=>this.mainContainer=t},e("div",{class:"table-scroll-wrapper"},e(Et,{columns:this.columns,dataSource:(null===(t=this.ticketDataSource)||void 0===t?void 0:t.map(((t,e)=>Object.assign(Object.assign({},t),{index:e+1}))))||[],hideHead:!1,grid:!1,bordered:!1})),this.renderPageFooter())}renderDefaultContent(){var t;const n=this.totalPages<this.maxTotalPages&&this.currentPage===this.totalPages,r=this.totalPages>this.minTotalPages;return e("div",null,e("div",{class:"LotteryTippingTicketBet__tableToolbar flex justify-end gap-1"},this.showClearButton&&e("lottery-button",{class:{"LotteryTippingTicketBet__tableToolbar--item":!0,"mr-0":!(n||r)},text:At("clearAll",this.language),onClick:()=>this.handleClearAll(),variant:"text",clientStyling:this.clientStyling||""})),e("div",{class:"flex align-center LotteryTippingTicketBet__main",ref:t=>this.mainContainer=t},e("div",{class:"table-scroll-wrapper"},e(Et,{columns:this.columns,dataSource:(null===(t=this.ticketDataSource)||void 0===t?void 0:t.map(((t,e)=>Object.assign(Object.assign({},t),{index:e+1}))))||[],hideHead:!1,grid:!1,bordered:!1})),(n||r)&&e("div",{class:"LotteryTippingTicketBet__lineOperatorGroup"},n&&e("button",{type:"button",class:{"LotteryTippingTicketBet__lineOperatorGroup--item":!0},onClick:()=>this.handleAddLine()},e("span",{class:"icon",innerHTML:this.addImage})),r&&e("button",{type:"button",class:{"LotteryTippingTicketBet__lineOperatorGroup--item":!0},onClick:()=>this.handleRemoveLine()},e("span",{class:"icon",innerHTML:this.deleteImage})))),this.renderPageFooter())}render(){let t;return t=this.betIsLoading?this.renderLoading():this.betHasErrors?this.renderErrorContent():0===this.ticketDataSource.length?this.renderEmptyContent():this.readPretty?this.renderReadPrettyContent():this.renderDefaultContent(),e("div",{key:"425f7f3d185616af3189857a9159868e3c57f100",ref:t=>this.stylingContainer=t,class:"LotteryTippingTicketBet__container"},t)}static get watchers(){return{translationUrl:["handleNewTranslations"],clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],ticketDataSourceStr:["parseTicketDataSource"],bulletSelectionsLineGroupStr:["parseBulletSelectionsLineGroup"]}}};Gt.style=":host {\n --lottery-button-border-radius: 16px;\n}\n\n.LotteryTippingTicketBet__container {\n display: block; /* Or inline-block, depending on desired layout flow */\n font-size: 14px;\n padding: 12px;\n border: 1px solid var(--emw--color-gray-100, #e6e6e6);\n border-radius: var(--emw--button-border-radius, 4px);\n line-height: 1.5715;\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n overflow: hidden;\n min-width: 300px;\n container-type: inline-size;\n}\n@container (max-width: 375px) {\n .LotteryTippingTicketBet__container {\n font-size: 12px;\n }\n}\n\n.table-wrapper {\n overflow-x: auto; /* Handle horizontal scroll if content overflows */\n}\n\n.LotteryTippingTicketBet__main {\n overflow: hidden;\n}\n\n.table-scroll-wrapper {\n overflow-x: auto;\n flex-grow: 1;\n min-width: 0;\n}\n\n.my-table-component {\n width: 100%;\n border-collapse: collapse; /* Important for borders */\n text-align: left;\n border-radius: 0.1rem; /* Ant Design like subtle rounding */\n border-spacing: 0;\n}\n\n/* Header */\n.my-table-component th {\n background: var(--emw--color-background-secondary, #f5f5f5);\n color: var(--emw--color-typography, #000);\n font-weight: 500;\n padding: 0.4rem 0.5rem;\n transition: background 0.3s ease;\n}\n@container (max-width: 400px) {\n .my-table-component th {\n padding: 0.3rem 0.3rem;\n }\n}\n\n/* Cells */\n.my-table-component td {\n padding: 0.4rem 0.5rem;\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n transition: background 0.3s;\n}\n@container (max-width: 400px) {\n .my-table-component td {\n padding: 0.3rem 0.3rem;\n }\n}\n\n.my-table-component th:nth-child(1),\n.my-table-component td:nth-child(1) {\n /* index */\n min-width: 10px;\n}\n.my-table-component th:nth-child(3),\n.my-table-component td:nth-child(3) {\n /* startTime */\n min-width: 60px;\n}\n.my-table-component th:nth-child(4),\n.my-table-component td:nth-child(4) {\n /* results */\n min-width: 120px;\n}\n\n.my-table-component.bordered th,\n.my-table-component.bordered td {\n border-bottom: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n/* Bordered style */\n.my-table-component.grid th,\n.my-table-component.grid td {\n border: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n.my-table-component.grid th {\n border-bottom-width: 1px; /* Ensure bottom border is consistent */\n}\n\n.my-table-component.grid {\n border: 1px solid var(--emw--color-gray-100, #e6e6e6); /* Outer border */\n border-right-width: 0;\n border-bottom-width: 0;\n}\n\n.my-table-component.grid th:last-child,\n.my-table-component.grid td:last-child {\n border-right: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n.my-table-component.grid tr:last-child td {\n border-bottom: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n/* Striped style */\n.my-table-component.striped tbody tr:nth-child(even) td {\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n/* Hover (optional, but nice) */\n.my-table-component tbody tr:hover td {\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n.flex {\n display: flex;\n}\n\n.justify-end {\n justify-content: flex-end;\n}\n\n.gap-1 {\n gap: 4px;\n}\n\n.justify-between {\n justify-content: space-between;\n}\n\n.align-center {\n align-items: center;\n}\n\n.gap-1 {\n gap: 0.5rem;\n}\n\n.btn {\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n font-size: 14px;\n transition: all 0.2s ease;\n}\n.btn:hover {\n cursor: pointer;\n}\n\n.btn:hover {\n background-color: var(--emw--color-gray-100, #e6e6e6);\n}\n\n.btn.disabled {\n opacity: 0.5;\n pointer-events: none;\n}\n.btn.disabled:hover {\n cursor: not-allowed !important;\n}\n\n.LotteryTippingTicketBet__tableToolbar {\n width: 100%;\n margin-bottom: 1rem;\n}\n\n.LotteryTippingTicketBet__tableToolbar--item {\n margin-right: 2rem;\n}\n.LotteryTippingTicketBet__tableToolbar--item.mr-0 {\n margin-right: 0rem !important;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup {\n flex-basis: 2rem;\n display: flex;\n flex-direction: column;\n gap: 1rem;\n border-radius: 8px;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 2rem;\n height: 2rem;\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n color: var(--emw--color-typography, #000);\n border-radius: 8px;\n border: none;\n transition: all 0.2s ease-in-out;\n cursor: pointer;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item:hover {\n transform: scale(1.1);\n box-shadow: 0 6px 14px var(--emw-calender-curday-box-shadow, rgba(0, 0, 0, 0.09));\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item .icon {\n width: 20px;\n height: 20px;\n transition: filter 0.2s ease-in-out;\n filter: grayscale(0.3);\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item:hover .icon {\n filter: grayscale(0);\n transform: rotate(3deg);\n}\n\ndiv.border-line {\n margin-top: 1rem;\n height: 1px;\n width: 100%;\n box-sizing: border-box;\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n transition: all 0.3s ease;\n}\n\n.LotteryTippingTicketBet__footer {\n padding: 0.5rem;\n}\n\n.my-pagination {\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 1rem;\n font-size: 0.8rem;\n color: var(--emw--color-typography-secondary, #333);\n}\n\n.my-pagination span {\n font-weight: 500;\n user-select: none;\n}\n\n.my-pagination .btn {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 2rem;\n height: 2rem;\n border-radius: 50%;\n border: none;\n transition: all 0.3s ease;\n cursor: pointer;\n opacity: 0.9;\n color: var(--emw--color-typography, #000);\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n.my-pagination .btn .icon {\n width: 20px;\n height: 20px;\n transition: transform 0.2s ease;\n}\n\n.my-pagination .btn:hover {\n transform: scale(1.1);\n box-shadow: 0 6px 14px var(--emw-calender-curday-box-shadow, rgba(0, 0, 0, 0.09));\n}\n\n.my-pagination .btn.disabled {\n background-color: var(--emw--color-background-tertiary, #ccc);\n cursor: not-allowed;\n opacity: 0.5;\n transform: scale(1);\n}\n\n.match-info-item {\n display: flex;\n}\n\n.match-info-item-label {\n margin-right: 6px;\n}\n\n.info-icon:hover {\n cursor: pointer;\n}\n\n.LotteryTippingTicketBet__empty p {\n text-align: center;\n}\n\n.no-wrap {\n white-space: nowrap;\n overflow: hidden;\n}\n\n.eventNameContainer__item--title {\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n max-width: 300px;\n}\n@container (max-width: 600px) {\n .eventNameContainer__item--title {\n max-width: 180px;\n }\n}\n@container (max-width: 500px) {\n .eventNameContainer__item--title {\n max-width: 150px;\n }\n}\n@container (max-width: 400px) {\n .eventNameContainer__item--title {\n max-width: 100px;\n }\n}\n@container (max-width: 330px) {\n .eventNameContainer__item--title {\n max-width: 70px;\n }\n}\n\n.LotteryTippingTicketBet__main {\n perspective: 800px;\n will-change: transform, opacity;\n}\n\n@container (max-width: 520px) {\n .LotteryTippingTicketBet__main {\n flex-wrap: wrap;\n justify-content: center;\n }\n .LotteryTippingTicketBet__tableToolbar--item {\n margin-right: 0 !important;\n }\n}\n/* Fade-In Keyframes */\n@keyframes fadeInLeft {\n from {\n opacity: 0;\n transform: translateX(100%);\n }\n to {\n opacity: 1;\n transform: translateX(0);\n }\n}\n/* Fade-Out Keyframes */\n@keyframes fadeOut {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n}\n@keyframes fadeInRight {\n from {\n opacity: 0;\n transform: translateX(-100%);\n }\n to {\n opacity: 1;\n transform: translateX(0);\n }\n}\n@keyframes fadeInUp {\n from {\n opacity: 0;\n transform: translateY(100%);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n}\n@-webkit-keyframes slide-left {\n 0% {\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n 100% {\n -webkit-transform: translateX(-100px);\n transform: translateX(-100px);\n }\n}\n@keyframes slide-left {\n 0% {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n }\n 100% {\n -webkit-transform: translateX(0px);\n transform: translateX(0px);\n }\n}\n@-webkit-keyframes slide-right {\n 0% {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n }\n 100% {\n -webkit-transform: translateX(0px);\n transform: translateX(0px);\n }\n}\n@keyframes slide-right {\n 0% {\n -webkit-transform: translateX(-100px);\n transform: translateX(-100px);\n }\n 100% {\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n}\n@-webkit-keyframes slide-top {\n 0% {\n -webkit-transform: translateY(-100px);\n transform: translateY(-100px);\n }\n 100% {\n -webkit-transform: translateY(0px);\n transform: translateY(0px);\n }\n}\n@keyframes slide-top {\n 0% {\n -webkit-transform: translateY(-100px);\n transform: translateY(-100px);\n }\n 100% {\n -webkit-transform: translateY(0px);\n transform: translateY(0px);\n }\n}\n/* Apply to your card classes */\n.card-in-left {\n -webkit-animation: slide-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-left {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.card-in-right {\n -webkit-animation: slide-right 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-right 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-right {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.card-in-up {\n -webkit-animation: slide-top 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-top 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-down {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.loading-wrap {\n margin: 20px 0;\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 40vh;\n}\n.loading-wrap .dots-container {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n.loading-wrap .dot {\n height: 14px;\n width: 14px;\n margin-right: 14px;\n border-radius: 14px;\n background-color: var(--emw--color-gray-300, #333);\n animation: pulse 1.5s infinite ease-in-out;\n}\n.loading-wrap .dot:last-child {\n margin-right: 0;\n}\n.loading-wrap .dot:nth-child(1) {\n animation-delay: -0.3s;\n}\n.loading-wrap .dot:nth-child(2) {\n animation-delay: -0.1s;\n}\n.loading-wrap .dot:nth-child(3) {\n animation-delay: 0.1s;\n}\n@keyframes pulse {\n 0% {\n transform: scale(0.8);\n background-color: var(--emw--color-gray-300, #333);\n }\n 50% {\n transform: scale(1.2);\n background-color: var(--emw--color-gray-100, #e6e6e6);\n }\n 100% {\n transform: scale(0.8);\n background-color: var(--emw--color-gray-150, #6f6f6f);\n }\n}\n\n.lottery-selection-group-table-header .lottery-selection__button {\n border: none;\n background: none;\n}";const Nt=["ro","en","fr","ar","hr"],Ut={en:{cancel:"Cancel",confirm:"Confirm"},ro:{cancel:"Anulează",confirm:"Confirmă"},fr:{cancel:"Annuler",confirm:"Confirmer"},ar:{cancel:"إلغاء",confirm:"تأكيد"},hr:{cancel:"Odustani",confirm:"Potvrdi"}},$t=(t,e)=>{const n=e;return Ut[void 0!==n&&Nt.includes(n)?n:"en"][t]},It=class{constructor(e){t(this,e),this.open=r(this,"open",7),this.close=r(this,"close",7),this.confirm=r(this,"confirm",7),this.cancel=r(this,"cancel",7),this.wasVisible=!1,this.mbSource=void 0,this.clientStyling="",this.clientStylingUrl="",this.visible=void 0,this.dialogTitle="",this.width="520px",this.closable=!0,this.mask=!0,this.maskClosable=!0,this.animationDuration=300,this.fullscreen=!1,this.showFooter=!0,this.showCancelBtn=!0,this.language="en",this.translationUrl=void 0,this.dialogClass=void 0,this.dialogStyle=void 0,this.confirmLoading=!1}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])Ut[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}componentWillUpdate(){this.visible&&!this.wasVisible?this.disableBodyScroll():!this.visible&&this.wasVisible&&this.enableBodyScroll(),this.wasVisible=this.visible}disconnectedCallback(){this.enableBodyScroll(),this.stylingSubscription&&this.stylingSubscription.unsubscribe()}disableBodyScroll(){document.body.style.overflow="hidden"}enableBodyScroll(){document.body.style.overflow=""}handleClose(){this.cancel.emit()}handleMaskClick(){this.maskClosable&&this.cancel.emit()}handleConfirm(){this.confirm.emit()}render(){const t=Object.assign({width:"number"==typeof this.width?`${this.width}px`:this.width,"--duration":`${this.animationDuration}ms`},this.dialogStyle||{}),n=["dialog-wrapper",this.visible?"dialog-wrapper-visible":""],r=["mask",this.visible?"mask-enter":"mask-leave"],i=["dialog",this.visible?"dialog-enter":"dialog-leave",this.fullscreen?"fullscreen":"",this.dialogClass].filter(Boolean).join(" ");return e("div",{key:"05dd671f10bdebda6f138e8f8039f4bc0533fe98",class:n.join(" "),ref:t=>this.stylingContainer=t},e("div",{key:"6e814e02770149de5495617039750461fc0a42d1",class:r.join(" "),onClick:this.handleMaskClick.bind(this)}),e("div",{key:"4cbc5db20317ef1b0808fc4a91a53fa8b86c5f4f",part:"dialog",class:i,style:t,role:"dialog","aria-modal":"true","aria-labelledby":"dialog-title"},(this.dialogTitle||this.closable)&&e("div",{key:"85dc705676a37e6ea2828a7b683fc54b0eb77d17",class:"dialog-header"},e("h2",{key:"85b7472d2b72801dfae19a24fc2018f3c1f1529a",id:"dialog-title",class:"dialog-title"},this.dialogTitle),this.closable&&e("button",{key:"8089aaecfe511558055ee9f64214ff97030eb2a9",class:"close-btn",onClick:this.handleClose.bind(this)},"x")),e("div",{key:"776255540f30d757caa3fcaee747c79ac638ae76",class:"dialog-content",style:{maxHeight:"calc(100vh - 62px)",overflowY:"auto"}},e("slot",{key:"5ef964615b6ab70a9e561f8efac8fe952fe47b4e"})),this.showFooter&&e("div",{key:"8927a0991d916caf7852d58db996b9818687da30",class:"dialog-footer"},e("slot",{key:"84de0306994ec62220ae30fa2881dadbae5544ea",name:"footer"},this.showCancelBtn&&e("button",{key:"ee87b8c3918c1f4d007923a2498142b3af2740a0",class:"cancel-btn",onClick:this.handleClose.bind(this)},$t("cancel",this.language)),e("button",{key:"935cff86381b21fff07c2d4156b29779c50e5ce3",class:"confirm-btn",onClick:this.handleConfirm.bind(this),disabled:this.confirmLoading},this.confirmLoading?e("div",{class:"Loading",innerHTML:_t(yt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}})}):$t("confirm",this.language))))))}get el(){return n(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};It.style=".dialog-wrapper{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;visibility:hidden;opacity:1;z-index:199}.dialog-wrapper-visible{visibility:visible}.mask{position:fixed;inset:0;background:var(--emw--color-mask-dialog-background, rgba(0, 0, 0, 0.5));opacity:0;z-index:1000;transition:opacity var(--duration) linear}.mask-enter{opacity:1}.mask-leave{opacity:0}.dialog{position:relative;background:var(--emw--color-background, #fff);border-radius:12px;box-shadow:0 4px 32px var(--emw--button-box-shadow-color-secondary, rgba(0, 0, 0, 0.15));opacity:0;transform:scale(0.9);transition:all var(--duration) linear;width:100%;max-width:100vw;overflow:hidden;z-index:1000}.dialog-enter{opacity:1;transform:scale(1)}.dialog-leave{opacity:0}.dialog.fullscreen{width:100vw !important;height:100vh;overflow:auto;max-height:none;border-radius:0;overflow:hidden}.dialog-header{padding:16px 16px 0 16px;display:flex;justify-content:space-between;align-items:center}.dialog-header .dialog-title{margin:0;font-size:1.25rem;font-weight:500;color:var(--emw--color-typography, #000)}.dialog-header .close-btn{background:transparent;border:none;font-size:1.5rem;width:2rem;height:2rem;color:var(--emw--color-gray-150, #6f6f6f);cursor:pointer;border-radius:4px}.dialog-header .close-btn:hover{background:var(--emw--color-gray-50, #f5f5f5);color:var(--emw--color-gray-300, #333)}.dialog-content{padding:24px;font-size:0.95rem;line-height:1.6;color:var(--emw--color-dialog-typography, #000);flex:1;overflow-y:auto;max-height:calc(100vh - 200px)}.dialog.fullscreen .dialog-content{max-height:none}.dialog-footer{padding:0 16px 16px 16px;display:flex;justify-content:center;gap:12px}.dialog-footer .cancel-btn,.dialog-footer .confirm-btn{padding:10px 24px;min-width:60px;border-radius:6px;font-size:0.9rem;cursor:pointer;transition:all 0.3s linear}.dialog-footer .cancel-btn{border:var(--emw--button-border, 1px solid rgba(221, 221, 221, 0.8666666667));background-color:var(--emw--color-background, #fff);color:var(--emw--color-typography, #000)}.dialog-footer .cancel-btn:hover{background-color:var(--emw--color-background-tertiary, #ccc)}.dialog-footer .confirm-btn{border:none;color:var(--emw--color-typography-normalized, #ffffff);background:var(--emw--color-primary, #009993)}.dialog-footer .confirm-btn:hover{background:var(--emw--color-primary-variant, #004d4a)}@media screen and (max-width: 480px){.dialog.fullscreen .dialog-content{padding:12px}}.Loading{display:flex;align-items:center;justify-content:center;width:100%;height:100%}.Loading svg{animation:spin 1s linear infinite;transform-origin:center}@keyframes spin{100%{transform:rotate(360deg)}}";export{rt as app_tooltip,it as helper_count_down,lt as lottery_banner,ht as lottery_button,mt as lottery_order_summary,Ct as lottery_selection,jt as lottery_selection_group,Gt as lottery_tipping_bet_slip,It as lottery_tipping_dialog}
1
+ import{r as t,h as e,g as n,c as r,a as i}from"./index-c24f96b9.js";import{r as o,t as a,a as s,_ as l,s as c,b as h,c as u,p as m,i as b}from"./lottery-tipping-ticket-buy-d6e60365.js";export{d as lottery_segmented,L as lottery_tipping_ticket_buy}from"./lottery-tipping-ticket-buy-d6e60365.js";var f={};function g(){return f}function p(t){o(1,arguments);var e=a(t),n=e.getUTCDay(),r=(n<1?7:0)+n-1;return e.setUTCDate(e.getUTCDate()-r),e.setUTCHours(0,0,0,0),e}function y(t){o(1,arguments);var e=a(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=p(r),s=new Date(0);s.setUTCFullYear(n,0,4),s.setUTCHours(0,0,0,0);var l=p(s);return e.getTime()>=i.getTime()?n+1:e.getTime()>=l.getTime()?n:n-1}function v(t,e){var n,r,i,l,c,d,h,u;o(1,arguments);var m=g(),b=s(null!==(n=null!==(r=null!==(i=null!==(l=null==e?void 0:e.weekStartsOn)&&void 0!==l?l:null==e||null===(c=e.locale)||void 0===c||null===(d=c.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==i?i:m.weekStartsOn)&&void 0!==r?r:null===(h=m.locale)||void 0===h||null===(u=h.options)||void 0===u?void 0:u.weekStartsOn)&&void 0!==n?n:0);if(!(b>=0&&b<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=a(t),p=f.getUTCDay(),y=(p<b?7:0)+p-b;return f.setUTCDate(f.getUTCDate()-y),f.setUTCHours(0,0,0,0),f}function w(t,e){var n,r,i,l,c,d,h,u;o(1,arguments);var m=a(t),b=m.getUTCFullYear(),f=g(),p=s(null!==(n=null!==(r=null!==(i=null!==(l=null==e?void 0:e.firstWeekContainsDate)&&void 0!==l?l:null==e||null===(c=e.locale)||void 0===c||null===(d=c.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==i?i:f.firstWeekContainsDate)&&void 0!==r?r:null===(h=f.locale)||void 0===h||null===(u=h.options)||void 0===u?void 0:u.firstWeekContainsDate)&&void 0!==n?n:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var y=new Date(0);y.setUTCFullYear(b+1,0,p),y.setUTCHours(0,0,0,0);var w=v(y,e),x=new Date(0);x.setUTCFullYear(b,0,p),x.setUTCHours(0,0,0,0);var k=v(x,e);return m.getTime()>=w.getTime()?b+1:m.getTime()>=k.getTime()?b:b-1}function x(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}const k=function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return x("yy"===e?r%100:r,e.length)},_=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):x(n+1,2)},S=function(t,e){return x(t.getUTCDate(),e.length)},C=function(t,e){return x(t.getUTCHours()%12||12,e.length)},T=function(t,e){return x(t.getUTCHours(),e.length)},M=function(t,e){return x(t.getUTCMinutes(),e.length)},D=function(t,e){return x(t.getUTCSeconds(),e.length)},z=function(t,e){var n=e.length,r=t.getUTCMilliseconds();return x(Math.floor(r*Math.pow(10,n-3)),e.length)};var B={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear();return n.ordinalNumber(r>0?r:1-r,{unit:"year"})}return k(t,e)},Y:function(t,e,n,r){var i=w(t,r),o=i>0?i:1-i;return"YY"===e?x(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):x(o,e.length)},R:function(t,e){return x(y(t),e.length)},u:function(t,e){return x(t.getUTCFullYear(),e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return x(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return x(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return _(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return x(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var i=function(t,e){o(1,arguments);var n=a(t),r=v(n,e).getTime()-function(t,e){var n,r,i,a,l,c,d,h;o(1,arguments);var u=g(),m=s(null!==(n=null!==(r=null!==(i=null!==(a=null==e?void 0:e.firstWeekContainsDate)&&void 0!==a?a:null==e||null===(l=e.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==i?i:u.firstWeekContainsDate)&&void 0!==r?r:null===(d=u.locale)||void 0===d||null===(h=d.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==n?n:1),b=w(t,e),f=new Date(0);return f.setUTCFullYear(b,0,m),f.setUTCHours(0,0,0,0),v(f,e)}(n,e).getTime();return Math.round(r/6048e5)+1}(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):x(i,e.length)},I:function(t,e,n){var r=function(t){o(1,arguments);var e=a(t),n=p(e).getTime()-function(t){o(1,arguments);var e=y(t),n=new Date(0);return n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0),p(n)}(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):x(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):S(t,e)},D:function(t,e,n){var r=function(t){o(1,arguments);var e=a(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime();return Math.floor((n-r)/864e5)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):x(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":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"})}},e:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.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(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"})}},c:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.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(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),i=0===r?7:r;switch(e){case"i":return String(i);case"ii":return x(i,e.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?"noon":0===i?"midnight":i/12>=1?"pm":"am",e){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,i=t.getUTCHours();switch(r=i>=17?"evening":i>=12?"afternoon":i>=4?"morning":"night",e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return C(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):T(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):x(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):M(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):D(t,e)},S:function(t,e){return z(t,e)},X:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();if(0===i)return"Z";switch(e){case"X":return O(i);case"XXXX":case"XX":return P(i);default:return P(i,":")}},x:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return O(i);case"xxxx":case"xx":return P(i);default:return P(i,":")}},O:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+j(i,":");default:return"GMT"+P(i,":")}},z:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+j(i,":");default:return"GMT"+P(i,":")}},t:function(t,e,n,r){return x(Math.floor((r._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,n,r){return x((r._originalDate||t).getTime(),e.length)}};function j(t,e){var n=t>0?"-":"+",r=Math.abs(t),i=Math.floor(r/60),o=r%60;if(0===o)return n+String(i);var a=e||"";return n+String(i)+a+x(o,2)}function O(t,e){return t%60==0?(t>0?"-":"+")+x(Math.abs(t)/60,2):P(t,e)}function P(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t);return r+x(Math.floor(i/60),2)+n+x(i%60,2)}const A=B;var H=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"})}},E=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"})}},G={p:E,P:function(t,e){var n,r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return H(t,e);switch(i){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}}",H(i,e)).replace("{{time}}",E(o,e))}};const N=G;var U=["D","DD"],$=["YY","YYYY"];function I(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 W(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 X,V={date:W({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:W({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:W({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},R={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function q(t){return function(e,n){var r;if("formatting"===(null!=n&&n.context?String(n.context):"standalone")&&t.formattingValues){var i=t.defaultFormattingWidth||t.defaultWidth,o=null!=n&&n.width?String(n.width):i;r=t.formattingValues[o]||t.formattingValues[i]}else{var a=t.defaultWidth,s=null!=n&&n.width?String(n.width):t.defaultWidth;r=t.values[s]||t.values[a]}return r[t.argumentCallback?t.argumentCallback(e):e]}}function F(t){return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.width,i=e.match(r&&t.matchPatterns[r]||t.matchPatterns[t.defaultMatchWidth]);if(!i)return null;var o,a=i[0],s=r&&t.parsePatterns[r]||t.parsePatterns[t.defaultParseWidth],l=Array.isArray(s)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(a))return e}(s):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(a))return e}(s);return o=t.valueCallback?t.valueCallback(l):l,{value:o=n.valueCallback?n.valueCallback(o):o,rest:e.slice(a.length)}}}const Q={code:"en-US",formatDistance:function(t,e,n){var r,i=Y[t];return r="string"==typeof i?i:1===e?i.one:i.other.replace("{{count}}",e.toString()),null!=n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r},formatLong:V,formatRelative:function(t){return R[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:q({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:q({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:q({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:q({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:q({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:(X={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(X.matchPattern);if(!n)return null;var r=n[0],i=t.match(X.parsePattern);if(!i)return null;var o=X.valueCallback?X.valueCallback(i[0]):i[0];return{value:o=e.valueCallback?e.valueCallback(o):o,rest:t.slice(r.length)}}),era:F({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:F({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:F({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:F({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:F({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 J=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,K=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Z=/^'([^]*?)'?$/,tt=/''/g,et=/[a-zA-Z]/;function nt(t,e,n){var r,i,c,d,h,u,m,b,f,p,y,v,w,x,k,_,S,C;o(2,arguments);var T=String(e),M=g(),L=null!==(r=null!==(i=null==n?void 0:n.locale)&&void 0!==i?i:M.locale)&&void 0!==r?r:Q,D=s(null!==(c=null!==(d=null!==(h=null!==(u=null==n?void 0:n.firstWeekContainsDate)&&void 0!==u?u:null==n||null===(m=n.locale)||void 0===m||null===(b=m.options)||void 0===b?void 0:b.firstWeekContainsDate)&&void 0!==h?h:M.firstWeekContainsDate)&&void 0!==d?d:null===(f=M.locale)||void 0===f||null===(p=f.options)||void 0===p?void 0:p.firstWeekContainsDate)&&void 0!==c?c:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var z=s(null!==(y=null!==(v=null!==(w=null!==(x=null==n?void 0:n.weekStartsOn)&&void 0!==x?x:null==n||null===(k=n.locale)||void 0===k||null===(_=k.options)||void 0===_?void 0:_.weekStartsOn)&&void 0!==w?w:M.weekStartsOn)&&void 0!==v?v:null===(S=M.locale)||void 0===S||null===(C=S.options)||void 0===C?void 0:C.weekStartsOn)&&void 0!==y?y:0);if(!(z>=0&&z<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!L.localize)throw new RangeError("locale must contain localize property");if(!L.formatLong)throw new RangeError("locale must contain formatLong property");var B=a(t);if(!function(t){if(o(1,arguments),!function(t){return o(1,arguments),t instanceof Date||"object"===l(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=a(t);return!isNaN(Number(e))}(B))throw new RangeError("Invalid time value");var j=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()}(B),O=function(t,e){return o(2,arguments),function(t,e){o(2,arguments);var n=a(t).getTime(),r=s(e);return new Date(n+r)}(t,-s(e))}(B,j),P={firstWeekContainsDate:D,weekStartsOn:z,locale:L,_originalDate:B};return T.match(K).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,N[e])(t,L.formatLong):t})).join("").match(J).map((function(r){if("''"===r)return"'";var i,o,a=r[0];if("'"===a)return(o=(i=r).match(Z))?o[1].replace(tt,"'"):i;var s=A[a];if(s)return null!=n&&n.useAdditionalWeekYearTokens||-1===$.indexOf(r)||I(r,e,String(t)),null!=n&&n.useAdditionalDayOfYearTokens||!(-1!==U.indexOf(r))||I(r,e,String(t)),s(O,r,L.localize,P);if(a.match(et))throw new RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");return r})).join("")}const rt=class{constructor(e){t(this,e),this.show=()=>this.visible=!0,this.hide=()=>this.visible=!1,this.visible=!1}componentDidLoad(){this.trigger=this.host.querySelector('[slot="trigger"]'),this.trigger&&(this.trigger.addEventListener("mouseenter",this.show),this.trigger.addEventListener("mouseleave",this.hide),this.trigger.addEventListener("focus",this.show),this.trigger.addEventListener("blur",this.hide))}disconnectedCallback(){this.trigger&&(this.trigger.removeEventListener("mouseenter",this.show),this.trigger.removeEventListener("mouseleave",this.hide),this.trigger.removeEventListener("focus",this.show),this.trigger.removeEventListener("blur",this.hide))}render(){return e("div",{key:"e56695ac60fcd7903127179423e9954ef40f05c0",class:"tooltip-wrapper"},e("slot",{key:"4e2472a395ceeb2b911692739d326c031df07e29",name:"trigger"}),e("div",{key:"f77bd72da94eb17d12e42ebb86c395c55801b728",class:{"tooltip-content-wrapper":!0,visible:this.visible}},e("div",{key:"988399e2b42988622d46eaf255f17c6221eb9697",class:"tooltip-content"},e("slot",{key:"05de0572ab1331d965e61947c5c15775e225197a",name:"content"}))))}get host(){return n(this)}};rt.style=":host{display:inline-flex;position:relative}.tooltip-wrapper{position:relative;display:inline-flex}.tooltip-content-wrapper{position:absolute;z-index:10;bottom:125%;left:50%;transform:translateX(-50%);opacity:0;visibility:hidden;transition:opacity 0.2s, visibility 0.2s}.tooltip-content-wrapper.visible{opacity:1;visibility:visible}.tooltip-content{background-color:var(--emw--tooltip-background-color, #000);color:var(--emw--tooltip-text-color, #fff);border-radius:4px;box-shadow:0 2px 8px rgba(0, 0, 0, 0.15);white-space:nowrap;padding:4px}";const it=class{constructor(e){t(this,e),this.countDownChange=r(this,"countDownChange",7),this.countDownFinish=r(this,"countDownFinish",7),this.value=void 0,this.format="HH:mm:ss",this.prefix=void 0,this.suffix=void 0,this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.endTime=void 0,this.timeObj={day:{str:"00",unit:""},hour:{str:"00",unit:""},minute:{str:"00",unit:""},second:{str:"00",unit:""}}}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}handleValueChange(t){this.setEndTime(t),t?this.startCountDown():this.clearCountDown()}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl)),this.setEndTime(this.value),this.value&&this.startCountDown()}setEndTime(t){if("string"==typeof t){const e=m(t).getTime();this.endTime=isNaN(e)?null:e}else this.endTime=t}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe(),this.clearCountDown()}startCountDown(){this.clearCountDown(),this.tick(),this.timer=setInterval((()=>{this.tick()}),1e3)}clearCountDown(){this.timer&&(clearInterval(this.timer),this.timer=null)}tick(){if(!this.endTime)return;let t=this.endTime-Date.now();t<=0&&(t=0,this.clearCountDown(),this.countDownFinish.emit());const e=Math.floor(t/864e5),n=Math.floor(t/36e5%24),r=Math.floor(t/1e3/60%60),i=Math.floor(t/1e3%60),o=t=>t<10?`0${t}`:`${t}`;this.timeObj={day:{str:o(e),unit:"d"},hour:{str:o(n),unit:"h"},minute:{str:o(r),unit:"m"},second:{str:o(i),unit:"s"}};const a=this.getFormatTime();this.countDownChange.emit({leftTime:t,formatTime:a,legalTime:a})}getFormatTime(){return this.format.replace("DD",this.timeObj.day.str).replace("HH",this.timeObj.hour.str).replace("mm",this.timeObj.minute.str).replace("ss",this.timeObj.second.str)}renderItems(){const t=/(DD|HH|mm|ss)|([\s\S]+?)(?=(DD|HH|mm|ss)|$)/g,n=[];let r;for(;null!==(r=t.exec(this.format));)if(r[1]){let t="";switch(r[1]){case"DD":t=this.timeObj.day.str;break;case"HH":t=this.timeObj.hour.str;break;case"mm":t=this.timeObj.minute.str;break;case"ss":t=this.timeObj.second.str}n.push({val:t,unit:""})}else r[2]&&n.length>0&&(n[n.length-1].unit=r[2]);return n.map(((t,n)=>e("div",{key:n+t.unit,class:"helper-count-down-item",part:"item"},e("div",{class:"helper-count-down-item-num"},t.val),e("div",{class:"helper-count-down-item-unit"},t.unit))))}render(){return e("div",{key:"b360412e045020b5ac0263c6ca56458f31eedb2c",class:"helper-count-down-container",ref:t=>this.stylingContainer=t},e("slot",{key:"c72bed87fba869c842407b04e0cbfe038e5b7ea8"}),this.prefix&&e("div",{key:"8d3ba9d60577421f81bae7bc76f52a774b17e1fe",class:"helper-count-down-prefix"},this.prefix),e("div",{key:"187edf3b8eb6de85efe1a748fd8ef47a68e19611",class:"helper-count-down-values",part:"values"},this.renderItems()),this.suffix&&e("div",{key:"3a8e5d9561ecd3f52eff423bd43c8b60a261a17c",class:"helper-count-down-suffix"},this.suffix))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],value:["handleValueChange"]}}};it.style=":host{display:block}.helper-count-down-container{display:flex;align-items:center}.helper-count-down-prefix{margin-right:4px}.helper-count-down-suffix{margin-left:4px}.helper-count-down-values{display:flex;align-items:center}.helper-count-down-item{display:flex;align-items:center;justify-content:center}.helper-count-down-item-num{font-variant-numeric:tabular-nums}";const ot=["ro","en","fr","ar","hr"],at={en:{stop:"Stop",at:"at",turnover:"Turnover: ",startIn:"Sales Start in:"},ro:{stop:"Oprește",at:"la"},fr:{stop:"Arrêtez",at:"à"},ar:{stop:"توقف",at:"في"},hr:{stop:"Stop",at:"u"}},st=(t,e)=>{const n=e;return at[void 0!==n&&ot.includes(n)?n:"en"][t]},lt=class{constructor(e){t(this,e),this.lotteryBannerWagerStarted=r(this,"lotteryBannerWagerStarted",7),this.handleCountdownFinish=()=>{this.isWagerStarted=!0,this.lotteryBannerWagerStarted.emit()},this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.language="en",this.logoUrl=void 0,this.stopTime="",this.startTime="",this.bannerTitle=void 0,this.turnover=void 0,this.layout="logo,title,info",this.isWagerStarted=!1,this.formattedStopTime=void 0}handleClientStylingChange(t,e){t!==e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!==e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!==e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}handleTimeChange(){this.checkWagerStatus()}async componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])at[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl),this.checkWagerStatus()}checkWagerStatus(){this.isWagerStarted=!this.startTime||!b(new Date,m(this.startTime)),this.stopTime&&(this.formattedStopTime=nt(m(this.stopTime),"dd/MM/yyyy HH:mm"))}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}renderElement(t,n=""){const r=i("../static/poolGameLogo.webp");switch(t){case"logo":return e("div",{class:`lottery-banner__logo-wrapper ${n}`},r&&e("img",{alt:"logo",src:r,class:"lottery-banner__logo"}));case"title":return this.bannerTitle&&e("div",{class:`lottery-banner__title ${n}`},this.bannerTitle);case"info":return e("div",{class:`lottery-banner__info ${n}`},this.isWagerStarted?e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},e("span",{class:"lottery-banner__info-item-label__strong"},st("stop",this.language))," ",st("at",this.language)),e("span",{class:"lottery-banner__info-item-value"},this.formattedStopTime)):e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},e("span",{class:"lottery-banner__info-item-label__strong"},st("startIn",this.language))," "),e("helper-count-down",{class:"lottery-banner__info-item-value lottery-banner__info-item-value__strong",value:this.startTime,format:"DDD HHH mmM ssS",onCountDownFinish:this.handleCountdownFinish})),this.isWagerStarted&&null!=this.turnover&&e("div",{class:"lottery-banner__info-item"},e("span",{class:"lottery-banner__info-item-label"},st("turnover",this.language)),e("span",{class:"lottery-banner__info-item-value"},this.turnover)));default:return null}}render(){const t=this.layout.split(",").map((t=>t.trim()));return e("section",{key:"8714d4136821b8afd6079da769bb9cc94149ed9d",ref:t=>this.stylingContainer=t,class:"lottery-banner"},t.map(((e,n)=>this.renderElement(e,3===t.length&&1===n?"lottery-banner__item--center":""))))}static get assetsDirs(){return["../static"]}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],startTime:["handleTimeChange"],stopTime:["handleTimeChange"]}}};lt.style=":host {\n display: block;\n container-type: inline-size;\n}\n\n.lottery-banner {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--lottery-banner-gap, 0.5rem);\n padding: var(--lottery-banner-padding, 0px 20px);\n background: var(--lottery-banner-background, var(--emw--color-primary, #fed275));\n border-top: var(--lottery-banner-border-width, 2px) var(--lottery-banner-border-style, solid) var(--lottery-banner-border-color, var(--emw--color-primary, #fed275));\n border-bottom: var(--lottery-banner-border-width, 2px) var(--lottery-banner-border-style, solid) var(--lottery-banner-border-color, var(--emw--color-primary, #fed275));\n border-left: var(--lottery-banner-border-left, none);\n border-right: var(--lottery-banner-border-right, none);\n border-radius: var(--lottery-banner-border-radius, 0);\n white-space: nowrap;\n height: var(--lottery-banner-height, 50px);\n position: relative;\n box-sizing: border-box;\n}\n\n.lottery-banner__logo-wrapper {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n}\n.lottery-banner__logo-wrapper img {\n height: 100%;\n max-width: 32vw;\n object-fit: var(--lottery-banner-logo-object-fit, contain);\n}\n\n.lottery-banner__item--center {\n position: absolute;\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n}\n\n.lottery-banner__title {\n text-align: center;\n font-size: var(--lottery-banner-title-font-size, 1.5rem);\n font-weight: 800;\n font-style: italic;\n letter-spacing: var(--lottery-banner-title-font-letter-spacing, 0.04em);\n color: var(--emw--color-typography, #000);\n}\n\n.lottery-banner__info {\n display: flex;\n align-items: center;\n gap: var(--lottery-banner-info-gap, 0.75rem);\n}\n\n.lottery-banner__info-item {\n font-size: var(--lottery-banner-info-font-size, 0.9rem);\n color: var(--lottery-banner-info-color, var(--emw--color-typography, #000));\n display: inline-flex;\n align-items: center;\n gap: 0.3rem;\n}\n\n.lottery-banner__info-item-label {\n color: var(--lottery-banner-info-label-color, var(--emw--color-typography, #000));\n}\n.lottery-banner__info-item-label__strong {\n font-weight: var(--lottery-banner-info-label-font-weight, 700);\n}\n\n.lottery-banner__info-item-value {\n font-weight: var(--lottery-banner-info-value-font-weight, inherit);\n color: var(--lottery-banner-info-value-color, var(--emw--color-typography, #000));\n}\n.lottery-banner__info-item-value__strong {\n font-weight: var(--lottery-banner-info-label-font-weight, 700);\n}\n\nhelper-count-down::part(values) {\n gap: 8px;\n}\n\n@container (max-width: 700px) {\n .lottery-banner {\n height: auto;\n padding: var(--lottery-banner-mobile-padding, 0.5rem 0.2rem);\n }\n .lottery-banner__title {\n flex-basis: 100%;\n text-align: var(--lottery-banner-mobile-title-text-align, left);\n font-size: var(--emw--font-size-small, 0.875rem);\n }\n .lottery-banner__info {\n flex-direction: column;\n align-items: flex-start;\n gap: var(--lottery-banner-mobile-info-gap, 0.1rem);\n }\n .lottery-banner__info-item {\n font-size: var(--emw--font-size-x-small, 0.75rem);\n }\n}";const ct=["ro","en","fr","ar","hr","zh"],dt={en:{loading:"Loading"},ro:{},fr:{},ar:{},hr:{}},ht=class{constructor(e){t(this,e),this.handleClick=t=>{if(this.disabled)return;const e=this.host.shadowRoot.querySelector(".btn");if(!e)return;const n=e.getBoundingClientRect(),r=Math.max(n.width,n.height),i={top:t.clientY-n.top-r/2,left:t.clientX-n.left-r/2,size:r};this.ripples=[...this.ripples,i],setTimeout((()=>{this.ripples=this.ripples.filter((t=>t!==i))}),600)},this.variant="primary",this.size="medium",this.color=void 0,this.disabled=!1,this.loading=!1,this.text=void 0,this.mbSource=void 0,this.language="en",this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.ripples=[]}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])dt[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}render(){const{variant:t,disabled:n,size:r,color:i}=this,o=n||this.loading,a={};if(i)switch(t){case"primary":default:Object.assign(a,{backgroundColor:i,borderColor:i});break;case"outline":case"dashed":Object.assign(a,{color:i,borderColor:i});break;case"text":Object.assign(a,{color:i})}return e("button",{key:"aa74ad98c90e7548228557bf8a8d26b125d4a83a",class:{btn:!0,[`btn--${t}`]:!0,[`btn--${r}`]:!0,"btn--loading":this.loading},style:i?a:void 0,disabled:o,onClick:this.handleClick,ref:t=>this.stylingContainer=t},this.loading?e("div",{class:"loading-container"},e("span",{class:"content"},this.text||(()=>{const t=this.language;let e=dt[void 0!==t&&ct.includes(t)?t:"en"].loading;return e})()),e("span",{class:"spinner"})):e("span",{class:"content"},e("slot",{name:"icon-left"}),this.text||e("slot",null),e("slot",{name:"icon-right"})),e("div",{key:"302ea02be395bb24989d4abc040a513e23fa029a",class:"ripple-container"},this.ripples.map(((t,n)=>e("span",{key:n,class:"ripple",style:{top:`${t.top}px`,left:`${t.left}px`,width:`${t.size}px`,height:`${t.size}px`}})))))}get host(){return n(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};var ut;ht.style=":host{display:inline-block}.btn{font:inherit;position:relative;display:inline-flex;align-items:center;justify-content:center;border:1px solid transparent;border-radius:var(--lottery-button-border-radius, 6px);font-weight:var(--lottery-button-font-weight, 500);cursor:pointer;outline:none;overflow:hidden;transition:var(--lottery-button-transition, background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s);user-select:none;-webkit-tap-highlight-color:transparent;box-shadow:var(--lottery-button-box-shadow, 0 2px 4px 0 rgba(0, 0, 0, 0.5))}.btn .content{position:relative;display:inline-flex;align-items:center;gap:var(--lottery-button-content-gap, 0.5em)}.btn .content ::slotted(span){display:inline-flex;align-items:center}.btn:hover:not(:disabled){box-shadow:var(--lottery-button-hover-box-shadow, 0 4px 8px 0 rgba(0, 0, 0, 0.5))}.btn:disabled{cursor:not-allowed;opacity:var(--lottery-button-disabled-opacity, 0.5)}.btn .loading-container{display:flex;align-items:center}.btn--loading{position:relative}.btn .spinner{display:inline-block;width:1em;height:1em;border:var(--lottery-button-spinner-border, 2px solid rgba(255, 255, 255, 0.3));border-radius:50%;border-top-color:var(--lottery-button-spinner-color, white);animation:spin 1s ease-in-out infinite;margin-left:0.5em;vertical-align:middle}.btn--small .spinner{width:0.8em;height:0.8em}.btn--large .spinner{width:1.2em;height:1.2em}@keyframes spin{to{transform:rotate(360deg)}}.btn--primary{background-color:var(--emw--color-primary, #0d196e);color:var(--emw--color-typography-inverse, #fff)}.btn--primary:hover:not(:disabled){background-color:var(--emw--color-primary-variant, #1367e7)}.btn--primary:active:not(:disabled){background-color:var(--lottery-button-primary-active-bg, #08104a)}.btn--outline .spinner,.btn--dashed .spinner,.btn--text .spinner{border-top-color:currentColor;border-color:var(--lottery-button-spinner-inverse-border-color, rgba(0, 0, 0, 0.2))}.btn--outline{background-color:var(--emw--color-background, #fff);border-color:var(--lottery-button-outline-border-color, #dcdcdc);color:var(--emw--color-typography, #000)}.btn--outline:hover:not(:disabled){background-color:var(--emw--color-background-tertiary, #ccc);border-color:var(--lottery-button-outline-hover-border-color, #a6a6a6)}.btn--outline:active:not(:disabled){background-color:var(--lottery-button-outline-active-bg, #e6e6e6)}.btn--dashed{background-color:transparent;border-style:dashed;border-color:var(--lottery-button-dashed-border-color, #dcdcdc);color:var(--lottery-button-dashed-color, #333)}.btn--dashed:hover:not(:disabled){border-color:var(--lottery-button-dashed-hover-border-color, #a6a6a6);color:var(--lottery-button-dashed-hover-color, #0052d9)}.btn--text{background-color:transparent;color:var(--lottery-button-text-color, #0052d9);border-color:transparent}.btn--text:hover:not(:disabled){background-color:var(--lottery-button-text-hover-bg, #f2f2f2)}.btn--text:active:not(:disabled){background-color:var(--lottery-button-text-active-bg, #e6e6e6)}.btn--custom-color:hover:not(:disabled){opacity:var(--lottery-button-custom-hover-opacity, 0.9)}.btn--custom-color:active:not(:disabled){opacity:var(--lottery-button-custom-active-opacity, 0.8)}.btn--small{height:var(--lottery-button-small-height, 28px);font-size:var(--lottery-button-small-font-size, 12px);padding:var(--lottery-button-small-padding, 0 12px)}.btn--medium{height:var(--lottery-button-medium-height, 34px);font-size:var(--lottery-button-medium-font-size, 14px);padding:var(--lottery-button-medium-padding, 0 18px)}.btn--large{height:var(--lottery-button-large-height, 40px);font-size:var(--lottery-button-large-font-size, 16px);padding:var(--lottery-button-large-padding, 0 24px)}.ripple-container{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;pointer-events:none;border-radius:inherit}.ripple{position:absolute;border-radius:50%;background-color:var(--lottery-button-ripple-light, rgba(255, 255, 255, 0.3));transform:scale(0);animation:ripple-animation 600ms linear}.btn--outline .ripple,.btn--dashed .ripple,.btn--text .ripple{background-color:var(--lottery-button-ripple-dark, rgba(0, 0, 0, 0.03))}@keyframes ripple-animation{to{transform:scale(4);opacity:0}}",function(t){t.PURCHASED="Purchased",t.SETTLED="Settled",t.CANCELED="Canceled",t.ERROR="Error"}(ut||(ut={}));const mt=class{constructor(e){t(this,e),this.orderSummarySubmit=r(this,"orderSummarySubmit",7),this.submitSuccess=r(this,"lotteryTicketSubmitSuccess",7),this.submitError=r(this,"lotteryTicketSubmitError",7),this.sessionExpired=r(this,"sessionExpired",7),this.endpoint=void 0,this.sessionId=void 0,this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.language="en",this.orderSummaryTitle=void 0,this.ticketsLabel=void 0,this.totalLabel=void 0,this.showColon=!0,this.showDivider=!1,this.submitDisabled=!1,this.submitButtonText=void 0,this.submitLoading=!1}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}handleLotteryTicketParamsReady(t){if(t.detail&&this.isValidTicketSubmitParam(t.detail))this.handleSubmitTickets(t.detail);else{const e="Invalid ticket data received before submission.";console.error(e,t.detail),this.submitError.emit({message:e,dataOrigin:t.detail,status:400})}}isValidTicketSubmitParam(t){return t&&Array.isArray(t.tickets)&&t.tickets.length>0&&t.tickets.every((t=>this.isValidTicketParam(t)))}isValidTicketParam(t){return t&&void 0!==t.gameName&&void 0!==t.startingDrawId&&void 0!==t.amount&&void 0!==t.currency&&void 0!==t.selection}async handleSubmitTickets(t){try{this.submitLoading=!0;const e=await function(t,e="GET",n=null,r={}){return new Promise(((i,o)=>{const a="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)})),s=Object.assign({"Content-Type":"application/json"},r);"GET"!==e&&"HEAD"!==e&&(s["X-Idempotency-Key"]=a);const l={method:e,headers:s,body:null};n&&"GET"!==e&&"HEAD"!==e?l.body=JSON.stringify(n):delete l.body,fetch(t,l).then((t=>t.ok?t.json():o(t))).then((t=>i(t))).catch((t=>o(t)))}))}(`${this.endpoint}/tickets`,"POST",t,{Authorization:`Bearer ${this.sessionId}`});e.tickets.every((t=>t.state===ut.PURCHASED))?this.submitSuccess.emit({dataOrigin:e,status:200}):this.submitError.emit({message:"Failed to purchase ticket",dataOrigin:e,status:200})}catch(t){401===t.status&&this.sessionExpired.emit(),(t.status>300||!t.status)&&this.submitError.emit({dataOrigin:t,status:t.status||0})}finally{this.submitLoading=!1}}handleSubmit(){this.orderSummarySubmit.emit()}render(){return e("div",{key:"bdab321b9336f47e16057d240b3226d7cba59b97",ref:t=>this.stylingContainer=t},e("div",{key:"de7ffcc9f96d8c7cfc7bdb3a3c7225ee78c33483",class:"order-summary"},e("h3",{key:"9500cd69a6eba0855d4981cdad8eaa91b9c98567",class:"order-summary__title"},this.orderSummaryTitle),e("div",{key:"ce29c82eef1d12bc63e94e4fa2d5474700860af2",class:"order-summary__ticket"},e("div",{key:"9db79da17590c7f847f46c3b3b66489ea9a0e268",class:"order-summary__ticket-info"},e("div",{key:"4b5a2df807aeb421cf3c1ebf33f410a92f39ccaf",class:"order-summary__ticket-label"},e("div",{key:"feb73e9f849d2e3d6b77e4c848657f27e6a82323",class:"order-summary__ticket"},this.ticketsLabel),e("span",{key:"51f70dcdda2154d8ce97d8e1a7c0f61a6198afbb",class:"order-summary__colon"},this.showColon?":":null)),e("div",{key:"4fed2d63cd7a881c8844055fe1fde99c8c7aa9fb",class:"order-summary__details"},e("slot",{key:"6a7969738546ee4aca81a075f6174556e78d2c31",name:"orderSummaryTicketDetail"}))),this.showDivider&&e("hr",{key:"029803fa93960d5098a24d5ca18e77e14562b29f",class:"order-summary__divider"}),e("div",{key:"738096c5b605a97851dbf24a972d93d9533ad48b",class:"order-summary__ticket-info"},e("div",{key:"acd8a7f3e64c97f58c79f57a90143151c996abf8",class:"order-summary__ticket-label"},e("div",{key:"44e6b29978ca4fc2b22ca9d95ee4facfc883f292",class:"order-summary__ticket"},this.totalLabel),e("span",{key:"330a00a4b39e578a1b0d80211d2b68d44c5235c9",class:"order-summary__colon"},this.showColon?":":null)),e("span",{key:"294046815a62a80366458aade4ec5d5476577a93",class:"order-summary__details"},e("slot",{key:"02d129ef0caf523ec0c9da34318df46d3b008376",name:"orderSummaryTotalDetail"})))),e("slot",{key:"9395396883f0594ad8db216a9aa9fa0aeff45c10",name:"orderSummaryChoice"}),e("div",{key:"462672abc490cde00fea90ea585f48875ca2ec47",class:"order-summary__button-wrapper"},e("lottery-button",{key:"1885bee3570ce6b58d4ae1977c635f418485fdbe",onClick:this.handleSubmit.bind(this),loading:this.submitLoading,disabled:this.submitDisabled,text:this.submitButtonText}))))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};mt.style=":host{width:100%}.order-summary{width:100%;background:var(--emw--color-background, #fff);border-radius:var(--lottery-order-summary-border-radius, 8px);border:var(--lottery-order-summary-border, none);box-shadow:var(--lottery-order-summary-box-shadow, none);box-sizing:border-box}.order-summary__title{margin:var(--lottery-order-summary-title-margin, 0 0 30px 0);text-align:var(--lottery-order-summary-title-text-align, center);color:var(--emw--color-typography, #000);text-transform:uppercase;font-weight:var(--lottery-order-summary-title-font-weight, 700)}.order-summary__ticket-info{display:flex;align-items:center;margin-bottom:var(--lottery-order-summary-row-gap, 16px);gap:var(--lottery-order-summary-col-gap, 10px);color:var(--emw--color-typography, #000)}.order-summary__ticket-label{display:flex;flex-direction:row;align-items:center;width:var(--lottery-order-summary-label-width, 50px);max-width:var(--lottery-order-summary-label-max-width, 100%);flex-shrink:0}.order-summary__colon{margin-left:2px}.order-summary__ticket{font-weight:var(--lottery-order-summary-label-font-weight, 500);color:var(--emw--color-typography, #000);overflow-wrap:break-word}.order-summary__details{display:flex;align-items:center;color:var(--emw--color-typography, #000);font-weight:var(--lottery-order-summary-details-font-weight, 400)}.order-summary__divider{border:none;border-top:var(--lottery-order-summary-divider-border, 1px solid var(--emw--color-gray-100, #e6e6e6));margin:var(--lottery-order-summary-divider-margin, 20px 0)}.order-summary__button-wrapper{display:flex;justify-content:center;margin:var(--lottery-order-summary-button-wrapper-margin, 0);padding:var(--lottery-order-summary-button-wrapper-padding, 0)}";const bt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 256H736v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zm-200 0H360v-72h304v72z"}}]},name:"delete",theme:"filled"},ft={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"},gt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"},pt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},yt={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},vt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"plus-square",theme:"outlined"},wt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"};var xt=function(){return xt=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},xt.apply(this,arguments)},kt={primaryColor:"#333",secondaryColor:"#E6E6E6"};function _t(t,e){if(void 0===e&&(e={}),"function"==typeof t.icon){var n=e.placeholders||kt;return St(t.icon(n.primaryColor,n.secondaryColor),e)}return St(t.icon,e)}function St(t,e){var n="svg"===t.tag?xt(xt({},t.attrs),e.extraSVGAttrs||{}):t.attrs,r=Object.keys(n).reduce((function(t,e){var r=n[e],i="".concat(e,'="').concat(r,'"');return t.push(i),t}),[]),i=r.length?" "+r.join(" "):"",o=(t.children||[]).map((function(t){return St(t,e)})).join("");return o&&o.length?"<".concat(t.tag).concat(i,">").concat(o,"</").concat(t.tag,">"):"<".concat(t.tag).concat(i," />")}const Ct=class{constructor(e){t(this,e),this.lotteryBulletClickHandler=r(this,"lotteryBulletClick",7),this.value=0,this.text=void 0,this.idx=void 0,this.type="toggle",this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.hasBorder=!0,this.hasBackground=!0,this.deleteIconSvg="",this.deleteIconWidth="16px",this.deleteIconHeight="16px"}handleClientStylingChange(t,e){t!==e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!==e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!==e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}handleClick(){"disabled"!==this.type&&"readonly"!==this.type&&(console.log("bullet clicked",this.type,this.idx,this.text,this.value),this.lotteryBulletClickHandler.emit({type:this.type,idx:this.idx,text:this.text,value:this.value}))}render(){let t;return t=this.deleteIconSvg?function(t){let e=t.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,"");return e=e.replace(/on[a-z]+=[\"'][^\"']*[\"']/gi,""),e=e.replace(/javascript:/gi,""),e}(this.deleteIconSvg):_t(bt,{extraSVGAttrs:{width:this.deleteIconWidth,height:this.deleteIconHeight,fill:"currentColor"}}),e("div",{key:"0d1e8aaa80a907a7467410f6b27b4b6175e82299",class:"lottery-selection",ref:t=>this.stylingContainer=t},e("button",{key:"11a2402abbc290dc877ad95f3433092c3a0d8419",class:{"lottery-selection__button":!0,"lottery-selection__button--selected":1==this.value,"lottery-selection__button--disabled":"disabled"===this.type,"lottery-selection__button--no-border":!this.hasBorder,"lottery-selection__button--no-background":!this.hasBackground,isDeleteByIcon:"delete"===this.type,isCallDialogBtn:"input"===this.type||"readonly"===this.type},onClick:this.handleClick.bind(this),disabled:"disabled"===this.type},"delete"===this.type&&e("span",{key:"f99001d936a8f7bdf8adc5c46e82caf730a9442a",class:"lottery-selection__delete-icon",innerHTML:t}),e("span",{key:"55775e2492a1fe45cc8a457ac0a0d206744461ab",class:"lottery-selection__text"},this.text)))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};Ct.style=":host{display:inline-block}.lottery-selection__button{display:flex;align-items:center;justify-content:center;width:var(--lottery-selection-width, 32px);height:var(--lottery-selection-height, 32px);padding:var(--lottery-selection-padding, 0);box-sizing:border-box;background:var(--lottery-selection-background, var(--emw--color-background, #fff));border:var(--lottery-selection-border-width, 2px) var(--lottery-selection-border-style, solid) var(--lottery-selection-border-color, var(--emw--color-primary, #0d196e));border-radius:var(--lottery-selection-border-radius, var(--emw--border-radius-medium, 8px));color:var(--lottery-selection-color, var(--emw--color-typography, #000));font-weight:var(--lottery-selection-font-weight, bold);font-size:var(--lottery-selection-font-size, 1em);cursor:pointer;user-select:none;}.lottery-selection__button:hover{background:var(--lottery-selection-hover-background, var(--emw--color-background, #fff));border-color:var(--lottery-selection-hover-border-color, var(--emw--color-primary, #0d196e));color:var(--lottery-selection-hover-color, var(--emw--color-typography, #000))}.lottery-selection__button .lottery-selection__delete-icon{display:none}.lottery-selection__button.isDeleteByIcon:hover .lottery-selection__text{display:none}.lottery-selection__button.isDeleteByIcon:hover .lottery-selection__delete-icon{display:flex;align-items:center;justify-content:center;fill:var(--lottery-selection-delete-icon-color, var(--emw--color-typography, #000));vertical-align:middle}.lottery-selection__button.lottery-selection__button--selected{background-color:var(--lottery-selection-selected-background, var(--emw--color-primary, #0d196e));border-color:var(--lottery-selection-selected-border-color, var(--emw--color-primary, #0d196e));color:var(--lottery-selection-selected-color, var(--emw--color-typography-inverse, #fff))}.lottery-selection__button.lottery-selection__button--disabled{background-color:var(--lottery-selection-disabled-background, var(--emw--color-gray-50, #f5f5f5));border-color:var(--lottery-selection-disabled-border-color, var(--emw--color-gray-100, #e6e6e6));color:var(--lottery-selection-disabled-color, var(--emw--color-gray-150, #6f6f6f));cursor:not-allowed;pointer-events:none;}.lottery-selection__button.lottery-selection__button--no-border{border:none}.lottery-selection__button.lottery-selection__button--no-background{background:transparent}";const Tt=["ro","en","fr","ar","hr","zh"],Mt={en:{noTicketBoard:"No ticket board available.",selectionCleared:"Your selection has been cleared.",clearAll:"Clear All",stopAt:"Stop at",turnover:"Turnover: ",pleaseFillIn:"Please fill in all the selection input!",fillIn:"Fill in",noBets:"Sorry. No bets have been placed so far. Check back later!",search:"Search",clear:"Clear",oddsChart:"Odds Chart",ticketSuccess:"Ticket purchased successfully.",stakePerLine:"Stake per Line:",lowestOdds:"Lowest Odds:",highestOdds:"Highest Odds:",orderSummary:"ORDER SUMMARY",ticket:"Ticket",lines:"Lines",total:"Total",submit:"Submit",loading:"Loading",enterValidNumber:"Please enter a valid number.",enterNumberBetween:"Please enter a number between {min} and {max}.",numberAlreadySelected:"This number has already been selected.",enterScoreUpTo:"Please enter the score (Up to {maxScore})",enterValue:"Please enter a value",myChoices:"My Choices",teams:"Teams",scores:"Scores",euro:"Euro",cancel:"Cancel",confirm:"Confirm"},ro:{},fr:{},ar:{},hr:{}},Lt=(t,e,n)=>{const r=e;let i=Mt[void 0!==r&&Tt.includes(r)?r:"en"][t];return n&&Object.keys(n).forEach((t=>{i=i.replace(`{${t}}`,n[t])})),i};function Dt(t,e){return new Set(t?t.split(e):[])}function zt(t,e){return e.filter((e=>e!==t))}function Bt(t,e){return e.concat([t])}const jt=class{constructor(e){t(this,e),this.bulletGroupUpdateSelectedBulletTexts=r(this,"bulletGroupUpdateSelection",7),this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.language="en",this.translationUrl="",this.splitToken=",",this.selectionGroupId=void 0,this.selectionGroupLabel=void 0,this.type="bet",this.selectedBulletTexts=null,this.maxSelectedCount=null,this.maxDisplayBulletsCount=11,this.bulletTexts=null,this.maxIntegerBulletText=null,this.minIntegerBulletText=0,this.bulletTextType="integer",this.hasBorder=!0,this.hasBackground=!0,this.dialogTitle=void 0,this.dialogInputPlaceholder=void 0,this.disabledBulletTexts="",this.dialogConfig={width:"400px",visible:!1,onConfirm:()=>this.handleFillInAddMore(),onCancel:()=>this.handleCloseAddMoreDialog()},this.inputInfo={valid:!0,errorMessage:"",value:""}}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentWillLoad(){var t;this.translationUrl&&(t=JSON.parse(this.translationUrl),Object.keys(t).forEach((e=>{for(let n in t[e])Mt[e][n]=t[e][n]})))}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}lotteryBulletClickHandler(t){if(t.stopPropagation(),"input"!==t.detail.type)if(["delete","toggle"].includes(t.detail.type))this.bulletGroupUpdateSelectedBulletTexts.emit({newSelectedBulletTexts:(e=t.detail,n=Array.from(this.selectedSet),r=this.maxSelectedCount,"delete"===e.type?zt(e.text,n):"toggle"===e.type?n.includes(e.text)?zt(e.text,n):n.length>=r?function(t,e,n){return e.slice(e.length-(n-1)).concat([t])}(e.text,n,r):Bt(e.text,n):[]).join(this.splitToken),selectionGroupId:this.selectionGroupId});else var e,n,r;else this.dialogConfig=Object.assign(Object.assign({},this.dialogConfig),{visible:!0})}get selectedSet(){return Dt(this.selectedBulletTexts,this.splitToken)}get disabledSet(){return Dt(this.disabledBulletTexts,this.splitToken)}get bulletTextsSet(){return this.bulletTexts?Dt(this.bulletTexts,this.splitToken):"integer"===this.bulletTextType&&null!=this.maxIntegerBulletText?Dt(Array.from({length:Number(this.lastDisplayBulletText)-this.minIntegerBulletText+1},((t,e)=>this.minIntegerBulletText+e)).join(this.splitToken),this.splitToken):new Set}get lastDisplayBulletText(){if("integer"===this.bulletTextType)return null!=this.maxIntegerBulletText?Math.min(this.maxIntegerBulletText,this.minIntegerBulletText+this.maxDisplayBulletsCount-1):this.minIntegerBulletText+this.maxDisplayBulletsCount-1;if(this.bulletTextsSet.size>0){const t=Array.from(this.bulletTextsSet);return t.length>=this.maxDisplayBulletsCount?t[this.maxDisplayBulletsCount-1]:t[t.length-1]}return null}get isSingleSelectionMode(){return 1===this.maxSelectedCount}getBulletToRender(){const t=Array.from(this.bulletTextsSet);let e=t,n=!1;return"text"===this.bulletTextType?t.length>this.maxDisplayBulletsCount?(n=!0,e=t.slice(0,this.maxDisplayBulletsCount-1)):e=t:(n=null!=this.maxIntegerBulletText&&this.maxIntegerBulletText>Number(this.lastDisplayBulletText),e=t),{bulletsToRender:e,showInputButton:n}}renderBulletGroup(){let t=[];if("bet"===this.type){const e=null!==this.maxSelectedCount&&this.selectedSet.size>=this.maxSelectedCount,{bulletsToRender:n,showInputButton:r}=this.getBulletToRender();if(n.forEach(((n,r)=>{let i="toggle";this.disabledSet.has(String(n))?i="disabled":this.selectedSet.has(String(n))||!e||this.isSingleSelectionMode||(i="disabled"),t.push({value:this.selectedSet.has(String(n))?1:0,text:String(n),idx:r,type:i})})),r){let n="input";e&&!this.isSingleSelectionMode&&(n="disabled");const r="text"===this.bulletTextType?"...":`${this.lastDisplayBulletText}+`,i="text"===this.bulletTextType?-1:Number(this.lastDisplayBulletText)+1;"integer"===this.bulletTextType&&t.length>=this.maxDisplayBulletsCount&&t.pop(),t.push({value:0,text:r,idx:i,type:n})}}else if(["choice","preview"].includes(this.type)){const{bulletsToRender:e}=this.getBulletToRender();e.forEach(((e,n)=>{let r="toggle";this.disabledSet.has(String(e))?r="disabled":"preview"===this.type?r="readonly":this.selectedSet.has(String(e))&&(r="delete"),t.push({value:this.selectedSet.has(String(e))?1:0,text:e,idx:n,type:r})}))}return e("div",{class:"lottery-selection-group__item--right"},t.map((t=>e("lottery-selection",{clientStyling:this.clientStyling,clientStylingUrl:this.clientStylingUrl,mbSource:this.mbSource,text:t.text,idx:t.idx,value:t.value,type:t.type,hasBorder:this.hasBorder,hasBackground:this.hasBackground}))))}handleCloseAddMoreDialog(){this.dialogConfig=Object.assign(Object.assign({},this.dialogConfig),{visible:!1}),this.inputInfo={value:"",errorMessage:"",valid:!0}}handleInputChange(t){const e=t.target.value;this.inputInfo=Object.assign(Object.assign({},this.inputInfo),{value:e}),this.inputInfo=function({value:t,selectedSet:e,maxValue:n,minValue:r,language:i,type:o="integer"}){const a=t.trim();if("integer"===o){if(!/^-?\d+$/.test(a))return{valid:!1,errorMessage:Lt("enterValidNumber",i),value:t};const o=Number(a);if(isNaN(o))return{valid:!1,errorMessage:Lt("enterValidNumber",i),value:t};if(void 0!==r&&o<r||void 0!==n&&o>n)return{valid:!1,errorMessage:Lt("enterNumberBetween",i,{min:r,max:n}),value:t};const s=String(o);if(e.has(s))return{valid:!1,errorMessage:Lt("numberAlreadySelected",i),value:t}}else if(e.has(a))return{valid:!1,errorMessage:Lt("numberAlreadySelected",i),value:t};return{valid:!0,errorMessage:"",value:t}}({value:e,selectedSet:this.selectedSet,maxValue:this.maxIntegerBulletText,minValue:"integer"===this.bulletTextType?Number(this.lastDisplayBulletText)+1:void 0,language:this.language,type:this.bulletTextType})}handleFillInAddMore(){if(this.inputInfo.valid){const{value:t}=this.inputInfo;let e,n=t;n="integer"===this.bulletTextType?String(Number(t)):t.trim(),e=this.isSingleSelectionMode?n:Bt(n,Array.from(this.selectedSet)).join(this.splitToken),this.bulletGroupUpdateSelectedBulletTexts.emit({newSelectedBulletTexts:e,selectionGroupId:this.selectionGroupId}),this.handleCloseAddMoreDialog()}}render(){return e("div",{key:"39225bad75cf435b166269367df570732eff7ef4",class:"lottery-selection-group",ref:t=>this.stylingContainer=t},e("div",{key:"2bb2bc539c9fc05aeece7145b13f722756bc054e",class:"lottery-selection-group__item"},this.selectionGroupLabel&&e("div",{key:"dc15197dca90375bd4eb50e87d96402d1ef694d2",class:"lottery-selection-group__item--left"},this.selectionGroupLabel),this.renderBulletGroup()),e("lottery-tipping-dialog",{key:"9526dbb5d1656d6724e6566465febde778437c64",visible:this.dialogConfig.visible,width:this.dialogConfig.width,onCancel:this.dialogConfig.onCancel},e("div",{key:"ecf5800430e92be4a2af279f1d8c5075d5965b7e",class:"addSelectionDialog"},e("div",{key:"3e8a2f445679ef5fe2ada60d4a6832f472f27dfa",class:"addSelectionDialog-title"},this.dialogTitle||("text"===this.bulletTextType?Lt("enterValue",this.language):Lt("enterScoreUpTo",this.language,{maxScore:this.maxIntegerBulletText}))),e("input",{key:"46462ee8f27410639d45970a76fc3d90a03f3a10",type:"text",class:{"dialog-input":!0,invalid:!this.inputInfo.valid},value:this.inputInfo.value,onInput:this.handleInputChange.bind(this),placeholder:this.dialogInputPlaceholder}),e("div",{key:"2e66988e4186f8f4f773ed548fc76e53085be946",class:"error-message"},this.inputInfo.errorMessage)),e("div",{key:"81dc64f0b7cba422a54af8ecff4734aa19832583",slot:"footer",class:"addSelectionDialog-footer"},e("lottery-button",{key:"3027240894aef525dc9fc50db79597cf29f9cb99",onClick:this.dialogConfig.onCancel,text:Lt("cancel",this.language),variant:"outline"}),e("lottery-button",{key:"ab8c6deed9ab4a7d79d71ed6fe8122b23af5741b",onClick:this.dialogConfig.onConfirm,text:Lt("confirm",this.language),variant:"primary",disabled:!this.inputInfo.valid||!this.inputInfo.value}))))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};jt.style=":host {\n width: 100%;\n}\n\n.lottery-selection-group {\n container-type: inline-size;\n padding: var(--lottery-selection-group-padding, 0);\n background: var(--lottery-selection-group-background, transparent);\n border: var(--lottery-selection-group-border, none);\n border-radius: var(--lottery-selection-group-border-radius, 0);\n}\n.lottery-selection-group__item {\n display: flex;\n flex-direction: var(--lottery-selection-group-flex-direction, row);\n align-items: var(--lottery-selection-group-item-align, center);\n justify-content: var(--lottery-selection-group-item-justify, flex-start);\n gap: var(--lottery-selection-group-item-gap, 16px);\n width: 100%;\n}\n.lottery-selection-group__item--left {\n width: var(--lottery-selection-group-label-width, 130px);\n min-width: var(--lottery-selection-group-label-min-width, auto);\n max-width: var(--lottery-selection-group-label-max-width, none);\n color: var(--lottery-selection-group-label-color, var(--emw--color-typography, #000));\n font-size: var(--lottery-selection-group-label-font-size, 1em);\n font-weight: var(--lottery-selection-group-label-font-weight, bold);\n text-align: var(--lottery-selection-group-label-align, left);\n white-space: var(--lottery-selection-group-label-white-space, normal);\n}\n.lottery-selection-group__item--right {\n flex: 1;\n display: flex;\n flex-wrap: var(--lottery-selection-group-bullets-wrap, wrap); /* Allow items to wrap */\n gap: var(--lottery-selection-group-bullets-gap, 8px); /* Gap between bullets */\n align-items: var(--lottery-selection-group-bullets-align, center);\n justify-content: var(--lottery-selection-group-bullets-justify, flex-start); /* Align bullets to start */\n}\n@container (max-width: 320px) {\n .lottery-selection-group__item--left {\n width: 100px;\n max-width: 100px;\n }\n}\n\n.dialog-input {\n width: 100%;\n padding: var(--lottery-selection-group-input-padding, 8px);\n border: var(--lottery-selection-group-input-border-width, 1px) var(--lottery-selection-group-input-border-style, solid) var(--lottery-selection-group-input-border-color, var(--emw--color-gray-100, #e6e6e6));\n border-radius: var(--lottery-selection-group-input-radius, 4px);\n background-color: var(--lottery-selection-group-input-bg, #fff);\n color: var(--lottery-selection-group-input-color, #000);\n box-sizing: border-box;\n margin-top: var(--lottery-selection-group-input-margin-top, 10px);\n font-size: var(--lottery-selection-group-input-font-size, 1em);\n}\n.dialog-input::placeholder {\n color: var(--lottery-selection-group-input-placeholder-color, #999);\n}\n\n.dialog-input.invalid,\n.dialog-input.invalid:focus {\n border-color: var(--emw--color-error, #ff3d00);\n outline-color: var(--emw--color-error, #ff3d00);\n}\n\n.error-message {\n color: var(--lottery-selection-group-error-color, var(--emw--color-error, #ff3d00));\n font-size: var(--lottery-selection-group-error-font-size, 12px);\n font-weight: var(--lottery-selection-group-error-font-weight, normal);\n margin-top: 4px;\n}\n\n.addSelectionDialog-title {\n color: var(--lottery-selection-group-dialog-title-color, var(--emw--color-typography, #000));\n font-size: var(--lottery-selection-group-dialog-title-font-size, 1.2em);\n font-weight: var(--lottery-selection-group-dialog-title-font-weight, bold);\n margin-bottom: var(--lottery-selection-group-dialog-title-margin-bottom, 0);\n}\n.addSelectionDialog-footer {\n display: flex;\n justify-content: var(--lottery-selection-group-dialog-footer-justify, flex-end);\n gap: var(--lottery-selection-group-dialog-footer-gap, 18px);\n margin-top: var(--lottery-selection-group-dialog-footer-margin-top, 0);\n}";const Ot=["ro","en","fr","ar","hr"],Pt={en:{homeTeam:"Home team:",awayTeam:"Away team:",loading:"Loading...",error:"Error!",noData:"No data available.",lineInfo:"Line {currentPage} of {totalPages}",clearAll:"Clear All"},ro:{homeTeam:"Echipa gazdă:",awayTeam:"Echipa oaspete:",selectionCleared:"Selecția dvs. a fost ștearsă.",selectionOnLineCleared:"Selecția dvs. de pe această linie va fi ștearsă.",loading:"Se încarcă...',n error: 'Eroare!",noData:"Nu sunt date disponibile.",lineInfo:"Linia {currentPage} din {totalPages}",clearAll:"Șterge tot",cancel:"Anulează",confirm:"Confirmă"},fr:{homeTeam:"Équipe à domicile:",awayTeam:"Équipe à l'extérieur:",selectionCleared:"Votre sélection a été effacée.",selectionOnLineCleared:"Votre sélection sur cette ligne sera effacée.",loading:"Chargement...',n error: 'Erreur!",noData:"Aucune donnée disponible.",lineInfo:"Ligne {currentPage} sur {totalPages}",clearAll:"Tout effacer",cancel:"Annuler",confirm:"Confirmer"},ar:{homeTeam:"الفريق المضيف:",awayTeam:"الفريق الضيف:",selectionCleared:"تم مسح اختيارك.",selectionOnLineCleared:"سيتم مسح اختيارك في هذا السطر.",loading:"جار التحميل...',n error: 'خطأ!",noData:"لا توجد بيانات متاحة.",lineInfo:"السطر {currentPage} من {totalPages}",clearAll:"مسح الكل",cancel:"إلغاء",confirm:"تأكيد"},hr:{homeTeam:"Domaći tim:",awayTeam:"Gostujući tim:",selectionCleared:"Vaš odabir je obrisan.",selectionOnLineCleared:"Vaš odabir na ovoj liniji bit će obrisan.",loading:"Učitavanje...',n error: 'Greška!",noData:"Nema dostupnih podataka.",lineInfo:"Linija {currentPage} od {totalPages}",clearAll:"Očisti sve",cancel:"Odustani",confirm:"Potvrdi"}},At=(t,e,n)=>{const r=e;let i=Pt[void 0!==r&&Ot.includes(r)?r:"en"][t];return n&&Object.keys(n).forEach((t=>{i=i.replace(`{${t}}`,n[t])})),i},Ht=async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])Pt[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e},Et=({columns:t,dataSource:n,hideHead:r=!1,grid:i=!0,bordered:o=!0})=>e("table",{class:{bordered:o,grid:i,"my-table-component":!0}},!r&&e("thead",null,e("tr",null,t.map((t=>{var n;return e("th",{key:t.value,style:{width:t.width+"%",textAlign:t.align}},"string"==typeof t.title?t.title:null===(n=t.title)||void 0===n?void 0:n.call(t))})))),e("tbody",null,n.map(((n,r)=>e("tr",{key:r},t.map((t=>e("td",{key:t.value,style:{width:t.width+"%",textAlign:t.align},class:{"no-wrap":t.nowrap}},t.render?t.render(n,n[t.value],r):n[t.value])))))))),Gt=class{constructor(n){t(this,n),this.selectionChangeHandler=r(this,"lotteryTippingBetSelectionChange",7),this.clearAll=r(this,"lotteryTippingBetClearAll",7),this.addLine=r(this,"lotteryTippingBetAddLine",7),this.removeLine=r(this,"lotteryTippingBetRemoveLine",7),this.pageChange=r(this,"lotteryTippingBetPageChange",7),this.columns=[{title:"",value:"index",width:3},{title:"",value:"eventName",width:65,render:(t,e)=>this.renderEventName(t,e)},{title:"",value:"startTime",width:22,align:"right",nowrap:!0,render:(t,e)=>(({date:t,type:e="date",format:n})=>{try{const r=m(t);if(isNaN(r.getTime()))throw new Error(`Invalid date: ${t}`);if(n)return nt(r,n);let i="dd/MM/yyyy";return"time"===e?i="dd/MM/yyyy HH:mm:ss":"week"===e&&(i="ccc dd/MM/yyyy HH:mm:ss"),nt(r,i)}catch(t){return console.error("Error formatting date:",t.message),""}})({date:e,format:"ccc HH:mm"})},{title:()=>e("lottery-selection-group",{language:this.language,"translation-url":this.translationUrl,"client-styling":this.clientStyling,clientStylingUrl:this.clientStylingUrl,type:"preview",splitToken:this.bulletTextsSplitToken,"bullet-texts":this.bulletNames,bulletTextType:"text",hasBackground:!1,hasBorder:!1}),value:"results",width:10,render:(t,n,r)=>e("lottery-selection-group",{language:this.language,"translation-url":this.translationUrl,"client-styling":this.clientStyling,clientStylingUrl:this.clientStylingUrl,"mb-source":this.mbSource,selectionGroupId:`${this.currentPage-1}${this.bulletTextsSplitToken}${r}`,type:this.readPretty?"preview":"bet","selected-bullet-texts":this.selectedBulletTexts(r),"disabled-bullet-texts":this.getBulletDisabledOptions(r),"max-selected-count":"single"===this.mode?1:this.bulletTexts.split(this.bulletTextsSplitToken).length,"bullet-texts":this.bulletTexts,splitToken:this.bulletTextsSplitToken,bulletTextType:"text"})}],this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.translationUrl="",this.language="en",this.totalPages=1,this.minTotalPages=1,this.maxTotalPages=3,this.bulletTexts="1,X,2",this.bulletNames="Home,Draw,Away",this.bulletTextsSplitToken=",",this.showClearButton=!0,this.addImage=_t(vt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.deleteImage=_t(ft,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.infoImage=_t(gt,{extraSVGAttrs:{width:"16px",height:"16px",fill:"currentColor"}}),this.leftImage=_t(pt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.rightImage=_t(wt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}}),this.mode="multi",this.readPretty=!1,this.ticketDataSourceStr="[]",this.bulletSelectionsLineGroupStr="[]",this.currentPage=1,this.bulletSelectionsLineGroup=[],this.ticketDataSource=[],this.betIsLoading=!1,this.betHasErrors=!1}renderEventName(t,n){const[r,i]=n.split(" vs ");return e("div",{class:"flex gap-1 eventNameContainer__item"},e("span",{class:"eventNameContainer__item--title"},n),e("app-tooltip",null,e("span",{slot:"trigger",class:"icon info-icon",innerHTML:this.infoImage,style:{width:"18px"}}),e("div",{slot:"content"},e("div",{class:"match-info"},e("div",{class:"match-info-item"},e("div",{class:"match-info-item-label"},At("homeTeam",this.language)),e("div",{class:"match-info-item-value"},r)),e("div",{class:"match-info-item"},e("div",{class:"match-info-item-label"},At("awayTeam",this.language)),e("div",{class:"match-info-item-value"},i))))))}selectedBulletTexts(t){var e,n,r;return(null===(r=null===(n=null===(e=this.bulletSelectionsLineGroup)||void 0===e?void 0:e[this.currentPage-1])||void 0===n?void 0:n[t])||void 0===r?void 0:r.join(this.bulletTextsSplitToken))||""}getBulletDisabledOptions(t){const{outcomes:e}=this.ticketDataSource[t],n=e.map((t=>t.betOn));return this.bulletTexts.split(this.bulletTextsSplitToken).filter((t=>!n.includes(t))).join(this.bulletTextsSplitToken)}handleNewTranslations(){Ht(this.translationUrl)}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}parseTicketDataSource(t){try{this.ticketDataSource=JSON.parse(t||"[]")}catch(t){console.error("Failed to parse ticketDataSourceStr:",t)}}parseBulletSelectionsLineGroup(t){try{this.bulletSelectionsLineGroup=JSON.parse(t||"[]")}catch(t){console.error("Failed to parse bulletSelectionsLineGroupStr:",t)}}connectedCallback(){this.boundMessageHandler=this.messageHandler.bind(this),window.addEventListener("message",this.boundMessageHandler)}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe(),this.boundMessageHandler&&window.removeEventListener("message",this.boundMessageHandler)}messageHandler(){}componentWillLoad(){Ht(this.translationUrl),this.parseTicketDataSource(this.ticketDataSourceStr),this.parseBulletSelectionsLineGroup(this.bulletSelectionsLineGroupStr)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription),this.clientStyling&&c(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&h(this.stylingContainer,this.clientStylingUrl))}handleClearAll(){this.clearAll.emit()}bulletGroupUpdateSelectionHandler(t){t.stopPropagation();const{newSelectedBulletTexts:e,selectionGroupId:n}=t.detail;if(!n)return void console.error("Miss selectionGroupId");const r=n.split(this.bulletTextsSplitToken);if(2!==r.length)return void console.error("Invalid selectionGroupId format:",n);const[i,o]=r;this.selectionChangeHandler.emit({newSelections:e.split(this.bulletTextsSplitToken),matchId:o,boardId:i})}prevPage(){this.swapCard("prev",(()=>{this.pageChange.emit({newPage:this.currentPage-1})}))}nextPage(){this.swapCard("next",(()=>{this.pageChange.emit({newPage:this.currentPage+1})}))}handleAddLine(){this.swapCard("add",(()=>{this.addLine.emit()}))}handleRemoveLine(){this.removeLine.emit({boardId:this.currentPage-1,close:t=>{t&&this.swapCard("remove",t)}})}swapCard(t,e){const n=this.mainContainer;if(!n)return;if(Array.from(n.classList).some((t=>t.startsWith("card-out-")||t.startsWith("card-in-"))))return;const{out:r,in:i}={next:{out:"card-out-left",in:"card-in-left"},prev:{out:"card-out-right",in:"card-in-right"},remove:{out:"card-out-down",in:"card-in-right"},add:{out:"card-out-left",in:"card-in-up"}}[t];n.classList.add(r),n.addEventListener("animationend",(()=>{n.classList.remove(r),e();const t=this.mainContainer;t&&(t.classList.add(i),t.addEventListener("animationend",(()=>t.classList.remove(i)),{once:!0}))}),{once:!0})}renderLoading(){return e("div",{class:"loading-wrap"},e("section",{class:"dots-container"},e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"}),e("div",{class:"dot"})))}renderErrorContent(){return e("p",null,At("error",this.language))}renderEmptyContent(){return e("div",{class:"LotteryTippingTicketBet__empty"},e("p",null,At("noData",this.language)))}renderPageFooter(){return this.totalPages<=1?null:e("div",null,e("div",{class:"border-line"}),e("div",{class:"LotteryTippingTicketBet__footer"},e("div",{class:"my-pagination flex justify-between"},e("span",null,At("lineInfo",this.language,{currentPage:this.currentPage,totalPages:this.totalPages})),e("div",{class:"flex gap-1"},e("button",{type:"button",class:"btn "+(1===this.currentPage?"disabled":""),onClick:()=>this.prevPage(),disabled:1===this.currentPage},e("span",{class:"icon",innerHTML:this.leftImage})),e("button",{type:"button",class:"btn "+(this.currentPage===this.totalPages?"disabled":""),onClick:()=>this.nextPage(),disabled:this.currentPage===this.totalPages},e("span",{class:"icon",innerHTML:this.rightImage}))))))}renderReadPrettyContent(){var t;return e("div",{class:"LotteryTippingTicketBet__main",ref:t=>this.mainContainer=t},e("div",{class:"table-scroll-wrapper"},e(Et,{columns:this.columns,dataSource:(null===(t=this.ticketDataSource)||void 0===t?void 0:t.map(((t,e)=>Object.assign(Object.assign({},t),{index:e+1}))))||[],hideHead:!1,grid:!1,bordered:!1})),this.renderPageFooter())}renderDefaultContent(){var t;const n=this.totalPages<this.maxTotalPages&&this.currentPage===this.totalPages,r=this.totalPages>this.minTotalPages;return e("div",null,e("div",{class:"LotteryTippingTicketBet__tableToolbar flex justify-end gap-1"},this.showClearButton&&e("lottery-button",{class:{"LotteryTippingTicketBet__tableToolbar--item":!0,"mr-0":!(n||r)},text:At("clearAll",this.language),onClick:()=>this.handleClearAll(),variant:"text",clientStyling:this.clientStyling||""})),e("div",{class:"flex align-center LotteryTippingTicketBet__main",ref:t=>this.mainContainer=t},e("div",{class:"table-scroll-wrapper"},e(Et,{columns:this.columns,dataSource:(null===(t=this.ticketDataSource)||void 0===t?void 0:t.map(((t,e)=>Object.assign(Object.assign({},t),{index:e+1}))))||[],hideHead:!1,grid:!1,bordered:!1})),(n||r)&&e("div",{class:"LotteryTippingTicketBet__lineOperatorGroup"},n&&e("button",{type:"button",class:{"LotteryTippingTicketBet__lineOperatorGroup--item":!0},onClick:()=>this.handleAddLine()},e("span",{class:"icon",innerHTML:this.addImage})),r&&e("button",{type:"button",class:{"LotteryTippingTicketBet__lineOperatorGroup--item":!0},onClick:()=>this.handleRemoveLine()},e("span",{class:"icon",innerHTML:this.deleteImage})))),this.renderPageFooter())}render(){let t;return t=this.betIsLoading?this.renderLoading():this.betHasErrors?this.renderErrorContent():0===this.ticketDataSource.length?this.renderEmptyContent():this.readPretty?this.renderReadPrettyContent():this.renderDefaultContent(),e("div",{key:"425f7f3d185616af3189857a9159868e3c57f100",ref:t=>this.stylingContainer=t,class:"LotteryTippingTicketBet__container"},t)}static get watchers(){return{translationUrl:["handleNewTranslations"],clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"],ticketDataSourceStr:["parseTicketDataSource"],bulletSelectionsLineGroupStr:["parseBulletSelectionsLineGroup"]}}};Gt.style=":host {\n --lottery-button-border-radius: 16px;\n}\n\n.LotteryTippingTicketBet__container {\n display: block; /* Or inline-block, depending on desired layout flow */\n font-size: 14px;\n padding: 12px;\n border: 1px solid var(--emw--color-gray-100, #e6e6e6);\n border-radius: var(--emw--button-border-radius, 4px);\n line-height: 1.5715;\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n overflow: hidden;\n min-width: 300px;\n container-type: inline-size;\n}\n@container (max-width: 375px) {\n .LotteryTippingTicketBet__container {\n font-size: 12px;\n }\n}\n\n.table-wrapper {\n overflow-x: auto; /* Handle horizontal scroll if content overflows */\n}\n\n.LotteryTippingTicketBet__main {\n overflow: hidden;\n}\n\n.table-scroll-wrapper {\n overflow-x: auto;\n flex-grow: 1;\n min-width: 0;\n}\n\n.my-table-component {\n width: 100%;\n border-collapse: collapse; /* Important for borders */\n text-align: left;\n border-radius: 0.1rem; /* Ant Design like subtle rounding */\n border-spacing: 0;\n}\n\n/* Header */\n.my-table-component th {\n background: var(--emw--color-background-secondary, #f5f5f5);\n color: var(--emw--color-typography, #000);\n font-weight: 500;\n padding: 0.4rem 0.5rem;\n transition: background 0.3s ease;\n}\n@container (max-width: 400px) {\n .my-table-component th {\n padding: 0.3rem 0.3rem;\n }\n}\n\n/* Cells */\n.my-table-component td {\n padding: 0.4rem 0.5rem;\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n transition: background 0.3s;\n}\n@container (max-width: 400px) {\n .my-table-component td {\n padding: 0.3rem 0.3rem;\n }\n}\n\n.my-table-component th:nth-child(1),\n.my-table-component td:nth-child(1) {\n /* index */\n min-width: 10px;\n}\n.my-table-component th:nth-child(3),\n.my-table-component td:nth-child(3) {\n /* startTime */\n min-width: 60px;\n}\n.my-table-component th:nth-child(4),\n.my-table-component td:nth-child(4) {\n /* results */\n min-width: 120px;\n}\n\n.my-table-component.bordered th,\n.my-table-component.bordered td {\n border-bottom: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n/* Bordered style */\n.my-table-component.grid th,\n.my-table-component.grid td {\n border: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n.my-table-component.grid th {\n border-bottom-width: 1px; /* Ensure bottom border is consistent */\n}\n\n.my-table-component.grid {\n border: 1px solid var(--emw--color-gray-100, #e6e6e6); /* Outer border */\n border-right-width: 0;\n border-bottom-width: 0;\n}\n\n.my-table-component.grid th:last-child,\n.my-table-component.grid td:last-child {\n border-right: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n.my-table-component.grid tr:last-child td {\n border-bottom: 1px solid var(--emw--color-gray-100, #e6e6e6);\n}\n\n/* Striped style */\n.my-table-component.striped tbody tr:nth-child(even) td {\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n/* Hover (optional, but nice) */\n.my-table-component tbody tr:hover td {\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n.flex {\n display: flex;\n}\n\n.justify-end {\n justify-content: flex-end;\n}\n\n.gap-1 {\n gap: 4px;\n}\n\n.justify-between {\n justify-content: space-between;\n}\n\n.align-center {\n align-items: center;\n}\n\n.gap-1 {\n gap: 0.5rem;\n}\n\n.btn {\n color: var(--emw--color-typography, #000);\n background: var(--emw--color-background, #fff);\n font-size: 14px;\n transition: all 0.2s ease;\n}\n.btn:hover {\n cursor: pointer;\n}\n\n.btn:hover {\n background-color: var(--emw--color-gray-100, #e6e6e6);\n}\n\n.btn.disabled {\n opacity: 0.5;\n pointer-events: none;\n}\n.btn.disabled:hover {\n cursor: not-allowed !important;\n}\n\n.LotteryTippingTicketBet__tableToolbar {\n width: 100%;\n margin-bottom: 1rem;\n}\n\n.LotteryTippingTicketBet__tableToolbar--item {\n margin-right: 2rem;\n}\n.LotteryTippingTicketBet__tableToolbar--item.mr-0 {\n margin-right: 0rem !important;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup {\n flex-basis: 2rem;\n display: flex;\n flex-direction: column;\n gap: 1rem;\n border-radius: 8px;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 2rem;\n height: 2rem;\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n color: var(--emw--color-typography, #000);\n border-radius: 8px;\n border: none;\n transition: all 0.2s ease-in-out;\n cursor: pointer;\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item:hover {\n transform: scale(1.1);\n box-shadow: 0 6px 14px var(--emw-calender-curday-box-shadow, rgba(0, 0, 0, 0.09));\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item .icon {\n width: 20px;\n height: 20px;\n transition: filter 0.2s ease-in-out;\n filter: grayscale(0.3);\n}\n\n.LotteryTippingTicketBet__lineOperatorGroup--item:hover .icon {\n filter: grayscale(0);\n transform: rotate(3deg);\n}\n\ndiv.border-line {\n margin-top: 1rem;\n height: 1px;\n width: 100%;\n box-sizing: border-box;\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n transition: all 0.3s ease;\n}\n\n.LotteryTippingTicketBet__footer {\n padding: 0.5rem;\n}\n\n.my-pagination {\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 1rem;\n font-size: 0.8rem;\n color: var(--emw--color-typography-secondary, #333);\n}\n\n.my-pagination span {\n font-weight: 500;\n user-select: none;\n}\n\n.my-pagination .btn {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 2rem;\n height: 2rem;\n border-radius: 50%;\n border: none;\n transition: all 0.3s ease;\n cursor: pointer;\n opacity: 0.9;\n color: var(--emw--color-typography, #000);\n background-color: var(--emw--color-background-secondary, #f5f5f5);\n}\n\n.my-pagination .btn .icon {\n width: 20px;\n height: 20px;\n transition: transform 0.2s ease;\n}\n\n.my-pagination .btn:hover {\n transform: scale(1.1);\n box-shadow: 0 6px 14px var(--emw-calender-curday-box-shadow, rgba(0, 0, 0, 0.09));\n}\n\n.my-pagination .btn.disabled {\n background-color: var(--emw--color-background-tertiary, #ccc);\n cursor: not-allowed;\n opacity: 0.5;\n transform: scale(1);\n}\n\n.match-info-item {\n display: flex;\n}\n\n.match-info-item-label {\n margin-right: 6px;\n}\n\n.info-icon:hover {\n cursor: pointer;\n}\n\n.LotteryTippingTicketBet__empty p {\n text-align: center;\n}\n\n.no-wrap {\n white-space: nowrap;\n overflow: hidden;\n}\n\n.eventNameContainer__item--title {\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n max-width: 300px;\n}\n@container (max-width: 600px) {\n .eventNameContainer__item--title {\n max-width: 180px;\n }\n}\n@container (max-width: 500px) {\n .eventNameContainer__item--title {\n max-width: 150px;\n }\n}\n@container (max-width: 400px) {\n .eventNameContainer__item--title {\n max-width: 100px;\n }\n}\n@container (max-width: 330px) {\n .eventNameContainer__item--title {\n max-width: 70px;\n }\n}\n\n.LotteryTippingTicketBet__main {\n perspective: 800px;\n will-change: transform, opacity;\n}\n\n@container (max-width: 520px) {\n .LotteryTippingTicketBet__main {\n flex-wrap: wrap;\n justify-content: center;\n }\n .LotteryTippingTicketBet__tableToolbar--item {\n margin-right: 0 !important;\n }\n}\n/* Fade-In Keyframes */\n@keyframes fadeInLeft {\n from {\n opacity: 0;\n transform: translateX(100%);\n }\n to {\n opacity: 1;\n transform: translateX(0);\n }\n}\n/* Fade-Out Keyframes */\n@keyframes fadeOut {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n}\n@keyframes fadeInRight {\n from {\n opacity: 0;\n transform: translateX(-100%);\n }\n to {\n opacity: 1;\n transform: translateX(0);\n }\n}\n@keyframes fadeInUp {\n from {\n opacity: 0;\n transform: translateY(100%);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n}\n@-webkit-keyframes slide-left {\n 0% {\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n 100% {\n -webkit-transform: translateX(-100px);\n transform: translateX(-100px);\n }\n}\n@keyframes slide-left {\n 0% {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n }\n 100% {\n -webkit-transform: translateX(0px);\n transform: translateX(0px);\n }\n}\n@-webkit-keyframes slide-right {\n 0% {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n }\n 100% {\n -webkit-transform: translateX(0px);\n transform: translateX(0px);\n }\n}\n@keyframes slide-right {\n 0% {\n -webkit-transform: translateX(-100px);\n transform: translateX(-100px);\n }\n 100% {\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n}\n@-webkit-keyframes slide-top {\n 0% {\n -webkit-transform: translateY(-100px);\n transform: translateY(-100px);\n }\n 100% {\n -webkit-transform: translateY(0px);\n transform: translateY(0px);\n }\n}\n@keyframes slide-top {\n 0% {\n -webkit-transform: translateY(-100px);\n transform: translateY(-100px);\n }\n 100% {\n -webkit-transform: translateY(0px);\n transform: translateY(0px);\n }\n}\n/* Apply to your card classes */\n.card-in-left {\n -webkit-animation: slide-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-left {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.card-in-right {\n -webkit-animation: slide-right 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-right 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-right {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.card-in-up {\n -webkit-animation: slide-top 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n animation: slide-top 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;\n}\n\n.card-out-down {\n animation: fadeOut 0.2s ease-out both;\n}\n\n.loading-wrap {\n margin: 20px 0;\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 40vh;\n}\n.loading-wrap .dots-container {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n.loading-wrap .dot {\n height: 14px;\n width: 14px;\n margin-right: 14px;\n border-radius: 14px;\n background-color: var(--emw--color-gray-300, #333);\n animation: pulse 1.5s infinite ease-in-out;\n}\n.loading-wrap .dot:last-child {\n margin-right: 0;\n}\n.loading-wrap .dot:nth-child(1) {\n animation-delay: -0.3s;\n}\n.loading-wrap .dot:nth-child(2) {\n animation-delay: -0.1s;\n}\n.loading-wrap .dot:nth-child(3) {\n animation-delay: 0.1s;\n}\n@keyframes pulse {\n 0% {\n transform: scale(0.8);\n background-color: var(--emw--color-gray-300, #333);\n }\n 50% {\n transform: scale(1.2);\n background-color: var(--emw--color-gray-100, #e6e6e6);\n }\n 100% {\n transform: scale(0.8);\n background-color: var(--emw--color-gray-150, #6f6f6f);\n }\n}\n\n.lottery-selection-group-table-header .lottery-selection__button {\n border: none;\n background: none;\n}";const Nt=["ro","en","fr","ar","hr"],Ut={en:{cancel:"Cancel",confirm:"Confirm"},ro:{cancel:"Anulează",confirm:"Confirmă"},fr:{cancel:"Annuler",confirm:"Confirmer"},ar:{cancel:"إلغاء",confirm:"تأكيد"},hr:{cancel:"Odustani",confirm:"Potvrdi"}},$t=(t,e)=>{const n=e;return Ut[void 0!==n&&Nt.includes(n)?n:"en"][t]},It=class{constructor(e){t(this,e),this.open=r(this,"open",7),this.close=r(this,"close",7),this.confirm=r(this,"confirm",7),this.cancel=r(this,"cancel",7),this.wasVisible=!1,this.mbSource=void 0,this.clientStyling="",this.clientStylingUrl="",this.visible=void 0,this.dialogTitle="",this.width="520px",this.closable=!0,this.mask=!0,this.maskClosable=!0,this.animationDuration=300,this.fullscreen=!1,this.showFooter=!0,this.showCancelBtn=!0,this.language="en",this.translationUrl=void 0,this.dialogClass=void 0,this.dialogStyle=void 0,this.confirmLoading=!1}handleClientStylingChange(t,e){t!=e&&c(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&h(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&u(this.stylingContainer,`${this.mbSource}.Style`,this.stylingSubscription)}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const n=await fetch(t);if(!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const r=await n.json();e=r,Object.keys(e).forEach((t=>{for(let n in e[t])Ut[t][n]=e[t][n]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}componentWillUpdate(){this.visible&&!this.wasVisible?this.disableBodyScroll():!this.visible&&this.wasVisible&&this.enableBodyScroll(),this.wasVisible=this.visible}disconnectedCallback(){this.enableBodyScroll(),this.stylingSubscription&&this.stylingSubscription.unsubscribe()}disableBodyScroll(){document.body.style.overflow="hidden"}enableBodyScroll(){document.body.style.overflow=""}handleClose(){this.cancel.emit()}handleMaskClick(){this.maskClosable&&this.cancel.emit()}handleConfirm(){this.confirm.emit()}render(){const t=Object.assign({width:"number"==typeof this.width?`${this.width}px`:this.width,"--duration":`${this.animationDuration}ms`},this.dialogStyle||{}),n=["dialog-wrapper",this.visible?"dialog-wrapper-visible":""],r=["mask",this.visible?"mask-enter":"mask-leave"],i=["dialog",this.visible?"dialog-enter":"dialog-leave",this.fullscreen?"fullscreen":"",this.dialogClass].filter(Boolean).join(" ");return e("div",{key:"05dd671f10bdebda6f138e8f8039f4bc0533fe98",class:n.join(" "),ref:t=>this.stylingContainer=t},e("div",{key:"6e814e02770149de5495617039750461fc0a42d1",class:r.join(" "),onClick:this.handleMaskClick.bind(this)}),e("div",{key:"4cbc5db20317ef1b0808fc4a91a53fa8b86c5f4f",part:"dialog",class:i,style:t,role:"dialog","aria-modal":"true","aria-labelledby":"dialog-title"},(this.dialogTitle||this.closable)&&e("div",{key:"85dc705676a37e6ea2828a7b683fc54b0eb77d17",class:"dialog-header"},e("h2",{key:"85b7472d2b72801dfae19a24fc2018f3c1f1529a",id:"dialog-title",class:"dialog-title"},this.dialogTitle),this.closable&&e("button",{key:"8089aaecfe511558055ee9f64214ff97030eb2a9",class:"close-btn",onClick:this.handleClose.bind(this)},"x")),e("div",{key:"776255540f30d757caa3fcaee747c79ac638ae76",class:"dialog-content",style:{maxHeight:"calc(100vh - 62px)",overflowY:"auto"}},e("slot",{key:"5ef964615b6ab70a9e561f8efac8fe952fe47b4e"})),this.showFooter&&e("div",{key:"8927a0991d916caf7852d58db996b9818687da30",class:"dialog-footer"},e("slot",{key:"84de0306994ec62220ae30fa2881dadbae5544ea",name:"footer"},this.showCancelBtn&&e("button",{key:"ee87b8c3918c1f4d007923a2498142b3af2740a0",class:"cancel-btn",onClick:this.handleClose.bind(this)},$t("cancel",this.language)),e("button",{key:"935cff86381b21fff07c2d4156b29779c50e5ce3",class:"confirm-btn",onClick:this.handleConfirm.bind(this),disabled:this.confirmLoading},this.confirmLoading?e("div",{class:"Loading",innerHTML:_t(yt,{extraSVGAttrs:{width:"20px",height:"20px",fill:"currentColor"}})}):$t("confirm",this.language))))))}get el(){return n(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};It.style=".dialog-wrapper{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;visibility:hidden;opacity:1;z-index:199}.dialog-wrapper-visible{visibility:visible}.mask{position:fixed;inset:0;background:var(--emw--color-mask-dialog-background, rgba(0, 0, 0, 0.5));opacity:0;z-index:1000;transition:opacity var(--duration) linear}.mask-enter{opacity:1}.mask-leave{opacity:0}.dialog{position:relative;background:var(--emw--color-background, #fff);border-radius:12px;box-shadow:0 4px 32px var(--emw--button-box-shadow-color-secondary, rgba(0, 0, 0, 0.15));opacity:0;transform:scale(0.9);transition:all var(--duration) linear;width:100%;max-width:100vw;overflow:hidden;z-index:1000}.dialog-enter{opacity:1;transform:scale(1)}.dialog-leave{opacity:0}.dialog.fullscreen{width:100vw !important;height:100vh;overflow:auto;max-height:none;border-radius:0;overflow:hidden}.dialog-header{padding:16px 16px 0 16px;display:flex;justify-content:space-between;align-items:center}.dialog-header .dialog-title{margin:0;font-size:1.25rem;font-weight:500;color:var(--emw--color-typography, #000)}.dialog-header .close-btn{background:transparent;border:none;font-size:1.5rem;width:2rem;height:2rem;color:var(--emw--color-gray-150, #6f6f6f);cursor:pointer;border-radius:4px}.dialog-header .close-btn:hover{background:var(--emw--color-gray-50, #f5f5f5);color:var(--emw--color-gray-300, #333)}.dialog-content{padding:24px;font-size:0.95rem;line-height:1.6;color:var(--emw--color-dialog-typography, #000);flex:1;overflow-y:auto;max-height:calc(100vh - 200px)}.dialog.fullscreen .dialog-content{max-height:none}.dialog-footer{padding:0 16px 16px 16px;display:flex;justify-content:center;gap:12px}.dialog-footer .cancel-btn,.dialog-footer .confirm-btn{padding:10px 24px;min-width:60px;border-radius:6px;font-size:0.9rem;cursor:pointer;transition:all 0.3s linear}.dialog-footer .cancel-btn{border:var(--emw--button-border, 1px solid rgba(221, 221, 221, 0.8666666667));background-color:var(--emw--color-background, #fff);color:var(--emw--color-typography, #000)}.dialog-footer .cancel-btn:hover{background-color:var(--emw--color-background-tertiary, #ccc)}.dialog-footer .confirm-btn{border:none;color:var(--emw--color-typography-normalized, #ffffff);background:var(--emw--color-primary, #009993)}.dialog-footer .confirm-btn:hover{background:var(--emw--color-primary-variant, #004d4a)}@media screen and (max-width: 480px){.dialog.fullscreen .dialog-content{padding:12px}}.Loading{display:flex;align-items:center;justify-content:center;width:100%;height:100%}.Loading svg{animation:spin 1s linear infinite;transform-origin:center}@keyframes spin{100%{transform:rotate(360deg)}}";export{rt as app_tooltip,it as helper_count_down,lt as lottery_banner,ht as lottery_button,mt as lottery_order_summary,Ct as lottery_selection,jt as lottery_selection_group,Gt as lottery_tipping_bet_slip,It as lottery_tipping_dialog}
@@ -1 +1 @@
1
- export{L as LotteryTippingTicketBuy}from"./lottery-tipping-ticket-buy-04819204.js";import"./index-c24f96b9.js";
1
+ export{L as LotteryTippingTicketBuy}from"./lottery-tipping-ticket-buy-d6e60365.js";import"./index-c24f96b9.js";
@@ -1,4 +1,4 @@
1
- import{r as t,c as e,h as i,g as s}from"./index-c24f96b9.js";const o="__WIDGET_GLOBAL_STYLE_CACHE__";function r(t,e){if(t){const i=document.createElement("style");i.innerHTML=e,t.appendChild(i)}}function n(t,e){if(!t||!e)return;const i=new URL(e);fetch(i.href).then((t=>t.text())).then((e=>{const i=document.createElement("style");i.innerHTML=e,t&&t.appendChild(i)})).catch((t=>{console.error("There was an error while trying to load client styling from URL",t)}))}function a(t,e,i,s=!1){if(!window.emMessageBus)return;if(!("adoptedStyleSheets"in Document.prototype)||!s)return i=function(t,e){const i=document.createElement("style");return window.emMessageBus.subscribe(e,(e=>{t&&(i.innerHTML=e,t.appendChild(i))}))}(t,e),i;window[o]||(window[o]={}),i=function(t,e){return window.emMessageBus.subscribe(e,(i=>{if(!t)return;const s=t.getRootNode(),r=window[o];let n=r[e]&&r[e].sheet;n?r[e].refCount=r[e].refCount+1:(n=new CSSStyleSheet,n.replaceSync(i),r[e]={sheet:n,refCount:1});const a=s.adoptedStyleSheets||[];a.includes(n)||(s.adoptedStyleSheets=[...a,n])}))}(t,e);const r=i.unsubscribe.bind(i);return i.unsubscribe=()=>{if(window[o][e]){const t=window[o][e];t.refCount>1?t.refCount=t.refCount-1:delete window[o][e]}r()},i}function l(t,e){return null==t||""===t||(0!==t||!e)&&(Array.isArray(t)?function(t){if(0===t.length)return!0;const e=t.length;let i=0;for(let s=0;s<e;s++){if(!l(t[s]))return!1;i++}return i===e}(t):"[object Object]"===Object.prototype.toString.call(t)?function(t){if(0===Object.keys(t).length)return!0;const e=Object.keys(t).length;let i=0;for(const e of Object.values(t)){if(!l(e))return!1;i++}return i===e}(t):!t)}function h(t,e="€"){return null==t?"":`${e}${t?function(t){if(0===t)return"0";if(!t)return"";const e=(t=t.toString()).split(".");return e[0]=e[0].replace(/\B(?=(\d{3})+(?!\d))/g,","),e.join(".")}(t):0}`}function c(t=[[]],e){let i=1;for(let s=0;s<e;s++)if(i*=(t[s]||[]).filter((t=>t)).length,0===i)return 0;return i}function d(t,e="GET",i=null,s={}){return new Promise(((o,r)=>{const n="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)})),a=Object.assign({"Content-Type":"application/json","X-APP-KEY":"123456"},s);"GET"!==e&&"HEAD"!==e&&(a["X-Idempotency-Key"]=n);const l={method:e,headers:a,body:null};i&&"GET"!==e&&"HEAD"!==e?l.body=JSON.stringify(i):delete l.body,fetch(t,l).then((t=>t.ok?t.json():t.json().then((e=>{r({status:t.status,statusText:t.statusText,code:e.code||"UNKNOWN_ERROR",message:e.message||"An unknown error occurred",data:e.data||null})}),(()=>r({status:t.status,statusText:t.statusText,code:"PARSE_ERROR",message:"Failed to parse error response"}))))).then((t=>o(t)),(t=>r(t)))}))}const u=["ro","en","fr","ar","hr"],p={en:{stop:"Stop",at:"at",turnover:"Turnover: ",selectionCleared:"Your selection will be cleared.",selectionOnLineCleared:"Your selection on this line will be cleared.",ticketSubmitted:"Ticket submitted successfully.",ticketFailed:"Failed to purchase the ticket. Please try again.",lines:"Lines",line:"Line",bettingType:"Betting Type",playingMode:"Playing Mode",orderSummaryTitle:"Order Summary",orderSummaryTickets:"Tickets",orderSummaryTotal:"Total",orderSummarySubmit:"Submit",cancel:"Cancel",confirm:"Confirm",stakePerLine:"Stake per Line:",error:"Error!",gameNotAvailable:"Sorry. The Game is not available now."},ro:{selectionCleared:"Selecția dvs. va fi ștearsă.",ticketSubmitted:"Bilet trimis cu succes.",ticketFailed:"Nu s-a putut achiziționa biletul. Vă rugăm să încercați din nou.",lines:"Linii",line:"Linie",bettingType:"Tip de pariu",playingMode:"Mod de joc",orderSummaryTitle:"Sumar comandă",orderSummaryTickets:"Bilete",orderSummaryTotal:"Total",orderSummarySubmit:"Trimite",cancel:"Anulează",confirm:"Confirmă"},fr:{selectionCleared:"Votre sélection sera effacée.",ticketSubmitted:"Billet soumis avec succès.",ticketFailed:"Échec de l'achat du billet. Veuillez réessayer.",lines:"Lignes",line:"Ligne",bettingType:"Type de pari",playingMode:"Mode de jeu",orderSummaryTitle:"Résumé de la commande",orderSummaryTickets:"Billets",orderSummaryTotal:"Total",orderSummarySubmit:"Soumettre",cancel:"Annuler",confirm:"Confirmer"},ar:{selectionCleared:"سيتم مسح اختيارك.",ticketSubmitted:"تم إرسال التذكرة بنجاح.",ticketFailed:"فشل شراء التذكرة. يرجى المحاولة مرة أخرى.",lines:"خطوط",line:"خط",bettingType:"نوع الرهان",playingMode:"وضع اللعب",orderSummaryTitle:"ملخص الطلب",orderSummaryTickets:"التذاكر",orderSummaryTotal:"المجموع",orderSummarySubmit:"إرسال",cancel:"إلغاء",confirm:"تأكيد"},hr:{selectionCleared:"Vaš odabir bit će obrisan.",ticketSubmitted:"Listić je uspješno predan.",ticketFailed:"Kupnja listića nije uspjela. Molimo pokušajte ponovo.",lines:"Linije",line:"Linija",bettingType:"Vrsta oklade",playingMode:"Način igranja",orderSummaryTitle:"Sažetak narudžbe",orderSummaryTickets:"Listići",orderSummaryTotal:"Ukupno",orderSummarySubmit:"Pošalji",cancel:"Odustani",confirm:"Potvrdi"}},m=(t,e,i)=>{const s=e;let o=p[void 0!==s&&u.includes(s)?s:"en"][t];return i&&Object.keys(i).forEach((t=>{o=o.replace(`{${t}}`,i[t])})),o};function v(t){return v="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},v(t)}function f(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 b(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function g(t){b(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===v(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))}var y=36e5;function _(t,e){b(2,arguments);var i=g(t),s=g(e);return i.getTime()<s.getTime()}function w(t,e){var i;b(1,arguments);var s=f(null!==(i=null==e?void 0:e.additionalDigits)&&void 0!==i?i:2);if(2!==s&&1!==s&&0!==s)throw new RangeError("additionalDigits must be 0, 1 or 2");if("string"!=typeof t&&"[object String]"!==Object.prototype.toString.call(t))return new Date(NaN);var o,r=function(t){var e,i={},s=t.split(x.dateTimeDelimiter);if(s.length>2)return i;if(/:/.test(s[0])?e=s[0]:(i.date=s[0],e=s[1],x.timeZoneDelimiter.test(i.date)&&(i.date=t.split(x.timeZoneDelimiter)[0],e=t.substr(i.date.length,t.length))),e){var o=x.timezone.exec(e);o?(i.time=e.replace(o[1],""),i.timezone=o[1]):i.time=e}return i}(t);if(r.date){var n=function(t,e){var i=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),s=t.match(i);if(!s)return{year:NaN,restDateString:""};var o=s[1]?parseInt(s[1]):null,r=s[2]?parseInt(s[2]):null;return{year:null===r?o:100*r,restDateString:t.slice((s[1]||s[2]).length)}}(r.date,s);o=function(t,e){if(null===e)return new Date(NaN);var i=t.match(k);if(!i)return new Date(NaN);var s=!!i[4],o=A(i[1]),r=A(i[2])-1,n=A(i[3]),a=A(i[4]),l=A(i[5])-1;if(s)return function(t,e,i){return e>=1&&e<=53&&i>=0&&i<=6}(0,a,l)?function(t,e,i){var s=new Date(0);s.setUTCFullYear(t,0,4);var o=7*(e-1)+i+1-(s.getUTCDay()||7);return s.setUTCDate(s.getUTCDate()+o),s}(e,a,l):new Date(NaN);var h=new Date(0);return function(t,e,i){return e>=0&&e<=11&&i>=1&&i<=(I[e]||(T(t)?29:28))}(e,r,n)&&function(t,e){return e>=1&&e<=(T(t)?366:365)}(e,o)?(h.setUTCFullYear(e,r,Math.max(o,n)),h):new Date(NaN)}(n.restDateString,n.year)}if(!o||isNaN(o.getTime()))return new Date(NaN);var a,l=o.getTime(),h=0;if(r.time&&(h=function(t){var e=t.match(C);if(!e)return NaN;var i=z(e[1]),s=z(e[2]),o=z(e[3]);return function(t,e,i){return 24===t?0===e&&0===i:i>=0&&i<60&&e>=0&&e<60&&t>=0&&t<25}(i,s,o)?i*y+6e4*s+1e3*o:NaN}(r.time),isNaN(h)))return new Date(NaN);if(!r.timezone){var c=new Date(l+h),d=new Date(0);return d.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),d.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),d}return a=function(t){if("Z"===t)return 0;var e=t.match(S);if(!e)return 0;var i="+"===e[1]?-1:1,s=parseInt(e[2]),o=e[3]&&parseInt(e[3])||0;return function(t,e){return e>=0&&e<=59}(0,o)?i*(s*y+6e4*o):NaN}(r.timezone),isNaN(a)?new Date(NaN):new Date(l+h+a)}var x={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},k=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,C=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,S=/^([+-])(\d{2})(?::?(\d{2}))?$/;function A(t){return t?parseInt(t):1}function z(t){return t&&parseFloat(t.replace(",","."))||0}var I=[31,null,31,30,31,30,31,31,30,31,30,31];function T(t){return t%400==0||t%4==0&&t%100!=0}const D=class{constructor(i){t(this,i),this.valueChange=e(this,"valueChange",7),this.optionRefs=[],this.label=void 0,this.options=[],this.value=void 0}handleValueChange(){this.updateActiveIndicator()}componentWillLoad(){!this.value&&this.options.length>0&&(this.value=this.options[0].value)}componentDidLoad(){requestAnimationFrame((()=>this.updateActiveIndicator()))}handleWindowResize(){this.updateActiveIndicator()}updateActiveIndicator(){const t=this.options.findIndex((t=>t.value===this.value));if(-1===t||!this.activeIndicator||!this.optionRefs[t])return;const e=this.optionRefs[t],i=this.activeIndicator.parentElement.getBoundingClientRect(),s=e.getBoundingClientRect();this.activeIndicator.style.transform=`translateX(${s.left-i.left}px)`,this.activeIndicator.style.width=`${s.width}px`}onOptionClick(t){this.value!==t&&this.valueChange.emit(t)}render(){return i("div",{key:"675f17d5fd8ddef56324416fda27ffd130ddafa3",class:"wrapper"},this.label&&i("label",{key:"d6dfc897e2014a7ce57cc4ddca57b1e6173eb1a5",class:"label"},this.label),i("div",{key:"e89097f2a9536ada1e0edf52e0d50cdd8f88c52e",class:"segmented-container"},i("div",{key:"f720dc7b9b8957cb6d363fd6a2313978eba6988e",class:"active-indicator",ref:t=>this.activeIndicator=t}),this.options.map(((t,e)=>i("button",{class:{option:!0,active:this.value===t.value},onClick:()=>this.onOptionClick(t.value),ref:t=>this.optionRefs[e]=t},t.label)))))}get host(){return s(this)}static get watchers(){return{value:["handleValueChange"]}}};D.style=":host{display:block}.wrapper{display:flex;align-items:center;gap:8px}.label{font-size:16px;color:var(--emw-segmented-label-color, #333);font-weight:500}.segmented-container{display:inline-flex;position:relative;background-color:var(--emw-segmented-bg, #f0f0f0);border-radius:20px;box-shadow:inset 0 1px 3px rgba(0, 0, 0, 0.1)}.option{position:relative;z-index:1;border:none;background-color:transparent;padding:12px 18px;cursor:pointer;font-size:14px;font-weight:500;color:var(--emw-segmented-text-color, #555);transition:color 0.3s ease;white-space:nowrap}.option.active{color:var(--emw-segmented-active-text-color, #000);font-weight:bold}.active-indicator{position:absolute;z-index:0;top:2px;bottom:2px;background-color:var(--emw-segmented-active-bg, #fff);border-radius:22px;box-shadow:0 2px 4px rgba(0, 0, 0, 0.15);transition:transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1)}";var O=Object.defineProperty,E=Object.defineProperties,P=Object.getOwnPropertyDescriptors,N=Object.getOwnPropertySymbols,M=Object.prototype.hasOwnProperty,B=Object.prototype.propertyIsEnumerable,j=(t,e,i)=>e in t?O(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,F=(t,e)=>{for(var i in e||(e={}))M.call(e,i)&&j(t,i,e[i]);if(N)for(var i of N(e))B.call(e,i)&&j(t,i,e[i]);return t},$=(t,e)=>E(t,P(e)),L=(t,e,i)=>(j(t,"symbol"!=typeof e?e+"":e,i),i),R=(t,e,i)=>new Promise(((s,o)=>{var r=t=>{try{a(i.next(t))}catch(t){o(t)}},n=t=>{try{a(i.throw(t))}catch(t){o(t)}},a=t=>t.done?s(t.value):Promise.resolve(t.value).then(r,n);a((i=i.apply(t,e)).next())}))
1
+ import{r as t,c as e,h as i,g as s}from"./index-c24f96b9.js";const o="__WIDGET_GLOBAL_STYLE_CACHE__";function r(t,e){if(t){const i=document.createElement("style");i.innerHTML=e,t.appendChild(i)}}function n(t,e){if(!t||!e)return;const i=new URL(e);fetch(i.href).then((t=>t.text())).then((e=>{const i=document.createElement("style");i.innerHTML=e,t&&t.appendChild(i)})).catch((t=>{console.error("There was an error while trying to load client styling from URL",t)}))}function a(t,e,i,s=!1){if(!window.emMessageBus)return;if(!("adoptedStyleSheets"in Document.prototype)||!s)return i=function(t,e){const i=document.createElement("style");return window.emMessageBus.subscribe(e,(e=>{t&&(i.innerHTML=e,t.appendChild(i))}))}(t,e),i;window[o]||(window[o]={}),i=function(t,e){return window.emMessageBus.subscribe(e,(i=>{if(!t)return;const s=t.getRootNode(),r=window[o];let n=r[e]&&r[e].sheet;n?r[e].refCount=r[e].refCount+1:(n=new CSSStyleSheet,n.replaceSync(i),r[e]={sheet:n,refCount:1});const a=s.adoptedStyleSheets||[];a.includes(n)||(s.adoptedStyleSheets=[...a,n])}))}(t,e);const r=i.unsubscribe.bind(i);return i.unsubscribe=()=>{if(window[o][e]){const t=window[o][e];t.refCount>1?t.refCount=t.refCount-1:delete window[o][e]}r()},i}function l(t,e){return null==t||""===t||(0!==t||!e)&&(Array.isArray(t)?function(t){if(0===t.length)return!0;const e=t.length;let i=0;for(let s=0;s<e;s++){if(!l(t[s]))return!1;i++}return i===e}(t):"[object Object]"===Object.prototype.toString.call(t)?function(t){if(0===Object.keys(t).length)return!0;const e=Object.keys(t).length;let i=0;for(const e of Object.values(t)){if(!l(e))return!1;i++}return i===e}(t):!t)}function h(t,e="€"){return null==t?"":`${e}${t?function(t){if(0===t)return"0";if(!t)return"";const e=(t=t.toString()).split(".");return e[0]=e[0].replace(/\B(?=(\d{3})+(?!\d))/g,","),e.join(".")}(t):0}`}function c(t=[[]],e){let i=1;for(let s=0;s<e;s++)if(i*=(t[s]||[]).filter((t=>t)).length,0===i)return 0;return i}function d(t,e="GET",i=null,s={}){return new Promise(((o,r)=>{const n="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"==t?e:3&e|8).toString(16)})),a=Object.assign({"Content-Type":"application/json","X-APP-KEY":"123456"},s);"GET"!==e&&"HEAD"!==e&&(a["X-Idempotency-Key"]=n);const l={method:e,headers:a,body:null};i&&"GET"!==e&&"HEAD"!==e?l.body=JSON.stringify(i):delete l.body,fetch(t,l).then((t=>t.ok?t.json():t.json().then((e=>{r({status:t.status,statusText:t.statusText,code:e.code||"UNKNOWN_ERROR",message:e.message||"An unknown error occurred",data:e.data||null})}),(()=>r({status:t.status,statusText:t.statusText,code:"PARSE_ERROR",message:"Failed to parse error response"}))))).then((t=>o(t)),(t=>r(t)))}))}const u=["ro","en","fr","ar","hr"],p={en:{stop:"Stop",at:"at",turnover:"Turnover: ",selectionCleared:"Your selection will be cleared.",selectionOnLineCleared:"Your selection on this line will be cleared.",ticketSubmitted:"Ticket submitted successfully.",ticketFailed:"Failed to purchase the ticket. Please try again.",lines:"Lines",line:"Line",bettingType:"Betting Type",playingMode:"Playing Mode",orderSummaryTitle:"Order Summary",orderSummaryTickets:"Tickets",orderSummaryTotal:"Total",orderSummarySubmit:"Submit",cancel:"Cancel",confirm:"Confirm",stakePerLine:"Stake per Line:",error:"Error!",gameNotAvailable:"Sorry. The Game is not available now."},ro:{selectionCleared:"Selecția dvs. va fi ștearsă.",ticketSubmitted:"Bilet trimis cu succes.",ticketFailed:"Nu s-a putut achiziționa biletul. Vă rugăm să încercați din nou.",lines:"Linii",line:"Linie",bettingType:"Tip de pariu",playingMode:"Mod de joc",orderSummaryTitle:"Sumar comandă",orderSummaryTickets:"Bilete",orderSummaryTotal:"Total",orderSummarySubmit:"Trimite",cancel:"Anulează",confirm:"Confirmă"},fr:{selectionCleared:"Votre sélection sera effacée.",ticketSubmitted:"Billet soumis avec succès.",ticketFailed:"Échec de l'achat du billet. Veuillez réessayer.",lines:"Lignes",line:"Ligne",bettingType:"Type de pari",playingMode:"Mode de jeu",orderSummaryTitle:"Résumé de la commande",orderSummaryTickets:"Billets",orderSummaryTotal:"Total",orderSummarySubmit:"Soumettre",cancel:"Annuler",confirm:"Confirmer"},ar:{selectionCleared:"سيتم مسح اختيارك.",ticketSubmitted:"تم إرسال التذكرة بنجاح.",ticketFailed:"فشل شراء التذكرة. يرجى المحاولة مرة أخرى.",lines:"خطوط",line:"خط",bettingType:"نوع الرهان",playingMode:"وضع اللعب",orderSummaryTitle:"ملخص الطلب",orderSummaryTickets:"التذاكر",orderSummaryTotal:"المجموع",orderSummarySubmit:"إرسال",cancel:"إلغاء",confirm:"تأكيد"},hr:{selectionCleared:"Vaš odabir bit će obrisan.",ticketSubmitted:"Listić je uspješno predan.",ticketFailed:"Kupnja listića nije uspjela. Molimo pokušajte ponovo.",lines:"Linije",line:"Linija",bettingType:"Vrsta oklade",playingMode:"Način igranja",orderSummaryTitle:"Sažetak narudžbe",orderSummaryTickets:"Listići",orderSummaryTotal:"Ukupno",orderSummarySubmit:"Pošalji",cancel:"Odustani",confirm:"Potvrdi"}},m=(t,e,i)=>{const s=e;let o=p[void 0!==s&&u.includes(s)?s:"en"][t];return i&&Object.keys(i).forEach((t=>{o=o.replace(`{${t}}`,i[t])})),o};function v(t){return v="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},v(t)}function f(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 b(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function g(t){b(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===v(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))}var y=36e5;function _(t,e){b(2,arguments);var i=g(t),s=g(e);return i.getTime()<s.getTime()}function w(t,e){var i;b(1,arguments);var s=f(null!==(i=null==e?void 0:e.additionalDigits)&&void 0!==i?i:2);if(2!==s&&1!==s&&0!==s)throw new RangeError("additionalDigits must be 0, 1 or 2");if("string"!=typeof t&&"[object String]"!==Object.prototype.toString.call(t))return new Date(NaN);var o,r=function(t){var e,i={},s=t.split(x.dateTimeDelimiter);if(s.length>2)return i;if(/:/.test(s[0])?e=s[0]:(i.date=s[0],e=s[1],x.timeZoneDelimiter.test(i.date)&&(i.date=t.split(x.timeZoneDelimiter)[0],e=t.substr(i.date.length,t.length))),e){var o=x.timezone.exec(e);o?(i.time=e.replace(o[1],""),i.timezone=o[1]):i.time=e}return i}(t);if(r.date){var n=function(t,e){var i=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),s=t.match(i);if(!s)return{year:NaN,restDateString:""};var o=s[1]?parseInt(s[1]):null,r=s[2]?parseInt(s[2]):null;return{year:null===r?o:100*r,restDateString:t.slice((s[1]||s[2]).length)}}(r.date,s);o=function(t,e){if(null===e)return new Date(NaN);var i=t.match(k);if(!i)return new Date(NaN);var s=!!i[4],o=A(i[1]),r=A(i[2])-1,n=A(i[3]),a=A(i[4]),l=A(i[5])-1;if(s)return function(t,e,i){return e>=1&&e<=53&&i>=0&&i<=6}(0,a,l)?function(t,e,i){var s=new Date(0);s.setUTCFullYear(t,0,4);var o=7*(e-1)+i+1-(s.getUTCDay()||7);return s.setUTCDate(s.getUTCDate()+o),s}(e,a,l):new Date(NaN);var h=new Date(0);return function(t,e,i){return e>=0&&e<=11&&i>=1&&i<=(I[e]||(T(t)?29:28))}(e,r,n)&&function(t,e){return e>=1&&e<=(T(t)?366:365)}(e,o)?(h.setUTCFullYear(e,r,Math.max(o,n)),h):new Date(NaN)}(n.restDateString,n.year)}if(!o||isNaN(o.getTime()))return new Date(NaN);var a,l=o.getTime(),h=0;if(r.time&&(h=function(t){var e=t.match(C);if(!e)return NaN;var i=z(e[1]),s=z(e[2]),o=z(e[3]);return function(t,e,i){return 24===t?0===e&&0===i:i>=0&&i<60&&e>=0&&e<60&&t>=0&&t<25}(i,s,o)?i*y+6e4*s+1e3*o:NaN}(r.time),isNaN(h)))return new Date(NaN);if(!r.timezone){var c=new Date(l+h),d=new Date(0);return d.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),d.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),d}return a=function(t){if("Z"===t)return 0;var e=t.match(S);if(!e)return 0;var i="+"===e[1]?-1:1,s=parseInt(e[2]),o=e[3]&&parseInt(e[3])||0;return function(t,e){return e>=0&&e<=59}(0,o)?i*(s*y+6e4*o):NaN}(r.timezone),isNaN(a)?new Date(NaN):new Date(l+h+a)}var x={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},k=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,C=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,S=/^([+-])(\d{2})(?::?(\d{2}))?$/;function A(t){return t?parseInt(t):1}function z(t){return t&&parseFloat(t.replace(",","."))||0}var I=[31,null,31,30,31,30,31,31,30,31,30,31];function T(t){return t%400==0||t%4==0&&t%100!=0}const D=class{constructor(i){t(this,i),this.valueChange=e(this,"valueChange",7),this.optionRefs=[],this.label=void 0,this.options=[],this.value=void 0}handleValueChange(){this.updateActiveIndicator()}componentWillLoad(){!this.value&&this.options.length>0&&(this.value=this.options[0].value)}componentDidLoad(){requestAnimationFrame((()=>this.updateActiveIndicator()))}handleWindowResize(){this.updateActiveIndicator()}updateActiveIndicator(){const t=this.options.findIndex((t=>t.value===this.value));if(-1===t||!this.activeIndicator||!this.optionRefs[t])return;const e=this.optionRefs[t],i=this.activeIndicator.parentElement.getBoundingClientRect(),s=e.getBoundingClientRect();this.activeIndicator.style.transform=`translateX(${s.left-i.left}px)`,this.activeIndicator.style.width=`${s.width}px`}onOptionClick(t){this.value!==t&&this.valueChange.emit(t)}render(){return i("div",{key:"675f17d5fd8ddef56324416fda27ffd130ddafa3",class:"wrapper"},this.label&&i("label",{key:"d6dfc897e2014a7ce57cc4ddca57b1e6173eb1a5",class:"label"},this.label),i("div",{key:"e89097f2a9536ada1e0edf52e0d50cdd8f88c52e",class:"segmented-container"},i("div",{key:"f720dc7b9b8957cb6d363fd6a2313978eba6988e",class:"active-indicator",ref:t=>this.activeIndicator=t}),this.options.map(((t,e)=>i("button",{class:{option:!0,active:this.value===t.value},onClick:()=>this.onOptionClick(t.value),ref:t=>this.optionRefs[e]=t},t.label)))))}get host(){return s(this)}static get watchers(){return{value:["handleValueChange"]}}};D.style=":host{display:block}.wrapper{display:flex;align-items:center;gap:8px}.label{font-size:16px;color:var(--emw-segmented-label-color, #333);font-weight:500}.segmented-container{display:inline-flex;position:relative;background-color:var(--emw-segmented-bg, #f0f0f0);border-radius:20px;box-shadow:inset 0 1px 3px rgba(0, 0, 0, 0.1)}.option{position:relative;z-index:1;border:none;background-color:transparent;padding:12px 18px;cursor:pointer;font-size:14px;font-weight:500;color:var(--emw-segmented-text-color, #555);transition:color 0.3s ease;white-space:nowrap}.option.active{color:var(--emw-segmented-active-text-color, #000);font-weight:bold}.active-indicator{position:absolute;z-index:0;top:2px;bottom:2px;background-color:var(--emw-segmented-active-bg, #fff);border-radius:22px;box-shadow:0 2px 4px rgba(0, 0, 0, 0.15);transition:transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1)}";var O=Object.defineProperty,E=Object.defineProperties,P=Object.getOwnPropertyDescriptors,N=Object.getOwnPropertySymbols,M=Object.prototype.hasOwnProperty,B=Object.prototype.propertyIsEnumerable,j=(t,e,i)=>e in t?O(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,F=(t,e)=>{for(var i in e||(e={}))M.call(e,i)&&j(t,i,e[i]);if(N)for(var i of N(e))B.call(e,i)&&j(t,i,e[i]);return t},$=(t,e)=>E(t,P(e)),L=(t,e,i)=>j(t,"symbol"!=typeof e?e+"":e,i),R=(t,e,i)=>new Promise(((s,o)=>{var r=t=>{try{a(i.next(t))}catch(t){o(t)}},n=t=>{try{a(i.throw(t))}catch(t){o(t)}},a=t=>t.done?s(t.value):Promise.resolve(t.value).then(r,n);a((i=i.apply(t,e)).next())}))
2
2
  /**
3
3
  * @license
4
4
  * Copyright (c) 2021 - 2024 Vaadin Ltd.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@everymatrix/lottery-tipping-ticket-buy",
3
- "version": "0.5.56",
3
+ "version": "0.5.59",
4
4
  "main": "./dist/index.cjs.js",
5
5
  "module": "./dist/index.js",
6
6
  "es2015": "./dist/esm/index.mjs",