@everymatrix/casino-games-category-section 0.0.246 → 0.0.250
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@everymatrix/casino-games-category-section",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.250",
|
|
4
4
|
"main": "dist/casino-games-category-section.js",
|
|
5
5
|
"svelte": "src/index.ts",
|
|
6
6
|
"scripts": {
|
|
@@ -36,5 +36,5 @@
|
|
|
36
36
|
"publishConfig": {
|
|
37
37
|
"access": "public"
|
|
38
38
|
},
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "a6d1510ec4bbfb0c340f1528b6c6636b9552705c"
|
|
40
40
|
}
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
export let favorites:string = '';
|
|
20
20
|
export let clientstyling:string = '';
|
|
21
21
|
export let clientstylingurl:string = '';
|
|
22
|
-
export let currency:string = '
|
|
22
|
+
export let currency:string = '';
|
|
23
23
|
|
|
24
24
|
export let categoryid:string = '';
|
|
25
25
|
export let categoryindex:number = 0;
|
|
@@ -107,12 +107,16 @@
|
|
|
107
107
|
// IntersectionObserver used for loading more games
|
|
108
108
|
let observer = new IntersectionObserver((entries, observerRef) => {
|
|
109
109
|
entries.forEach(async (entry) => {
|
|
110
|
+
let gameid = entry.target.gameid; // eslint-disable-line
|
|
110
111
|
let index = entry.target.elems_index; // eslint-disable-line
|
|
111
112
|
|
|
112
113
|
if (entry.isIntersecting) {
|
|
113
114
|
if (index * 1.2 > limit ) {
|
|
114
115
|
loadMoreGames(categoryid);
|
|
115
116
|
}
|
|
117
|
+
intersectingIndexes[gameid] = 1;
|
|
118
|
+
} else {
|
|
119
|
+
intersectingIndexes[gameid] = 0;
|
|
116
120
|
}
|
|
117
121
|
});
|
|
118
122
|
});
|
|
@@ -488,29 +492,29 @@
|
|
|
488
492
|
$: clientstylingurl && setClientStylingURL();
|
|
489
493
|
</script>
|
|
490
494
|
|
|
491
|
-
<div class="CasinoGamesCategorySectionContainer" bind:this={customStylingContainer}>
|
|
495
|
+
<div class="CasinoGamesCategorySectionContainer" part="CasinoGamesCategorySectionContainer" bind:this={customStylingContainer}>
|
|
492
496
|
{#if hasErrors}
|
|
493
497
|
<!-- @TODO diversify error handling -->
|
|
494
498
|
{#if filteresPresent}
|
|
495
|
-
<p class="SearchLoading">404 Error - No result found.</p>
|
|
499
|
+
<p class="SearchLoading" part="SearchLoading">404 Error - No result found.</p>
|
|
496
500
|
{:else}
|
|
497
|
-
<p class="SearchLoading">500 Error - Internal Server Error.</p>
|
|
501
|
+
<p class="SearchLoading" part="SearchLoading">500 Error - Internal Server Error.</p>
|
|
498
502
|
{/if}
|
|
499
503
|
{:else}
|
|
500
504
|
{#if searched}
|
|
501
|
-
<div class="CasinoGamesContainer">
|
|
502
|
-
<div class="CasinoGamesHeader Searched {isMobile(userAgent) ? 'CasinoGamesHeaderMobile' : ''}">
|
|
505
|
+
<div class="CasinoGamesContainer" part="CasinoGamesContainer">
|
|
506
|
+
<div class="CasinoGamesHeader Searched {isMobile(userAgent) ? 'CasinoGamesHeaderMobile' : ''}" part="CasinoGamesHeader Searched {isMobile(userAgent) ? 'CasinoGamesHeaderMobile' : ''}">
|
|
503
507
|
{#if recentSearched}
|
|
504
|
-
<h3 class="StatusText">
|
|
508
|
+
<h3 class="StatusText" part="StatusText">
|
|
505
509
|
{$_('gamesCategorySection.recentSearchedItems')}
|
|
506
510
|
</h3>
|
|
507
511
|
{:else}
|
|
508
512
|
{#if !shownCategoryData.length}
|
|
509
|
-
<h3 class="StatusText">
|
|
513
|
+
<h3 class="StatusText" part="StatusText">
|
|
510
514
|
{$_('gamesCategorySection.noResults')}
|
|
511
515
|
</h3>
|
|
512
516
|
{:else}
|
|
513
|
-
<h3 class="StatusText">
|
|
517
|
+
<h3 class="StatusText" part="StatusText">
|
|
514
518
|
{$_('gamesCategorySection.searchedItems')}
|
|
515
519
|
</h3>
|
|
516
520
|
{/if}
|
|
@@ -518,16 +522,16 @@
|
|
|
518
522
|
</div>
|
|
519
523
|
{#if shownCategoryData}
|
|
520
524
|
{#if !showItems}
|
|
521
|
-
<p class="NoSearchResults NoRecentSearches NoRecentSearchesCenter {isMobile(userAgent) ? 'NoRecentSearchesMobile' : ''}">{$_('gamesCategorySection.noRecentSearch')}</p>
|
|
525
|
+
<p class="NoSearchResults NoRecentSearches NoRecentSearchesCenter {isMobile(userAgent) ? 'NoRecentSearchesMobile' : ''}" part="NoSearchResults NoRecentSearches NoRecentSearchesCenter {isMobile(userAgent) ? 'NoRecentSearchesMobile' : ''}">{$_('gamesCategorySection.noRecentSearch')}</p>
|
|
522
526
|
{/if}
|
|
523
|
-
<ul class="CasinoGamesGrid SearchedGamesGrid GamesListIncreasedGap">
|
|
527
|
+
<ul class="CasinoGamesGrid SearchedGamesGrid GamesListIncreasedGap" part="CasinoGamesGrid SearchedGamesGrid GamesListIncreasedGap">
|
|
524
528
|
{#each shownCategoryData as gameprops, index}
|
|
525
529
|
<casino-game-thumbnail
|
|
526
530
|
class="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
531
|
+
part="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
527
532
|
session={session}
|
|
528
533
|
userid={userid}
|
|
529
534
|
lang={lang}
|
|
530
|
-
currency={currency}
|
|
531
535
|
searchitem={searchItem}
|
|
532
536
|
favorites={favorites}
|
|
533
537
|
gamethumbnail={gameprops.thumbnail}
|
|
@@ -539,6 +543,7 @@
|
|
|
539
543
|
gameid={gameprops.id}
|
|
540
544
|
gamefunmode={gameprops.hasFunMode}
|
|
541
545
|
gamefavorite={gameprops.isFavorite}
|
|
546
|
+
{currency}
|
|
542
547
|
livelobbyendpoint={gameprops.details ? gameprops.href : ''}
|
|
543
548
|
{clientstyling}
|
|
544
549
|
{clientstylingurl}
|
|
@@ -548,37 +553,37 @@
|
|
|
548
553
|
{/each}
|
|
549
554
|
</ul>
|
|
550
555
|
{:else}
|
|
551
|
-
<p class="SearchWaiting">Waiting</p>
|
|
556
|
+
<p class="SearchWaiting" part="SearchWaiting">Waiting</p>
|
|
552
557
|
{/if}
|
|
553
558
|
</div>
|
|
554
559
|
{:else}
|
|
555
560
|
<div>
|
|
556
561
|
{#if categoryData}
|
|
557
|
-
<div class="CasinoGamesContainer">
|
|
558
|
-
<div class="CasinoGamesHeader">
|
|
559
|
-
<h3 class="CategoryName" bind:this={categoryName}>
|
|
562
|
+
<div class="CasinoGamesContainer" part="CasinoGamesContainer">
|
|
563
|
+
<div class="CasinoGamesHeader" part="CasinoGamesHeader">
|
|
564
|
+
<h3 class="CategoryName" part="CategoryName" bind:this={categoryName}>
|
|
560
565
|
{categoryData.name}
|
|
561
566
|
</h3>
|
|
562
567
|
|
|
563
568
|
{#if showLoadCategory}
|
|
564
569
|
<!-- svelte-ignore a11y-missing-attribute -->
|
|
565
|
-
<a class="CategoryNameLink" on:click="{e => showCategory(categoryData.id, categoryData)}">
|
|
566
|
-
<span class="CategoryLoadMore">
|
|
570
|
+
<a class="CategoryNameLink" part="CategoryNameLink" on:click="{e => showCategory(categoryData.id, categoryData)}">
|
|
571
|
+
<span class="CategoryLoadMore" part="CategoryLoadMore">
|
|
567
572
|
{$_('gamesCategorySection.viewAll')} ({categoryData.games.total})
|
|
568
573
|
</span>
|
|
569
574
|
</a>
|
|
570
575
|
{/if}
|
|
571
576
|
</div>
|
|
572
577
|
{#if shownCategoryData.length !== 0}
|
|
573
|
-
<ul class="{(favoriteGamesData.items.length === 0 && showFavGamesCategory) ? '' : 'CasinoGamesGrid'} GamesListIncreasedGap" bind:this={container}>
|
|
578
|
+
<ul class="{(favoriteGamesData.items.length === 0 && showFavGamesCategory) ? '' : 'CasinoGamesGrid'} GamesListIncreasedGap" part="{(favoriteGamesData.items.length === 0 && showFavGamesCategory) ? '' : 'CasinoGamesGrid'} GamesListIncreasedGap" bind:this={container}>
|
|
574
579
|
{#each shownCategoryData as gameprops, index}
|
|
575
580
|
{#if intersecting || nativeLoading}
|
|
576
581
|
<casino-game-thumbnail
|
|
577
582
|
session={session}
|
|
578
583
|
userid={userid}
|
|
579
584
|
lang={lang}
|
|
580
|
-
currency={currency}
|
|
581
585
|
class="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
586
|
+
part="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
582
587
|
favorites={favorites}
|
|
583
588
|
gamethumbnail={gameprops.thumbnail}
|
|
584
589
|
gamename={gameprops.name}
|
|
@@ -592,6 +597,7 @@
|
|
|
592
597
|
bind:this={thumbnailContainer[index]}
|
|
593
598
|
connectlive={intersectingIndexes[gameprops.id] == 1 ? 'connect' : 'disconnect'}
|
|
594
599
|
visibilityconnect={visibilityconnect}
|
|
600
|
+
{currency}
|
|
595
601
|
livelobbyendpoint={gameprops.details ? gameprops.href : ''}
|
|
596
602
|
{clientstyling}
|
|
597
603
|
{clientstylingurl}
|
|
@@ -602,17 +608,17 @@
|
|
|
602
608
|
{/each}
|
|
603
609
|
</ul>
|
|
604
610
|
{:else}
|
|
605
|
-
<p class="NoSearchResults">You don't have any games in this category.</p>
|
|
611
|
+
<p class="NoSearchResults" part="NoSearchResults">You don't have any games in this category.</p>
|
|
606
612
|
{/if}
|
|
607
613
|
</div>
|
|
608
614
|
{:else if showFavGamesCategory}
|
|
609
|
-
<div class="CasinoGamesContainer">
|
|
610
|
-
<div class="CasinoGamesHeader">
|
|
611
|
-
<h3 class="CategoryName" bind:this={categoryName}>
|
|
615
|
+
<div class="CasinoGamesContainer" part="CasinoGamesContainer">
|
|
616
|
+
<div class="CasinoGamesHeader" part="CasinoGamesHeader">
|
|
617
|
+
<h3 class="CategoryName" part="CategoryName" bind:this={categoryName}>
|
|
612
618
|
{favoriteGamesData.name}
|
|
613
619
|
</h3>
|
|
614
620
|
</div>
|
|
615
|
-
<ul class="{(favoriteGamesData.items.length != 0) ? 'CasinoGamesGrid' : ''} 'GamesListIncreasedGap'}" bind:this={container}>
|
|
621
|
+
<ul class="{(favoriteGamesData.items.length != 0) ? 'CasinoGamesGrid' : ''} 'GamesListIncreasedGap'}" part="{(favoriteGamesData.items.length != 0) ? 'CasinoGamesGrid' : ''} 'GamesListIncreasedGap'}" bind:this={container}>
|
|
616
622
|
{#if favoriteGamesData}
|
|
617
623
|
{#each favoriteGamesData.items as gameprops, index}
|
|
618
624
|
{#if gameprops.gameModel}
|
|
@@ -622,10 +628,10 @@
|
|
|
622
628
|
{#if (gameprops.gameModel.platform.includes("iPad") || gameprops.gameModel.platform.includes("iPhone") || gameprops.gameModel.platform.includes("Android"))}
|
|
623
629
|
<casino-game-thumbnail
|
|
624
630
|
class="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
631
|
+
part="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
625
632
|
session={session}
|
|
626
633
|
userid={userid}
|
|
627
634
|
lang={lang}
|
|
628
|
-
currency={currency}
|
|
629
635
|
favorites={favorites}
|
|
630
636
|
gamethumbnail={gameprops.gameModel.thumbnail}
|
|
631
637
|
gamename={gameprops.gameModel.name}
|
|
@@ -637,6 +643,7 @@
|
|
|
637
643
|
gamefunmode={gameprops.gameModel.hasFunMode}
|
|
638
644
|
gamefavorite={gameprops.gameModel.isFavorite}
|
|
639
645
|
showfavoredcategory={showFavGamesCategory}
|
|
646
|
+
{currency}
|
|
640
647
|
livelobbyendpoint={gameprops.gameModel.details ? gameprops.gameModel.href : ''}
|
|
641
648
|
{clientstyling}
|
|
642
649
|
{clientstylingurl}
|
|
@@ -648,10 +655,10 @@
|
|
|
648
655
|
<!-- <p style="color: var(--emfe-w-color-white, #FFFFFF)">{gameprops.gameModel.isFavorite}</p> -->
|
|
649
656
|
<casino-game-thumbnail
|
|
650
657
|
class="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
658
|
+
part="{MASONRY_CLASS_PREFIX}{gameprops.cellSize ? gameprops.cellSize : '1x1'}"
|
|
651
659
|
session={session}
|
|
652
660
|
userid={userid}
|
|
653
661
|
lang={lang}
|
|
654
|
-
currency={currency}
|
|
655
662
|
favorites={favorites}
|
|
656
663
|
gamethumbnail={gameprops.gameModel.thumbnail}
|
|
657
664
|
gamename={gameprops.gameModel.name}
|
|
@@ -663,6 +670,7 @@
|
|
|
663
670
|
gamefunmode={gameprops.gameModel.hasFunMode}
|
|
664
671
|
gamefavorite={gameprops.gameModel.isFavorite}
|
|
665
672
|
showfavoredcategory={showFavGamesCategory}
|
|
673
|
+
{currency}
|
|
666
674
|
livelobbyendpoint={gameprops.gameModel.details ? gameprops.gameModel.href : ''}
|
|
667
675
|
{clientstyling}
|
|
668
676
|
{clientstylingurl}
|
|
@@ -674,8 +682,8 @@
|
|
|
674
682
|
{/if}
|
|
675
683
|
{/if}
|
|
676
684
|
{:else}
|
|
677
|
-
<p class="NoFavoriteGames {isMobile(userAgent) ? 'NoFavoriteGamesMobile' : ''}">
|
|
678
|
-
<svg version="1.1" class="UnfavoredIcon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="50px" y="50px"
|
|
685
|
+
<p class="NoFavoriteGames {isMobile(userAgent) ? 'NoFavoriteGamesMobile' : ''}" part="NoFavoriteGames {isMobile(userAgent) ? 'NoFavoriteGamesMobile' : ''}">
|
|
686
|
+
<svg version="1.1" class="UnfavoredIcon" part="UnfavoredIcon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="50px" y="50px"
|
|
679
687
|
viewBox="0 0 512.001 512.001" style="enable-background:new 0 0 512.001 512.001;" xml:space="preserve"><path style="fill: white" d="M511.266,197.256c-1.764-5.431-6.458-9.388-12.108-10.209l-158.722-23.065L269.452,20.155
|
|
680
688
|
c-2.527-5.12-7.741-8.361-13.451-8.361c-5.709,0-10.924,3.242-13.451,8.361l-70.988,143.828L12.843,187.047
|
|
681
689
|
c-5.65,0.821-10.344,4.779-12.108,10.209c-1.765,5.43-0.293,11.391,3.795,15.376l114.848,111.955L92.27,482.67
|
|
@@ -685,11 +693,11 @@
|
|
|
685
693
|
l23.311,135.898l-122.038-64.162c-4.37-2.297-9.591-2.297-13.961,0l-122.045,64.163l23.304-135.9
|
|
686
694
|
c0.834-4.866-0.779-9.83-4.313-13.276l-98.731-96.244l136.445-19.829c4.886-0.71,9.108-3.778,11.294-8.205L256,60.685
|
|
687
695
|
l61.023,123.645c2.186,4.427,6.408,7.496,11.294,8.206l136.447,19.828L366.023,308.608z"/></svg>
|
|
688
|
-
<span class="NoFavoriteText NoFavoriteTextHighlight">You do not have any favored games yet.</span>
|
|
696
|
+
<span class="NoFavoriteText NoFavoriteTextHighlight" part="NoFavoriteText NoFavoriteTextHighlight">You do not have any favored games yet.</span>
|
|
689
697
|
{#if isMobile(userAgent)}
|
|
690
|
-
<span class="NoFavoriteText">You can now add games to favorites by tapping on the star icon located on the game page.</span>
|
|
698
|
+
<span class="NoFavoriteText" part="NoFavoriteText">You can now add games to favorites by tapping on the star icon located on the game page.</span>
|
|
691
699
|
{:else}
|
|
692
|
-
<span class="NoFavoriteText">You can now add games to favorites by clicking on the star icon located on the game thumbnail.</span>
|
|
700
|
+
<span class="NoFavoriteText" part="NoFavoriteText">You can now add games to favorites by clicking on the star icon located on the game thumbnail.</span>
|
|
693
701
|
{/if}
|
|
694
702
|
</p>
|
|
695
703
|
{/each}
|