@everymatrix/lottery-hakuna-ticket-history 0.0.23 → 0.0.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index-62b3d460.js +64 -0
- package/dist/cjs/index-dc95b9af.js +6 -2
- package/dist/cjs/index.cjs.js +2 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{lottery-button_8.cjs.entry.js → lottery-button_7.cjs.entry.js} +98 -268
- package/dist/cjs/{lottery-hakuna-ticket-history-ec8bf5d5.js → lottery-hakuna-ticket-history-49bed503.js} +51 -124
- package/dist/cjs/lottery-hakuna-ticket-history.cjs.js +1 -1
- package/dist/cjs/lottery-infinite-scroll.cjs.entry.js +223 -0
- package/dist/collection/components/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history.css +8 -0
- package/dist/collection/components/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history.js +51 -8
- package/dist/collection/components/lottery-infinite-scroll/lottery-infinite-scroll.js +4 -4
- package/dist/esm/index-30f31c84.js +60 -0
- package/dist/esm/index-50addd47.js +6 -2
- package/dist/esm/index.js +2 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{lottery-button_8.entry.js → lottery-button_7.entry.js} +71 -241
- package/dist/esm/{lottery-hakuna-ticket-history-35d86d50.js → lottery-hakuna-ticket-history-844d94d7.js} +46 -115
- package/dist/esm/lottery-hakuna-ticket-history.js +1 -1
- package/dist/esm/lottery-infinite-scroll.entry.js +219 -0
- package/dist/lottery-hakuna-ticket-history/index-30f31c84.js +1 -0
- package/dist/lottery-hakuna-ticket-history/index.esm.js +1 -1
- package/dist/lottery-hakuna-ticket-history/lottery-button_7.entry.js +1 -0
- package/dist/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history-844d94d7.js +1 -0
- package/dist/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history.esm.js +1 -1
- package/dist/lottery-hakuna-ticket-history/lottery-infinite-scroll.entry.js +1 -0
- package/dist/types/components/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history.d.ts +5 -0
- package/package.json +1 -1
- package/dist/lottery-hakuna-ticket-history/lottery-button_8.entry.js +0 -1
- package/dist/lottery-hakuna-ticket-history/lottery-hakuna-ticket-history-35d86d50.js +0 -1
|
@@ -1,63 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, h } from './index-50addd47.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @name setClientStyling
|
|
5
|
-
* @description Method used to create and append to the passed element of the widget a style element with the content received
|
|
6
|
-
* @param {HTMLElement} stylingContainer The reference element of the widget
|
|
7
|
-
* @param {string} clientStyling The style content
|
|
8
|
-
*/
|
|
9
|
-
function setClientStyling(stylingContainer, clientStyling) {
|
|
10
|
-
if (stylingContainer) {
|
|
11
|
-
const sheet = document.createElement('style');
|
|
12
|
-
sheet.innerHTML = clientStyling;
|
|
13
|
-
stylingContainer.appendChild(sheet);
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @name setClientStylingURL
|
|
19
|
-
* @description Method used to create and append to the passed element of the widget a style element with the content fetched from a given URL
|
|
20
|
-
* @param {HTMLElement} stylingContainer The reference element of the widget
|
|
21
|
-
* @param {string} clientStylingUrl The URL of the style content
|
|
22
|
-
*/
|
|
23
|
-
function setClientStylingURL(stylingContainer, clientStylingUrl) {
|
|
24
|
-
if (!stylingContainer || !clientStylingUrl) return;
|
|
25
|
-
|
|
26
|
-
const url = new URL(clientStylingUrl);
|
|
27
|
-
|
|
28
|
-
fetch(url.href)
|
|
29
|
-
.then((res) => res.text())
|
|
30
|
-
.then((data) => {
|
|
31
|
-
const cssFile = document.createElement('style');
|
|
32
|
-
cssFile.innerHTML = data;
|
|
33
|
-
if (stylingContainer) {
|
|
34
|
-
stylingContainer.appendChild(cssFile);
|
|
35
|
-
}
|
|
36
|
-
})
|
|
37
|
-
.catch((err) => {
|
|
38
|
-
console.error('There was an error while trying to load client styling from URL', err);
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* @name setStreamLibrary
|
|
44
|
-
* @description Method used to create and append to the passed element of the widget a style element with content fetched from the MessageBus
|
|
45
|
-
* @param {HTMLElement} stylingContainer The highest element of the widget
|
|
46
|
-
* @param {string} domain The domain from where the content should be fetched (e.g. 'Casino.Style', 'App.Style', 'casino-footer.style', etc.)
|
|
47
|
-
* @param {ref} subscription A reference to a variable where the subscription should be saved for unsubscribing when no longer needed
|
|
48
|
-
*/
|
|
49
|
-
function setStreamStyling(stylingContainer, domain, subscription) {
|
|
50
|
-
if (window.emMessageBus) {
|
|
51
|
-
const sheet = document.createElement('style');
|
|
52
|
-
|
|
53
|
-
window.emMessageBus.subscribe(domain, (data) => {
|
|
54
|
-
sheet.innerHTML = data;
|
|
55
|
-
if (stylingContainer) {
|
|
56
|
-
stylingContainer.appendChild(sheet);
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
}
|
|
2
|
+
import { s as setClientStyling, a as setClientStylingURL, b as setStreamStyling } from './index-30f31c84.js';
|
|
61
3
|
|
|
62
4
|
var GameType;
|
|
63
5
|
(function (GameType) {
|
|
@@ -2469,61 +2411,9 @@ const resolveTranslationUrl = async (translationUrl) => {
|
|
|
2469
2411
|
}
|
|
2470
2412
|
};
|
|
2471
2413
|
|
|
2472
|
-
|
|
2473
|
-
var LoadingOutlined = { "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" };
|
|
2474
|
-
const LoadingOutlined$1 = LoadingOutlined;
|
|
2475
|
-
|
|
2476
|
-
var __assign = (undefined && undefined.__assign) || function () {
|
|
2477
|
-
__assign = Object.assign || function(t) {
|
|
2478
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
2479
|
-
s = arguments[i];
|
|
2480
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
2481
|
-
t[p] = s[p];
|
|
2482
|
-
}
|
|
2483
|
-
return t;
|
|
2484
|
-
};
|
|
2485
|
-
return __assign.apply(this, arguments);
|
|
2486
|
-
};
|
|
2487
|
-
var defaultColors = {
|
|
2488
|
-
primaryColor: '#333',
|
|
2489
|
-
secondaryColor: '#E6E6E6'
|
|
2490
|
-
};
|
|
2491
|
-
function renderIconDefinitionToSVGElement(icond, options) {
|
|
2492
|
-
if (options === void 0) { options = {}; }
|
|
2493
|
-
if (typeof icond.icon === 'function') {
|
|
2494
|
-
// two-tone
|
|
2495
|
-
var placeholders = options.placeholders || defaultColors;
|
|
2496
|
-
return renderAbstractNodeToSVGElement(icond.icon(placeholders.primaryColor, placeholders.secondaryColor), options);
|
|
2497
|
-
}
|
|
2498
|
-
// fill, outline
|
|
2499
|
-
return renderAbstractNodeToSVGElement(icond.icon, options);
|
|
2500
|
-
}
|
|
2501
|
-
function renderAbstractNodeToSVGElement(node, options) {
|
|
2502
|
-
var targetAttrs = node.tag === 'svg'
|
|
2503
|
-
? __assign(__assign({}, node.attrs), (options.extraSVGAttrs || {})) : node.attrs;
|
|
2504
|
-
var attrs = Object.keys(targetAttrs).reduce(function (acc, nextKey) {
|
|
2505
|
-
var key = nextKey;
|
|
2506
|
-
var value = targetAttrs[key];
|
|
2507
|
-
var token = "".concat(key, "=\"").concat(value, "\"");
|
|
2508
|
-
acc.push(token);
|
|
2509
|
-
return acc;
|
|
2510
|
-
}, []);
|
|
2511
|
-
var attrsToken = attrs.length ? ' ' + attrs.join(' ') : '';
|
|
2512
|
-
var children = (node.children || [])
|
|
2513
|
-
.map(function (child) { return renderAbstractNodeToSVGElement(child, options); })
|
|
2514
|
-
.join('');
|
|
2515
|
-
if (children && children.length) {
|
|
2516
|
-
return "<".concat(node.tag).concat(attrsToken, ">").concat(children, "</").concat(node.tag, ">");
|
|
2517
|
-
}
|
|
2518
|
-
return "<".concat(node.tag).concat(attrsToken, " />");
|
|
2519
|
-
}
|
|
2520
|
-
|
|
2521
|
-
const lotteryHakunaTicketHistoryCss = ":host{display:block}.lottery-hakuna-ticket-history__container{padding:var(--lottery-hakuna-container-padding, 0);display:flex;flex-direction:var(--lottery-hakuna-container-flex-direction, column);align-items:var(--lottery-hakuna-container-align-items, center)}.lottery-hakuna-ticket-history__title{color:var(--lottery-hakuna-title-color, #000);font-size:var(--lottery-hakuna-title-font-size, 14px);font-style:var(--lottery-hakuna-title-font-style, normal);font-weight:var(--lottery-hakuna-title-font-weight, 700);line-height:var(--lottery-hakuna-title-line-height, normal);text-transform:var(--lottery-hakuna-title-text-transform, uppercase);margin-bottom:var(--lottery-hakuna-title-margin-bottom, 18px)}lottery-hakuna-ticket-history-item{width:var(--lottery-hakuna-ticket-history-item-width, 100%)}lottery-infinite-scroll{max-width:var(--lottery-hakuna-ticket-history-item-max-width, 100%);height:var(--lottery-hakuna-ticket-history-item-height, 500px)}.lottery-hakuna-ticket-history__end-message{width:var(--lottery-hakuna-end-message-width, 100%);text-align:var(--lottery-hakuna-end-message-text-align, center);font-size:var(--lottery-hakuna-end-message-font-size, 14px)}.lottery-hakuna-ticket-history__loading-more{width:var(--lottery-hakuna-loading-more-width, 100%);display:flex;align-items:center;justify-content:center;font-size:var(--lottery-hakuna-loading-more-font-size, 14px);gap:var(--lottery-hakuna-loading-spinner-text-gap, 8px);}.lottery-hakuna-ticket-history__loading-more .loading-spinner{animation:spin var(--lottery-hakuna-loading-spinner-animation-duration, 1s) linear infinite;color:var(--lottery-hakuna-loading-spinner-color, currentColor);}.lottery-hakuna-ticket-history__loading-more .loading-spinner svg{width:var(--lottery-hakuna-loading-spinner-size, 16px);height:var(--lottery-hakuna-loading-spinner-size, 16px)}@keyframes spin{from{transform:rotate(0deg)}to{transform:rotate(360deg)}}.lottery-hakuna-ticket-history__error-message{display:flex;align-items:center;justify-content:center;gap:8px;margin-bottom:10px}.lottery-hakuna-ticket-history__error-message svg{width:20px;height:20px}";
|
|
2414
|
+
const lotteryHakunaTicketHistoryCss = ":host{display:block}.lottery-hakuna-ticket-history__container{padding:var(--lottery-hakuna-container-padding, 0);display:flex;flex-direction:var(--lottery-hakuna-container-flex-direction, column);align-items:var(--lottery-hakuna-container-align-items, center)}.lottery-hakuna-ticket-history__title{color:var(--lottery-hakuna-title-color, #000);font-size:var(--lottery-hakuna-title-font-size, 14px);font-style:var(--lottery-hakuna-title-font-style, normal);font-weight:var(--lottery-hakuna-title-font-weight, 700);line-height:var(--lottery-hakuna-title-line-height, normal);text-transform:var(--lottery-hakuna-title-text-transform, uppercase);margin-bottom:var(--lottery-hakuna-title-margin-bottom, 18px)}lottery-hakuna-ticket-history-item{width:var(--lottery-hakuna-ticket-history-item-width, 100%)}lottery-infinite-scroll{max-width:var(--lottery-hakuna-ticket-history-item-max-width, 100%);height:var(--lottery-hakuna-ticket-history-item-height, 500px)}.lottery-hakuna-ticket-history__end-message{width:var(--lottery-hakuna-end-message-width, 100%);text-align:var(--lottery-hakuna-end-message-text-align, center);font-size:var(--lottery-hakuna-end-message-font-size, 14px)}.lottery-hakuna-ticket-history__loading-more{width:var(--lottery-hakuna-loading-more-width, 100%);display:flex;align-items:center;justify-content:center;font-size:var(--lottery-hakuna-loading-more-font-size, 14px);gap:var(--lottery-hakuna-loading-spinner-text-gap, 8px);}.lottery-hakuna-ticket-history__loading-more .loading-spinner{animation:spin var(--lottery-hakuna-loading-spinner-animation-duration, 1s) linear infinite;color:var(--lottery-hakuna-loading-spinner-color, currentColor);}.lottery-hakuna-ticket-history__loading-more .loading-spinner svg{width:var(--lottery-hakuna-loading-spinner-size, 16px);height:var(--lottery-hakuna-loading-spinner-size, 16px)}@keyframes spin{from{transform:rotate(0deg)}to{transform:rotate(360deg)}}.lottery-hakuna-ticket-history__error-message{display:flex;align-items:center;justify-content:center;gap:8px;margin-bottom:10px}.lottery-hakuna-ticket-history__error-message svg{width:20px;height:20px}.lottery-hakuna-ticket-history__list{display:grid;grid-template-columns:repeat(auto-fill, minmax(300px, 1fr));gap:10px;box-sizing:border-box;width:100%}";
|
|
2522
2415
|
const LotteryHakunaTicketHistoryStyle0 = lotteryHakunaTicketHistoryCss;
|
|
2523
2416
|
|
|
2524
|
-
const loadingOutLinedSvg = renderIconDefinitionToSVGElement(LoadingOutlined$1, {
|
|
2525
|
-
extraSVGAttrs: { width: '14px', height: '14px', fill: 'currentColor' }
|
|
2526
|
-
});
|
|
2527
2417
|
const LotteryHakunaTicketHistory = class {
|
|
2528
2418
|
constructor(hostRef) {
|
|
2529
2419
|
registerInstance(this, hostRef);
|
|
@@ -2564,6 +2454,11 @@ const LotteryHakunaTicketHistory = class {
|
|
|
2564
2454
|
this.renderItem = (ticket) => {
|
|
2565
2455
|
return (h("lottery-hakuna-ticket-history-item", { "client-styling": this.customStyle + (this.clientStyling || ''), "client-styling-url": this.clientStylingUrl, "mb-source": this.mbSource, translationUrl: this.translationUrl, language: this.language, key: ticket.id, "history-item-name": ticket.name, "history-item-image-src": ticket.imageSrc, "ticket-id": ticket.id, "total-amount": ticket.totalAmount, date: ticket.date, time: ticket.time, "selected-numbers": ticket.selectedNumbers }));
|
|
2566
2456
|
};
|
|
2457
|
+
this.renderSkeletonList = (num) => {
|
|
2458
|
+
return (h("div", { class: "lottery-hakuna-ticket-history__list" }, Array(num)
|
|
2459
|
+
.fill(0)
|
|
2460
|
+
.map(() => this.renderSkeleton())));
|
|
2461
|
+
};
|
|
2567
2462
|
this.mbSource = undefined;
|
|
2568
2463
|
this.clientStyling = undefined;
|
|
2569
2464
|
this.clientStylingUrl = undefined;
|
|
@@ -2590,6 +2485,8 @@ const LotteryHakunaTicketHistory = class {
|
|
|
2590
2485
|
this.errorMessage = undefined;
|
|
2591
2486
|
this.minItemWidth = 300;
|
|
2592
2487
|
this.showSkeleton = true;
|
|
2488
|
+
this.ticketList = [];
|
|
2489
|
+
this.isLoadingList = false;
|
|
2593
2490
|
}
|
|
2594
2491
|
handleClientStylingChange(newValue, oldValue) {
|
|
2595
2492
|
if (newValue != oldValue) {
|
|
@@ -2608,7 +2505,38 @@ const LotteryHakunaTicketHistory = class {
|
|
|
2608
2505
|
}
|
|
2609
2506
|
componentWillLoad() {
|
|
2610
2507
|
resolveTranslationUrl(this.translationUrl);
|
|
2611
|
-
this.
|
|
2508
|
+
this.getAllTickets();
|
|
2509
|
+
}
|
|
2510
|
+
async getAllTickets() {
|
|
2511
|
+
try {
|
|
2512
|
+
this.isLoadingList = true;
|
|
2513
|
+
const { items } = await fetchTicketList({
|
|
2514
|
+
endpoint: this.endpoint,
|
|
2515
|
+
filterData: {
|
|
2516
|
+
offset: 0,
|
|
2517
|
+
limit: 100,
|
|
2518
|
+
vendorGameType: this.vendorGameType
|
|
2519
|
+
},
|
|
2520
|
+
sessionId: this.sessionId,
|
|
2521
|
+
meta: {
|
|
2522
|
+
name: this.ticketHistoryItemName,
|
|
2523
|
+
imageSrc: this.ticketHistoryItemImageSrc,
|
|
2524
|
+
currency: this.ticketHistoryItemCurrency
|
|
2525
|
+
}
|
|
2526
|
+
});
|
|
2527
|
+
this.ticketList = items;
|
|
2528
|
+
}
|
|
2529
|
+
catch (err) {
|
|
2530
|
+
if (err.status === 401) {
|
|
2531
|
+
this.errorMessage = translate('unauthorized', this.language);
|
|
2532
|
+
window.postMessage({ type: 'SessionExpired' }, window.location.href);
|
|
2533
|
+
return;
|
|
2534
|
+
}
|
|
2535
|
+
this.errorMessage = translate('failToShowTicketList', this.language);
|
|
2536
|
+
}
|
|
2537
|
+
finally {
|
|
2538
|
+
this.isLoadingList = false;
|
|
2539
|
+
}
|
|
2612
2540
|
}
|
|
2613
2541
|
async getTicketList(page, isRefresh = false) {
|
|
2614
2542
|
try {
|
|
@@ -2673,11 +2601,14 @@ const LotteryHakunaTicketHistory = class {
|
|
|
2673
2601
|
disconnectedCallback() {
|
|
2674
2602
|
this.stylingSubscription && this.stylingSubscription.unsubscribe();
|
|
2675
2603
|
}
|
|
2604
|
+
renderTicketList() {
|
|
2605
|
+
return (h("div", { class: "lottery-hakuna-ticket-history__list" }, this.ticketList.map((ticket) => this.renderItem(ticket))));
|
|
2606
|
+
}
|
|
2676
2607
|
renderInfoIcon() {
|
|
2677
2608
|
return (h("svg", { width: "45", height: "45", viewBox: "0 0 45 45", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", fill: "currentColor", d: "M22.5 5.625C13.1802 5.625 5.625 13.1802 5.625 22.5C5.625 31.8198 13.1802 39.375 22.5 39.375C31.8198 39.375 39.375 31.8198 39.375 22.5C39.375 13.1802 31.8198 5.625 22.5 5.625ZM1.875 22.5C1.875 11.1091 11.1091 1.875 22.5 1.875C33.8909 1.875 43.125 11.1091 43.125 22.5C43.125 33.8909 33.8909 43.125 22.5 43.125C11.1091 43.125 1.875 33.8909 1.875 22.5ZM22.5 13.125C23.5355 13.125 24.375 13.9645 24.375 15V22.5C24.375 23.5355 23.5355 24.375 22.5 24.375C21.4645 24.375 20.625 23.5355 20.625 22.5V15C20.625 13.9645 21.4645 13.125 22.5 13.125ZM20.625 30C20.625 28.9645 21.4645 28.125 22.5 28.125H22.5188C23.5543 28.125 24.3938 28.9645 24.3938 30C24.3938 31.0355 23.5543 31.875 22.5188 31.875H22.5C21.4645 31.875 20.625 31.0355 20.625 30Z" })));
|
|
2678
2609
|
}
|
|
2679
2610
|
render() {
|
|
2680
|
-
return (h("div", { key: '
|
|
2611
|
+
return (h("div", { key: '0433d863f5272aa244a014381b58b82b9c975bed', class: "lottery-hakuna-ticket-history__container", ref: (el) => (this.stylingContainer = el) }, h("div", { key: 'df8f56cc99e845b5a65858d649fa59b8945b49d2', class: "lottery-hakuna-ticket-history__title" }, this.ticketHistoryTitle), this.errorMessage && (h("div", { key: 'b880a26e24fb2b2ae1590b6c6d4b963de598c6f3', class: "lottery-hakuna-ticket-history__error-message" }, this.renderInfoIcon(), h("span", { key: '1248f83b4635123f760d49e9ca26013aa268dc26' }, this.errorMessage))), this.isLoadingList ? this.renderSkeletonList(8) : this.renderTicketList()));
|
|
2681
2612
|
}
|
|
2682
2613
|
static get watchers() { return {
|
|
2683
2614
|
"clientStyling": ["handleClientStylingChange"],
|
|
@@ -2687,4 +2618,4 @@ const LotteryHakunaTicketHistory = class {
|
|
|
2687
2618
|
};
|
|
2688
2619
|
LotteryHakunaTicketHistory.style = LotteryHakunaTicketHistoryStyle0;
|
|
2689
2620
|
|
|
2690
|
-
export { LotteryHakunaTicketHistory as L
|
|
2621
|
+
export { LotteryHakunaTicketHistory as L };
|
|
@@ -16,5 +16,5 @@ var patchBrowser = () => {
|
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(async (options) => {
|
|
18
18
|
await globalScripts();
|
|
19
|
-
return bootstrapLazy([["lottery-
|
|
19
|
+
return bootstrapLazy([["lottery-infinite-scroll",[[1,"lottery-infinite-scroll",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"items":[16],"hasMore":[4,"has-more"],"isLoading":[4,"is-loading"],"isRefreshing":[4,"is-refreshing"],"threshold":[1],"containerHeight":[1,"container-height"],"renderItem":[16],"renderSkeleton":[16],"skeletonCount":[2,"skeleton-count"],"pullTriggerDistance":[2,"pull-trigger-distance"],"minItemWidth":[2,"min-item-width"],"gridGap":[2,"grid-gap"],"pullDistance":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"],"isRefreshing":["handleRefreshingChange"]}]]],["lottery-button_7",[[1,"lottery-hakuna-ticket-history",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"endpoint":[513],"gameId":[513,"game-id"],"playerId":[514,"player-id"],"sessionId":[513,"session-id"],"scrollThreshold":[1,"scroll-threshold"],"scrollContainerHeight":[2,"scroll-container-height"],"ticketHistoryTitle":[1,"ticket-history-title"],"ticketHistoryItemImageSrc":[1,"ticket-history-item-image-src"],"ticketHistoryItemName":[1,"ticket-history-item-name"],"ticketHistoryItemCurrency":[1,"ticket-history-item-currency"],"listLoadingText":[1,"list-loading-text"],"listRefreshingText":[1,"list-refreshing-text"],"listEndText":[1,"list-end-text"],"limit":[2],"minItemWidth":[2,"min-item-width"],"showSkeleton":[4,"show-skeleton"],"visibleTickets":[32],"hasMore":[32],"isLoading":[32],"isRefreshing":[32],"errorMessage":[32],"ticketList":[32],"isLoadingList":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-hakuna-ticket-history-item",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"historyItemName":[1,"history-item-name"],"historyItemImageSrc":[1,"history-item-image-src"],"ticketId":[8,"ticket-id"],"totalAmount":[1,"total-amount"],"date":[1],"time":[1],"selectedNumbers":[1,"selected-numbers"],"showSkeleton":[4,"show-skeleton"],"selectedNumbersCount":[2,"selected-numbers-count"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-selection-group",{"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"language":[513],"translationUrl":[513,"translation-url"],"splitToken":[513,"split-token"],"selectionGroupId":[513,"selection-group-id"],"selectionGroupLabel":[513,"selection-group-label"],"type":[513],"selectedBulletTexts":[513,"selected-bullet-texts"],"maxSelectedCount":[514,"max-selected-count"],"maxDisplayBulletsCount":[514,"max-display-bullets-count"],"bulletTexts":[513,"bullet-texts"],"maxIntegerBulletText":[514,"max-integer-bullet-text"],"minIntegerBulletText":[514,"min-integer-bullet-text"],"bulletTextType":[513,"bullet-text-type"],"hasBorder":[516,"has-border"],"hasBackground":[516,"has-background"],"dialogTitle":[513,"dialog-title"],"dialogInputPlaceholder":[513,"dialog-input-placeholder"],"dialogConfig":[32],"inputInfo":[32]},[[0,"lotteryBulletClick","lotteryBulletClickHandler"]],{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[0,"ui-skeleton",{"structure":[1],"width":[1],"height":[1],"borderRadius":[8,"border-radius"],"marginBottom":[8,"margin-bottom"],"marginTop":[8,"margin-top"],"marginLeft":[8,"margin-left"],"marginRight":[8,"margin-right"],"animation":[4],"rows":[2],"size":[1]},null,{"structure":["handleStructureChange"]}],[1,"lottery-button",{"variant":[513],"size":[513],"color":[513],"disabled":[516],"loading":[516],"text":[513],"mbSource":[513,"mb-source"],"language":[513],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"ripples":[32]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-selection",{"value":[520],"text":[513],"idx":[514],"type":[513],"mbSource":[513,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"hasBorder":[516,"has-border"],"hasBackground":[516,"has-background"],"deleteIconSvg":[513,"delete-icon-svg"],"deleteIconWidth":[513,"delete-icon-width"],"deleteIconHeight":[513,"delete-icon-height"]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}],[1,"lottery-tipping-dialog",{"mbSource":[1,"mb-source"],"clientStyling":[513,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"visible":[516],"dialogTitle":[1,"dialog-title"],"width":[1],"closable":[4],"mask":[4],"maskClosable":[4,"mask-closable"],"animationDuration":[2,"animation-duration"],"fullscreen":[4],"showFooter":[4,"show-footer"],"showCancelBtn":[4,"show-cancel-btn"],"language":[513],"translationUrl":[520,"translation-url"],"dialogClass":[1,"dialog-class"],"dialogStyle":[16]},null,{"clientStyling":["handleClientStylingChange"],"clientStylingUrl":["handleClientStylingUrlChange"],"mbSource":["handleMbSourceChange"]}]]]], options);
|
|
20
20
|
});
|
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-50addd47.js';
|
|
2
|
+
import { b as setStreamStyling, s as setClientStyling, a as setClientStylingURL } from './index-30f31c84.js';
|
|
3
|
+
|
|
4
|
+
const DEFAULT_LANGUAGE = 'en';
|
|
5
|
+
const SUPPORTED_LANGUAGES = ['ro', 'en', 'fr', 'ar', 'hr'];
|
|
6
|
+
const TRANSLATIONS = {
|
|
7
|
+
en: {
|
|
8
|
+
noMoreData: 'No more data',
|
|
9
|
+
loading: 'Loading...',
|
|
10
|
+
release: 'Release',
|
|
11
|
+
refreshing: 'Refreshing...',
|
|
12
|
+
pull: 'Pull'
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
const translate = (key, customLang, replacements) => {
|
|
16
|
+
const lang = customLang;
|
|
17
|
+
let translation = TRANSLATIONS[lang !== undefined && SUPPORTED_LANGUAGES.includes(lang) ? lang : DEFAULT_LANGUAGE][key];
|
|
18
|
+
if (replacements) {
|
|
19
|
+
Object.keys(replacements).forEach((placeholder) => {
|
|
20
|
+
translation = translation.replace(`{${placeholder}}`, replacements[placeholder]);
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return translation;
|
|
24
|
+
};
|
|
25
|
+
const getTranslations = (data) => {
|
|
26
|
+
Object.keys(data).forEach((item) => {
|
|
27
|
+
for (let key in data[item]) {
|
|
28
|
+
TRANSLATIONS[item][key] = data[item][key];
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
const resolveTranslationUrl = async (translationUrl) => {
|
|
33
|
+
if (translationUrl) {
|
|
34
|
+
try {
|
|
35
|
+
const response = await fetch(translationUrl);
|
|
36
|
+
if (!response.ok) {
|
|
37
|
+
throw new Error(`HTTP error! status: ${response.status}`);
|
|
38
|
+
}
|
|
39
|
+
const translations = await response.json();
|
|
40
|
+
getTranslations(translations);
|
|
41
|
+
}
|
|
42
|
+
catch (error) {
|
|
43
|
+
console.error('Failed to fetch or parse translations from URL:', error);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
const lotteryInfiniteScrollCss = ":host{display:block;width:100%}.lottery-infinite-scroll__container{display:block;width:100%;overflow-x:hidden;-webkit-overflow-scrolling:touch;padding-right:10px;box-sizing:border-box;scrollbar-width:thin;scrollbar-color:var(--emw-hakuna-bg-secondary, #120505) var(--lottery-infinite-scroll-scrollbar-track-background, transparent);}.lottery-infinite-scroll__container::-webkit-scrollbar{width:var(--lottery-infinite-scroll-scrollbar-width, 2px)}.lottery-infinite-scroll__container::-webkit-scrollbar-track{background:var(--lottery-infinite-scroll-scrollbar-track-background, transparent)}.lottery-infinite-scroll__container::-webkit-scrollbar-thumb{background:var(--emw-hakuna-bg-secondary, #120505);border-radius:var(--lottery-infinite-scroll-scrollbar-thumb-border-radius, 2px)}.lottery-infinite-scroll__sentinel{width:100%;display:block;text-align:center;}.lottery-infinite-scroll__sentinel.virtual-scroll-sentinel{height:1px;pointer-events:none;opacity:0;position:absolute;width:100%}.lottery-infinite-scroll__sentinel:not(.virtual-scroll-sentinel){height:1px;}.lottery-infinite-scroll__end-message{width:100%;display:block;text-align:center;}.lottery-infinite-scroll__end-message.virtual-scroll-end-message{position:absolute;width:100%}.ptr-indicator{height:var(--pull-trigger-distance, 60px);margin-top:calc(-1 * var(--pull-trigger-distance, 60px));display:flex;align-items:center;justify-content:center;position:absolute;top:0;width:100%;z-index:10;font-size:14px;color:#666;}";
|
|
49
|
+
const LotteryInfiniteScrollStyle0 = lotteryInfiniteScrollCss;
|
|
50
|
+
|
|
51
|
+
const LotteryInfiniteScroll = class {
|
|
52
|
+
constructor(hostRef) {
|
|
53
|
+
registerInstance(this, hostRef);
|
|
54
|
+
this.loadMore = createEvent(this, "loadMore", 7);
|
|
55
|
+
this.refresh = createEvent(this, "refresh", 7);
|
|
56
|
+
// Touch event vars
|
|
57
|
+
this.startY = 0;
|
|
58
|
+
this.isTouching = false;
|
|
59
|
+
// --- Pull to Refresh Logic (Touch handling) ---
|
|
60
|
+
this.handleTouchStart = (e) => {
|
|
61
|
+
// Only allow pull-down when scrollbar is at the top
|
|
62
|
+
if (this.scrollContainer.scrollTop <= 0) {
|
|
63
|
+
this.startY = e.touches[0].clientY;
|
|
64
|
+
this.isTouching = true;
|
|
65
|
+
}
|
|
66
|
+
};
|
|
67
|
+
this.handleTouchMove = (e) => {
|
|
68
|
+
if (!this.isTouching || this.isRefreshing)
|
|
69
|
+
return;
|
|
70
|
+
const currentY = e.touches[0].clientY;
|
|
71
|
+
const distance = currentY - this.startY;
|
|
72
|
+
// Only process pull-down and when scrollbar is at the top
|
|
73
|
+
if (distance > 0 && this.scrollContainer.scrollTop <= 0) {
|
|
74
|
+
// Prevent default scroll behavior (prevents entire page from being dragged)
|
|
75
|
+
if (e.cancelable)
|
|
76
|
+
e.preventDefault();
|
|
77
|
+
// Add damping effect (harder to pull further)
|
|
78
|
+
this.pullDistance = Math.pow(distance, 0.8);
|
|
79
|
+
}
|
|
80
|
+
else {
|
|
81
|
+
// If user pushes up, or already scrolled, reset
|
|
82
|
+
this.isTouching = false;
|
|
83
|
+
this.pullDistance = 0;
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
this.handleTouchEnd = () => {
|
|
87
|
+
this.isTouching = false;
|
|
88
|
+
if (this.pullDistance >= this.pullTriggerDistance) {
|
|
89
|
+
// Trigger refresh
|
|
90
|
+
this.pullDistance = this.pullTriggerDistance; // Stay in loading area
|
|
91
|
+
this.refresh.emit();
|
|
92
|
+
}
|
|
93
|
+
else {
|
|
94
|
+
// Not reached threshold, bounce back
|
|
95
|
+
this.pullDistance = 0;
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
this.mbSource = undefined;
|
|
99
|
+
this.clientStyling = undefined;
|
|
100
|
+
this.clientStylingUrl = undefined;
|
|
101
|
+
this.language = 'en';
|
|
102
|
+
this.translationUrl = '';
|
|
103
|
+
this.items = [];
|
|
104
|
+
this.hasMore = false;
|
|
105
|
+
this.isLoading = false;
|
|
106
|
+
this.isRefreshing = false;
|
|
107
|
+
this.threshold = '0px 0px 200px 0px';
|
|
108
|
+
this.containerHeight = '100%';
|
|
109
|
+
this.renderItem = undefined;
|
|
110
|
+
this.renderSkeleton = undefined;
|
|
111
|
+
this.skeletonCount = 6;
|
|
112
|
+
this.pullTriggerDistance = 60;
|
|
113
|
+
this.minItemWidth = 340;
|
|
114
|
+
this.gridGap = 10;
|
|
115
|
+
this.pullDistance = 0;
|
|
116
|
+
}
|
|
117
|
+
componentDidLoad() {
|
|
118
|
+
this.initObserver();
|
|
119
|
+
if (this.scrollContainer) {
|
|
120
|
+
if (this.mbSource)
|
|
121
|
+
setStreamStyling(this.scrollContainer, `${this.mbSource}.Style`);
|
|
122
|
+
if (this.clientStyling)
|
|
123
|
+
setClientStyling(this.scrollContainer, this.clientStyling);
|
|
124
|
+
if (this.clientStylingUrl)
|
|
125
|
+
setClientStylingURL(this.scrollContainer, this.clientStylingUrl);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
handleClientStylingChange(newValue, oldValue) {
|
|
129
|
+
if (newValue != oldValue) {
|
|
130
|
+
setClientStyling(this.scrollContainer, this.clientStyling);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
handleClientStylingUrlChange(newValue, oldValue) {
|
|
134
|
+
if (newValue != oldValue) {
|
|
135
|
+
setClientStylingURL(this.scrollContainer, this.clientStylingUrl);
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
handleMbSourceChange(newValue, oldValue) {
|
|
139
|
+
if (newValue != oldValue) {
|
|
140
|
+
setStreamStyling(this.scrollContainer, `${this.mbSource}.Style`);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
componentWillLoad() {
|
|
144
|
+
resolveTranslationUrl(this.translationUrl);
|
|
145
|
+
}
|
|
146
|
+
componentDidUpdate() {
|
|
147
|
+
if (this.hasMore && !this.isLoading) {
|
|
148
|
+
this.initObserver();
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
disconnectedCallback() {
|
|
152
|
+
this.disconnectObserver();
|
|
153
|
+
this.stylingSubscription && this.stylingSubscription.unsubscribe();
|
|
154
|
+
}
|
|
155
|
+
handleRefreshingChange(newValue) {
|
|
156
|
+
if (!newValue) {
|
|
157
|
+
this.pullDistance = 0;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
disconnectObserver() {
|
|
161
|
+
if (this.observer) {
|
|
162
|
+
this.observer.disconnect();
|
|
163
|
+
this.observer = null;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
initObserver() {
|
|
167
|
+
this.disconnectObserver();
|
|
168
|
+
if (!this.hasMore || this.isLoading || !this.sentinel)
|
|
169
|
+
return;
|
|
170
|
+
const options = {
|
|
171
|
+
root: this.scrollContainer,
|
|
172
|
+
rootMargin: this.threshold,
|
|
173
|
+
threshold: 0.1
|
|
174
|
+
};
|
|
175
|
+
this.observer = new IntersectionObserver((entries) => {
|
|
176
|
+
if (entries[0].isIntersecting && this.hasMore && !this.isLoading) {
|
|
177
|
+
this.loadMore.emit();
|
|
178
|
+
}
|
|
179
|
+
}, options);
|
|
180
|
+
this.observer.observe(this.sentinel);
|
|
181
|
+
}
|
|
182
|
+
render() {
|
|
183
|
+
const { items, minItemWidth, gridGap } = this;
|
|
184
|
+
const showSkeleton = items.length === 0 && !!this.renderSkeleton && this.isLoading;
|
|
185
|
+
const listToRender = showSkeleton ? new Array(this.skeletonCount).fill(null) : items;
|
|
186
|
+
const contentTransform = {
|
|
187
|
+
transform: `translateY(${this.pullDistance}px)`,
|
|
188
|
+
transition: this.isTouching ? 'none' : 'transform 0.3s ease-out'
|
|
189
|
+
};
|
|
190
|
+
const listStyle = {
|
|
191
|
+
display: 'grid',
|
|
192
|
+
gridTemplateColumns: `repeat(auto-fill, minmax(${minItemWidth}px, 1fr))`,
|
|
193
|
+
gap: `${gridGap}px`,
|
|
194
|
+
boxSizing: 'border-box'
|
|
195
|
+
};
|
|
196
|
+
return (h("div", { key: 'e47cafd444a010ce552fabd3c00722e32b1b3cd8', class: "lottery-infinite-scroll__container", style: {
|
|
197
|
+
height: this.containerHeight,
|
|
198
|
+
overflowY: 'auto',
|
|
199
|
+
position: 'relative'
|
|
200
|
+
}, ref: (el) => (this.scrollContainer = el), onTouchStart: this.handleTouchStart, onTouchMove: this.handleTouchMove, onTouchEnd: this.handleTouchEnd }, h("div", { key: 'ee21b030a6f83432edfce4b6cf2719c045fde57f', class: "ptr-indicator", style: Object.assign(Object.assign({}, contentTransform), { position: 'absolute', top: '0', left: '0', width: '100%', height: `${this.pullTriggerDistance}px`, display: 'flex', alignItems: 'center', justifyContent: 'center', marginTop: `-${this.pullTriggerDistance}px`, pointerEvents: 'none' }) }, this.isRefreshing ? (h("slot", { name: "refresh-loading" }, translate('refreshing', this.language))) : (h("slot", { name: "pull-hint" }, this.pullDistance > this.pullTriggerDistance
|
|
201
|
+
? translate('release', this.language)
|
|
202
|
+
: translate('pull', this.language)))), h("div", { key: '15dd187e7683d16112b6366f94a840153c2c32a4', class: "scroll-content-wrapper", style: contentTransform }, h("div", { key: '241ba9f947b2846d78a0beae5806e60f0ac86c8f', class: "list-content", style: listStyle }, listToRender.map((item, index) => (h("div", { key: index, class: "list-item-wrapper" }, showSkeleton ? this.renderSkeleton(index) : this.renderItem(item, index))))), h("div", { key: 'c014157ee2f47cc6020d8cffb06136c6e78e2323', class: "lottery-infinite-scroll__sentinel", ref: (el) => (this.sentinel = el), style: {
|
|
203
|
+
height: '20px',
|
|
204
|
+
display: 'flex',
|
|
205
|
+
justifyContent: 'center',
|
|
206
|
+
visibility: this.hasMore || (this.isLoading && !showSkeleton) ? 'visible' : 'hidden'
|
|
207
|
+
} }, this.isLoading ? h("slot", { name: "loading-more" }, translate('loading', this.language)) : null), !this.hasMore && !this.isLoading && items.length > 0 && (h("div", { key: 'd363303795035f2f1a1bd8ace34999084171a866', class: "end-message", style: { textAlign: 'center', padding: '10px' } }, h("slot", { key: '1be1f840fa161f07a2ecd14c11d0168f5d1156c6', name: "end-message" }, translate('noMoreData', this.language)))))));
|
|
208
|
+
}
|
|
209
|
+
get el() { return getElement(this); }
|
|
210
|
+
static get watchers() { return {
|
|
211
|
+
"clientStyling": ["handleClientStylingChange"],
|
|
212
|
+
"clientStylingUrl": ["handleClientStylingUrlChange"],
|
|
213
|
+
"mbSource": ["handleMbSourceChange"],
|
|
214
|
+
"isRefreshing": ["handleRefreshingChange"]
|
|
215
|
+
}; }
|
|
216
|
+
};
|
|
217
|
+
LotteryInfiniteScroll.style = LotteryInfiniteScrollStyle0;
|
|
218
|
+
|
|
219
|
+
export { LotteryInfiniteScroll as lottery_infinite_scroll };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function n(n,t){if(n){const o=document.createElement("style");o.innerHTML=t,n.appendChild(o)}}function t(n,t){if(!n||!t)return;const o=new URL(t);fetch(o.href).then((n=>n.text())).then((t=>{const o=document.createElement("style");o.innerHTML=t,n&&n.appendChild(o)})).catch((n=>{console.error("There was an error while trying to load client styling from URL",n)}))}function o(n,t){if(window.emMessageBus){const o=document.createElement("style");window.emMessageBus.subscribe(t,(t=>{o.innerHTML=t,n&&n.appendChild(o)}))}}export{t as a,o as b,n as s}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{L as LotteryHakunaTicketHistory}from"./lottery-hakuna-ticket-history-
|
|
1
|
+
export{L as LotteryHakunaTicketHistory}from"./lottery-hakuna-ticket-history-844d94d7.js";import"./index-50addd47.js";import"./index-30f31c84.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,h as e,g as i,c as r,H as o}from"./index-50addd47.js";import{s as n,a,b as l}from"./index-30f31c84.js";export{L as lottery_hakuna_ticket_history}from"./lottery-hakuna-ticket-history-844d94d7.js";const s=["ro","en","fr","ar","hr","zh"],c={en:{loading:"Loading"},ro:{},fr:{},ar:{},hr:{}},h=class{constructor(e){t(this,e),this.handleClick=t=>{if(this.disabled)return;const e=this.host.shadowRoot.querySelector(".btn");if(!e)return;const i=e.getBoundingClientRect(),r=Math.max(i.width,i.height),o={top:t.clientY-i.top-r/2,left:t.clientX-i.left-r/2,size:r};this.ripples=[...this.ripples,o],setTimeout((()=>{this.ripples=this.ripples.filter((t=>t!==o))}),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&&n(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&a(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&l(this.stylingContainer,`${this.mbSource}.Style`)}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}componentDidLoad(){this.stylingContainer&&(this.mbSource&&l(this.stylingContainer,`${this.mbSource}.Style`),this.clientStyling&&n(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&a(this.stylingContainer,this.clientStylingUrl))}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const i=await fetch(t);if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);const r=await i.json();e=r,Object.keys(e).forEach((t=>{for(let i in e[t])c[t][i]=e[t][i]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}render(){const{variant:t,disabled:i,size:r,color:o}=this,n=i||this.loading,a={};if(o)switch(t){case"primary":default:Object.assign(a,{backgroundColor:o,borderColor:o});break;case"outline":case"dashed":Object.assign(a,{color:o,borderColor:o});break;case"text":Object.assign(a,{color:o})}return e("button",{key:"aa74ad98c90e7548228557bf8a8d26b125d4a83a",class:{btn:!0,[`btn--${t}`]:!0,[`btn--${r}`]:!0,"btn--loading":this.loading},style:o?a:void 0,disabled:n,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=c[void 0!==t&&s.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,i)=>e("span",{key:i,class:"ripple",style:{top:`${t.top}px`,left:`${t.left}px`,width:`${t.size}px`,height:`${t.size}px`}})))))}get host(){return i(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};h.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}}";const d=["ro","en","fr","ar","hr"],u={en:{total:"Total:"}},g=class{constructor(i){t(this,i),this.selectionGroupStyle="\n :host{\n --lottery-selection-width: 24px;\n --lottery-selection-height: 24px;\n --lottery-selection-padding: 10px;\n --lottery-selection-border-radius: 6px;\n --lottery-selection-border-width: 1px;\n --lottery-selection-border-color: var(--emw-hakuna-color-primary, #c52217);\n\n --lottery-selection-color: var(--emw-hakuna-text-primary, #ffffff);\n --lottery-selection-font-size: 14px;\n --lottery-selection-font-weight: 500;\n\n --lottery-selection-hover-background: transparent;\n --lottery-selection-hover-border-color: var(--emw-hakuna-color-primary, #c52217);\n --lottery-selection-hover-color: var(--emw-hakuna-text-primary, #ffffff);\n\n .lottery-selection__button{\n box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.15);\n line-height: normal;\n }\n .lottery-selection__button:hover{\n cursor: default;\n }\n --lottery-selection-group-item-gap:6px;\n }\n ",this.renderSkeleton=()=>e("div",{class:"lottery-hakuna-ticket-history-item__container"},e("div",{class:"lottery-hakuna-ticket-history-item__top"},e("div",{class:"lottery-hakuna-ticket-history-item__country-wrapper"},e("ui-skeleton",{structure:"image",width:"30px",height:"20px"}),e("ui-skeleton",{structure:"title",width:"86px",height:"17px",marginBottom:0})),e("div",{class:"lottery-hakuna-ticket-history-item__details"},e("ui-skeleton",{structure:"text",width:"60%",height:"20px"}))),e("div",{class:"lottery-hakuna-ticket-history-item__bottom"},e("div",{class:"lottery-hakuna-ticket-history-item__numbers-wrapper"},new Array(this.selectedNumbersCount).fill(e("ui-skeleton",{borderRadius:"8px",structure:"rectangle",width:"24px",height:"24px"}))),e("div",{class:"lottery-hakuna-ticket-history-item__date-wrapper"},e("ui-skeleton",{structure:"text",width:"180px",height:"14px"})))),this.renderMain=()=>e("div",{class:"lottery-hakuna-ticket-history-item__container"},e("div",{class:"lottery-hakuna-ticket-history-item__top"},e("div",{class:"lottery-hakuna-ticket-history-item__country-wrapper"},this.historyItemImageSrc&&e("img",{src:this.historyItemImageSrc,alt:this.historyItemName,class:"lottery-hakuna-ticket-history-item__country-flag"}),e("span",{class:"lottery-hakuna-ticket-history-item__country-name"},this.historyItemName)),e("div",{class:"lottery-hakuna-ticket-history-item__details"},e("span",{class:"lottery-hakuna-ticket-history-item__meta"},(()=>{const t=this.language;let e=u[void 0!==t&&d.includes(t)?t:"en"].total;return e})(),e("span",{class:"lottery-hakuna-ticket-history-item__meta-value"},this.totalAmount)))),e("div",{class:"lottery-hakuna-ticket-history-item__bottom"},e("div",{class:"lottery-hakuna-ticket-history-item__numbers-wrapper"},this.selectedNumbers&&e("lottery-selection-group",{type:"preview",bulletTexts:this.selectedNumbers,clientStyling:this.selectionGroupStyle+(this.clientStyling||""),clientStylingUrl:this.clientStylingUrl,mbSource:this.mbSource,hasBorder:!0,hasBackground:!1,selectionGroupId:this.ticketId?this.ticketId.toString():void 0})),e("div",{class:"lottery-hakuna-ticket-history-item__date-wrapper"},this.date&&e("div",null,this.date),this.time&&e("div",null,this.time)))),this.mbSource=void 0,this.clientStyling=void 0,this.clientStylingUrl=void 0,this.language="en",this.translationUrl="",this.historyItemName=void 0,this.historyItemImageSrc=void 0,this.ticketId=void 0,this.totalAmount=void 0,this.date=void 0,this.time=void 0,this.selectedNumbers=void 0,this.showSkeleton=!1,this.selectedNumbersCount=6}handleClientStylingChange(t,e){t!=e&&n(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&a(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&l(this.stylingContainer,`${this.mbSource}.Style`)}async componentWillLoad(){(async t=>{if(t)try{const i=await fetch(t);if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);const r=await i.json();e=r,Object.keys(e).forEach((t=>{for(let i in e[t])u[t][i]=e[t][i]}))}catch(t){console.error("Failed to fetch or parse translations from URL:",t)}var e})(this.translationUrl)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&l(this.stylingContainer,`${this.mbSource}.Style`),this.clientStyling&&n(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&a(this.stylingContainer,this.clientStylingUrl))}disconnectedCallback(){this.stylingSubscription&&this.stylingSubscription.unsubscribe()}render(){return e("div",{key:"d22e301e9824aa3539e0c11ed52a1bddc5e1fb9c",ref:t=>this.stylingContainer=t,class:"lottery-hakuna-ticket-history-item__container-wrapper"},this.showSkeleton?this.renderSkeleton():this.renderMain())}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};g.style=".lottery-hakuna-ticket-history-item__container{display:flex;padding:var(--lottery-hakuna-ticket-history-item-container-padding, 20px);flex-direction:column;justify-content:center;gap:var(--lottery-hakuna-ticket-history-item-container-gap, 16px);border-radius:var(--lottery-hakuna-ticket-history-item-container-border-radius, 12px);border:1px solid transparent;min-width:var(--lottery-hakuna-ticket-history-item-container-min-width, 200px);background-origin:border-box;background-clip:padding-box, border-box;background-image:linear-gradient(var(--emw-hakuna-bg-secondary, #120505), var(--emw-hakuna-bg-secondary, #120505)), linear-gradient(to top left, var(--emw-hakuna-color-primary, #c52217) var(--lottery-hakuna-ticket-history-item-border-gradient-start-stop, 22%), var(--emw-hakuna-bg-primary, #2c2525) var(--lottery-hakuna-ticket-history-item-border-gradient-end-stop, 68%))}.lottery-hakuna-ticket-history-item__top{display:flex;justify-content:space-between;align-items:center}.lottery-hakuna-ticket-history-item__country-wrapper{display:flex;align-items:center;gap:10px}.lottery-hakuna-ticket-history-item__country-flag{width:var(--lottery-hakuna-ticket-history-item-country-flag-width, 30px);object-fit:cover;aspect-ratio:var(--lottery-hakuna-ticket-history-item-country-flag-aspect-ratio, 3/2)}.lottery-hakuna-ticket-history-item__country-name{color:var(--lottery-hakuna-ticket-history-item-country-name-color, #fff);font-size:var(--lottery-hakuna-ticket-history-item-country-name-font-size, 14px);font-style:normal;font-weight:var(--lottery-hakuna-ticket-history-item-country-name-font-weight, 700);line-height:var(--lottery-hakuna-ticket-history-item-country-name-line-height, normal)}.lottery-hakuna-ticket-history-item__details{display:flex;gap:var(--lottery-hakuna-ticket-history-item-details-gap, 13px);color:var(--emw-hakuna-text-secondary, #b4a5a5);font-size:var(--lottery-hakuna-ticket-history-item-details-font-size, 10px);font-style:normal;font-weight:var(--lottery-hakuna-ticket-history-item-details-font-weight, 700);line-height:var(--lottery-hakuna-ticket-history-item-details-line-height, normal)}.lottery-hakuna-ticket-history-item__meta{display:flex;gap:var(--lottery-hakuna-ticket-history-item-meta-gap, 10px)}.lottery-hakuna-ticket-history-item__meta-value{color:var(--lottery-hakuna-ticket-history-item-meta-value-color, inherit)}.lottery-hakuna-ticket-history-item__bottom{display:flex;justify-content:space-between;align-items:center;align-self:stretch}.lottery-hakuna-ticket-history-item__numbers-wrapper{flex:1;display:flex;align-items:flex-start;gap:var(--lottery-hakuna-ticket-history-item-numbers-wrapper-gap, 8px);box-shadow:var(--lottery-hakuna-ticket-history-item-numbers-wrapper-box-shadow, 0 1px 2px 0 rgba(0, 0, 0, 0.25))}.lottery-hakuna-ticket-history-item__date-wrapper{color:var(--lottery-hakuna-ticket-history-item-date-wrapper-color, #fffefe);text-align:var(--lottery-hakuna-ticket-history-item-date-wrapper-text-align, right);font-size:var(--lottery-hakuna-ticket-history-item-date-wrapper-font-size, 8px);font-style:normal;font-weight:var(--lottery-hakuna-ticket-history-item-date-wrapper-font-weight, 400);line-height:var(--lottery-hakuna-ticket-history-item-date-wrapper-line-height, 125%);min-width:var(--lottery-hakuna-ticket-history-item-date-wrapper-min-width, 70px);max-width:var(--lottery-hakuna-ticket-history-item-date-wrapper-max-width, 100px)}lottery-selection-group{width:100%}ui-skeleton{--emw-skeleton-primary-color:#414141;--emw-skeleton-secondary-color:#2f2929}";const b={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"};var y=function(){return y=Object.assign||function(t){for(var e,i=1,r=arguments.length;i<r;i++)for(var o in e=arguments[i])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},y.apply(this,arguments)},p={primaryColor:"#333",secondaryColor:"#E6E6E6"};function m(t,e){var i="svg"===t.tag?y(y({},t.attrs),e.extraSVGAttrs||{}):t.attrs,r=Object.keys(i).reduce((function(t,e){var r=i[e],o="".concat(e,'="').concat(r,'"');return t.push(o),t}),[]),o=r.length?" "+r.join(" "):"",n=(t.children||[]).map((function(t){return m(t,e)})).join("");return n&&n.length?"<".concat(t.tag).concat(o,">").concat(n,"</").concat(t.tag,">"):"<".concat(t.tag).concat(o," />")}const v=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&&n(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!==e&&a(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!==e&&l(this.stylingContainer,`${this.mbSource}.Style`)}componentDidLoad(){this.stylingContainer&&(this.mbSource&&l(this.stylingContainer,`${this.mbSource}.Style`),this.clientStyling&&n(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&a(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):function(t,e){if(void 0===e&&(e={}),"function"==typeof t.icon){var i=e.placeholders||p;return m(t.icon(i.primaryColor,i.secondaryColor),e)}return m(t.icon,e)}(b,{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"]}}};v.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 f=["ro","en","fr","ar","hr","zh"],k={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:{}},w=(t,e,i)=>{const r=e;let o=k[void 0!==r&&f.includes(r)?r:"en"][t];return i&&Object.keys(i).forEach((t=>{o=o.replace(`{${t}}`,i[t])})),o};function x(t,e){return new Set(t?t.split(e):[])}function _(t,e){return e.filter((e=>e!==t))}function S(t,e){return e.concat([t])}const C=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.dialogConfig={width:"400px",visible:!1,onConfirm:()=>this.handleFillInAddMore(),onCancel:()=>this.handleCloseAddMoreDialog()},this.inputInfo={valid:!0,errorMessage:"",value:""}}handleClientStylingChange(t,e){t!=e&&n(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&a(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&l(this.stylingContainer,`${this.mbSource}.Style`)}componentWillLoad(){var t;this.translationUrl&&(t=JSON.parse(this.translationUrl),Object.keys(t).forEach((e=>{for(let i in t[e])k[e][i]=t[e][i]})))}componentDidLoad(){this.stylingContainer&&(this.mbSource&&l(this.stylingContainer,`${this.mbSource}.Style`),this.clientStyling&&n(this.stylingContainer,this.clientStyling),this.clientStylingUrl&&a(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,i=Array.from(this.selectedSet),r=this.maxSelectedCount,"delete"===e.type?_(e.text,i):"toggle"===e.type?i.includes(e.text)?_(e.text,i):i.length>=r?function(t,e,i){return e.slice(e.length-(i-1)).concat([t])}(e.text,i,r):S(e.text,i):[]).join(this.splitToken),selectionGroupId:this.selectionGroupId});else var e,i,r;else this.dialogConfig=Object.assign(Object.assign({},this.dialogConfig),{visible:!0})}get selectedSet(){return x(this.selectedBulletTexts,this.splitToken)}get bulletTextsSet(){return this.bulletTexts?x(this.bulletTexts,this.splitToken):"integer"===this.bulletTextType&&null!=this.maxIntegerBulletText?x(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,i=!1;return"text"===this.bulletTextType?t.length>this.maxDisplayBulletsCount?(i=!0,e=t.slice(0,this.maxDisplayBulletsCount-1)):e=t:(i=null!=this.maxIntegerBulletText&&this.maxIntegerBulletText>Number(this.lastDisplayBulletText),e=t),{bulletsToRender:e,showInputButton:i}}renderBulletGroup(){let t=[];if("bet"===this.type){const e=null!==this.maxSelectedCount&&this.selectedSet.size>=this.maxSelectedCount,{bulletsToRender:i,showInputButton:r}=this.getBulletToRender();if(i.forEach(((i,r)=>{let o="toggle";this.selectedSet.has(String(i))||!e||this.isSingleSelectionMode||(o="disabled"),t.push({value:this.selectedSet.has(String(i))?1:0,text:String(i),idx:r,type:o})})),r){let i="input";e&&!this.isSingleSelectionMode&&(i="disabled");const r="text"===this.bulletTextType?"...":`${this.lastDisplayBulletText}+`,o="text"===this.bulletTextType?-1:Number(this.lastDisplayBulletText)+1;"integer"===this.bulletTextType&&t.length>=this.maxDisplayBulletsCount&&t.pop(),t.push({value:0,text:r,idx:o,type:i})}}else if(["choice","preview"].includes(this.type)){const{bulletsToRender:e}=this.getBulletToRender();e.forEach(((e,i)=>{let r="toggle";"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:i,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:i,minValue:r,language:o,type:n="integer"}){const a=t.trim();if("integer"===n){if(!/^-?\d+$/.test(a))return{valid:!1,errorMessage:w("enterValidNumber",o),value:t};const n=Number(a);if(isNaN(n))return{valid:!1,errorMessage:w("enterValidNumber",o),value:t};if(void 0!==r&&n<r||void 0!==i&&n>i)return{valid:!1,errorMessage:w("enterNumberBetween",o,{min:r,max:i}),value:t};const l=String(n);if(e.has(l))return{valid:!1,errorMessage:w("numberAlreadySelected",o),value:t}}else if(e.has(a))return{valid:!1,errorMessage:w("numberAlreadySelected",o),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,i=t;i="integer"===this.bulletTextType?String(Number(t)):t.trim(),e=this.isSingleSelectionMode?i:S(i,Array.from(this.selectedSet)).join(this.splitToken),this.bulletGroupUpdateSelectedBulletTexts.emit({newSelectedBulletTexts:e,selectionGroupId:this.selectionGroupId}),this.handleCloseAddMoreDialog()}}render(){return e("div",{key:"66b8e9c63d948eb2f7eb37adb80892dbedd7df9a",class:"lottery-selection-group",ref:t=>this.stylingContainer=t},e("div",{key:"6562fdcad0f352b5e2d03edcc980a9aeab32277e",class:"lottery-selection-group__item"},this.selectionGroupLabel&&e("div",{key:"43c2132e4904a2b69b970d9b2074f120ed4d0986",class:"lottery-selection-group__item--left"},this.selectionGroupLabel),this.renderBulletGroup()),e("lottery-tipping-dialog",{key:"cb693d10e6b499628909571021d8508cdebbe29a",visible:this.dialogConfig.visible,width:this.dialogConfig.width,onCancel:this.dialogConfig.onCancel},e("div",{key:"dd312634574bbe1b4d3de7e82a9c58f58f846c1a",class:"addSelectionDialog"},e("div",{key:"b371b1090598f0219a7c652bab51e9d349703c34",class:"addSelectionDialog-title"},this.dialogTitle||("text"===this.bulletTextType?w("enterValue",this.language):w("enterScoreUpTo",this.language,{maxScore:this.maxIntegerBulletText}))),e("input",{key:"b5f1bb74999246dac8dc20f04e3af893deae6654",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:"f33970a6dffdc881ffa9cf2c0bb54b26b27cccd6",class:"error-message"},this.inputInfo.errorMessage)),e("div",{key:"4c580dae14b38aff03e17067b2c0b72d01aa4f42",slot:"footer",class:"addSelectionDialog-footer"},e("lottery-button",{key:"874aa0ffde8fe2d0b08efea0cf951f101ab8dad0",onClick:this.dialogConfig.onCancel,text:w("cancel",this.language),variant:"outline"}),e("lottery-button",{key:"63a556eb5f9ad1cdd357c017756be274d40ef235",onClick:this.dialogConfig.onConfirm,text:w("confirm",this.language),variant:"primary",disabled:!this.inputInfo.valid||!this.inputInfo.value}))))}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};C.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 $=["ro","en","fr","ar","hr"],z={en:{cancel:"Cancel",confirm:"Confirm"},ro:{cancel:"Anulează",confirm:"Confirmă"},fr:{cancel:"Annuler",confirm:"Confirmer"},ar:{cancel:"إلغاء",confirm:"تأكيد"},hr:{cancel:"Odustani",confirm:"Potvrdi"}},j=(t,e)=>{const i=e;return z[void 0!==i&&$.includes(i)?i:"en"][t]},T=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}handleClientStylingChange(t,e){t!=e&&n(this.stylingContainer,this.clientStyling)}handleClientStylingUrlChange(t,e){t!=e&&a(this.stylingContainer,this.clientStylingUrl)}handleMbSourceChange(t,e){t!=e&&l(this.stylingContainer,`${this.mbSource}.Style`)}componentWillLoad(){this.translationUrl&&(async t=>{if(t)try{const i=await fetch(t);if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);const r=await i.json();e=r,Object.keys(e).forEach((t=>{for(let i in e[t])z[t][i]=e[t][i]}))}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||{}),i=["dialog-wrapper",this.visible?"dialog-wrapper-visible":""],r=["mask",this.visible?"mask-enter":"mask-leave"],o=["dialog",this.visible?"dialog-enter":"dialog-leave",this.fullscreen?"fullscreen":"",this.dialogClass].filter(Boolean).join(" ");return e("div",{key:"306683c5190fa6dca57dcf75e52eca575c0215e7",class:i.join(" "),ref:t=>this.stylingContainer=t},e("div",{key:"8be097f3a86fcd9ad4e18c6ac56cafdcf249049b",class:r.join(" "),onClick:this.handleMaskClick.bind(this)}),e("div",{key:"87d2206d3e3d75fe0e0ef8a6afd8de5c20892ae6",part:"dialog",class:o,style:t,role:"dialog","aria-modal":"true","aria-labelledby":"dialog-title"},(this.dialogTitle||this.closable)&&e("div",{key:"04d54878aa24e0d9eb98bc921ea3edfacd6de3af",class:"dialog-header"},e("h2",{key:"f6f6c279de47e49cde86d0c907b9b40a115926b3",id:"dialog-title",class:"dialog-title"},this.dialogTitle),this.closable&&e("button",{key:"e1625473e5460cd667961923bf678c9a91b69c82",class:"close-btn",onClick:this.handleClose.bind(this)},"x")),e("div",{key:"fb0db8dd765832cf1d8e8b682131e4c97a93ac22",class:"dialog-content",style:{maxHeight:"calc(100vh - 62px)",overflowY:"auto"}},e("slot",{key:"75336f59c2a8fe6775fc12ed4e2e26ff6bb6b508"})),this.showFooter&&e("div",{key:"a305086a2830265317abb0fd6f59b4a053fd54a9",class:"dialog-footer"},e("slot",{key:"cb330ea63908002f4f8b4b8139d5843c2570302e",name:"footer"},this.showCancelBtn&&e("button",{key:"c3d2c15195e56efd6d388265e9ccb87030627b7b",class:"cancel-btn",onClick:this.handleClose.bind(this)},j("cancel",this.language)),e("button",{key:"af9c96b4e1ce82f9ecb73e2b9f4e93cba0382d76",class:"confirm-btn",onClick:this.handleConfirm.bind(this)},j("confirm",this.language))))))}get el(){return i(this)}static get watchers(){return{clientStyling:["handleClientStylingChange"],clientStylingUrl:["handleClientStylingUrlChange"],mbSource:["handleMbSourceChange"]}}};T.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-color: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 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;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)}}";const M=class{constructor(e){t(this,e),this.stylingValue={width:this.handleStylingProps(this.width),height:this.handleStylingProps(this.height),borderRadius:this.handleStylingProps(this.borderRadius),marginBottom:this.handleStylingProps(this.marginBottom),marginTop:this.handleStylingProps(this.marginTop),marginLeft:this.handleStylingProps(this.marginLeft),marginRight:this.handleStylingProps(this.marginRight),size:this.handleStylingProps(this.size)},this.structure=void 0,this.width="unset",this.height="unset",this.borderRadius="unset",this.marginBottom="unset",this.marginTop="unset",this.marginLeft="unset",this.marginRight="unset",this.animation=!0,this.rows=0,this.size="100%"}handleStructureChange(t,e){e!==t&&this.handleStructure(t)}handleStylingProps(t){switch(typeof t){case"number":return 0===t?0:`${t}px`;case"undefined":default:return"unset";case"string":return["auto","unset","none","inherit","initial"].includes(t)||t.endsWith("px")||t.endsWith("%")?t:"unset"}}handleStructure(t){switch(t){case"logo":return this.renderLogo();case"image":return this.renderImage();case"title":return this.renderTitle();case"text":return this.renderText();case"rectangle":return this.renderRectangle();case"circle":return this.renderCircle();default:return null}}renderLogo(){return e("div",{class:"SkeletonContainer"},e("div",{class:"SkeletonLogo "+(this.animation?"Skeleton":"")}))}renderImage(){return e("div",{class:"SkeletonImage "+(this.animation?"Skeleton":"")})}renderTitle(){return e("div",{class:"SkeletonContainer"},e("div",{class:"SkeletonTitle "+(this.animation?"Skeleton":"")}))}renderText(){return e("div",{class:"SkeletonContainer"},Array.from({length:this.rows>0?this.rows:1}).map(((t,i)=>e("div",{key:i,class:"SkeletonText "+(this.animation?"Skeleton":"")}))))}renderRectangle(){return e("div",{class:"SkeletonContainer"},e("div",{class:"SkeletonRectangle "+(this.animation?"Skeleton":"")}))}renderCircle(){return e("div",{class:"SkeletonContainer"},e("div",{class:"SkeletonCircle "+(this.animation?"Skeleton":"")}))}render(){let t="";switch(this.structure){case"logo":t=`\n :host {\n --emw-skeleton-logo-width: ${this.stylingValue.width};\n --emw-skeleton-logo-height: ${this.stylingValue.height};\n --emw-skeleton-logo-border-radius: ${this.stylingValue.borderRadius};\n --emw-skeleton-logo-margin-bottom: ${this.stylingValue.marginBottom};\n --emw-skeleton-logo-margin-top: ${this.stylingValue.marginTop};\n --emw-skeleton-logo-margin-left: ${this.stylingValue.marginLeft};\n --emw-skeleton-logo-margin-right: ${this.stylingValue.marginRight};\n }\n `;break;case"image":t=`\n :host {\n --emw-skeleton-image-width: ${this.stylingValue.width};\n --emw-skeleton-image-height: ${this.stylingValue.height};\n --emw-skeleton-image-border-radius: ${this.stylingValue.borderRadius};\n --emw-skeleton-image-margin-bottom: ${this.stylingValue.marginBottom};\n --emw-skeleton-image-margin-top: ${this.stylingValue.marginTop};\n --emw-skeleton-image-margin-left: ${this.stylingValue.marginLeft};\n --emw-skeleton-image-margin-right: ${this.stylingValue.marginRight};\n }\n `;break;case"title":t=`\n :host {\n --emw-skeleton-title-width: ${this.stylingValue.width};\n --emw-skeleton-title-height: ${this.stylingValue.height};\n --emw-skeleton-title-border-radius: ${this.stylingValue.borderRadius};\n --emw-skeleton-title-margin-bottom: ${this.stylingValue.marginBottom};\n --emw-skeleton-title-margin-top: ${this.stylingValue.marginTop};\n --emw-skeleton-title-margin-left: ${this.stylingValue.marginLeft};\n --emw-skeleton-title-margin-right: ${this.stylingValue.marginRight};\n }\n `;break;case"text":t=`\n :host {\n --emw-skeleton-text-width: ${this.stylingValue.width};\n --emw-skeleton-text-height: ${this.stylingValue.height};\n --emw-skeleton-text-border-radius: ${this.stylingValue.borderRadius};\n --emw-skeleton-text-margin-bottom: ${this.stylingValue.marginBottom};\n --emw-skeleton-text-margin-top: ${this.stylingValue.marginTop};\n --emw-skeleton-text-margin-left: ${this.stylingValue.marginLeft};\n --emw-skeleton-text-margin-right: ${this.stylingValue.marginRight};\n }\n `;break;case"rectangle":t=`\n :host {\n --emw-skeleton-rectangle-width: ${this.stylingValue.width};\n --emw-skeleton-rectangle-height: ${this.stylingValue.height};\n --emw-skeleton-rectangle-border-radius: ${this.stylingValue.borderRadius};\n --emw-skeleton-rectangle-margin-bottom: ${this.stylingValue.marginBottom};\n --emw-skeleton-rectangle-margin-top: ${this.stylingValue.marginTop};\n --emw-skeleton-rectangle-margin-left: ${this.stylingValue.marginLeft};\n --emw-skeleton-rectangle-margin-right: ${this.stylingValue.marginRight};\n }\n `;break;case"circle":t=`\n :host {\n --emw-skeleton-circle-size: ${this.stylingValue.size};\n }\n `;break;default:t=""}return e(o,{key:"c2a2650acd416962a2bc4e1a7ee18bc6d8e2def8"},e("style",{key:"9bd7fc1f9e9ed9f17735a7b72fce6f09696f5e19"},t),this.handleStructure(this.structure))}static get watchers(){return{structure:["handleStructureChange"]}}};M.style=":host{display:block}.Skeleton{animation:skeleton-loading 1s linear infinite alternate}.SkeletonRectangle{background-color:var(--emw-skeleton-rectangle-background, #c2c2c2);width:var(--emw-skeleton-rectangle-width, 400px);height:var(--emw-skeleton-rectangle-height, 200px);border-radius:var(--emw-skeleton-rectangle-border-radius, 10px)}.SkeletonCircle{background-color:var(--emw-skeleton-circle-background, #c2c2c2);width:var(--emw-skeleton-circle-size, 400px);height:var(--emw-skeleton-circle-size, 400px);border-radius:50%}.SkeletonText{background-color:var(--emw-skeleton-text-background, #c2c2c2);width:var(--emw-skeleton-text-width, 500px);height:var(--emw-skeleton-text-height, 20px);border-radius:var(--emw-skeleton-text-border-radius, 10px);margin-bottom:var(--emw-skeleton-text-margin-bottom, 5px)}.SkeletonText:last-child{width:calc(var(--emw-skeleton-text-width, 400px) - 100px)}.SkeletonTitle{background-color:var(--emw-skeleton-title-background, #c2c2c2);width:var(--emw-skeleton-title-width, 300px);height:var(--emw-skeleton-title-height, 30px);border-radius:var(--emw-skeleton-title-border-radius, 10px);margin-bottom:var(--emw-skeleton-title-margin-bottom, 5px)}.SkeletonImage{background-color:var(--emw-skeleton-image-background, #c2c2c2);width:var(--emw-skeleton-image-width, 100%);height:var(--emw-skeleton-image-height, 100%);border-radius:var(--emw-skeleton-image-border-radius, unset)}.SkeletonLogo{background-color:var(--emw-skeleton-logo-background, #c2c2c2);width:var(--emw-skeleton-logo-width, 120px);height:var(--emw-skeleton-logo-height, 75px);border-radius:var(--emw-skeleton-logo-border-radius, 10px)}@keyframes skeleton-loading{0%{background-color:var(--emw-skeleton-primary-color, #e0e0e0)}100%{background-color:var(--emw-skeleton-secondary-color, #f0f0f0)}}";export{h as lottery_button,g as lottery_hakuna_ticket_history_item,v as lottery_selection,C as lottery_selection_group,T as lottery_tipping_dialog,M as ui_skeleton}
|