@everymatrix/casino-game-page 0.0.268 → 0.0.269

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-game-page",
3
- "version": "0.0.268",
3
+ "version": "0.0.269",
4
4
  "main": "dist/casino-game-page.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": "c5b78b8fcf6dd4293a5b296177205963840e7289"
39
+ "gitHead": "f99063bddeebbe083973aa77500fc3ee5d9de894"
40
40
  }
@@ -66,6 +66,8 @@
66
66
  let mobileView:boolean = false;
67
67
  let favoriteGames: Array<Object> = [];
68
68
  let customStylingContainer:HTMLElement;
69
+ let buttonsContainer:HTMLElement;
70
+ let timeContainer:HTMLElement;
69
71
  let isOnNative:boolean = false;
70
72
 
71
73
  setupI18n({ withLocale: 'en', translations: {}});
@@ -243,15 +245,13 @@
243
245
  let gameFrame = getComputedStyle(gameInnerContainer);
244
246
  let gameContainerWidth = parseInt(iframeContainer.width.slice(0, -2));
245
247
  let gameContainerHeight = parseInt(iframeContainer.height.slice(0, -2));
246
-
247
248
  const iframeRatio = game.width/(game.height + 100);
248
249
 
249
250
  gameFrameWidth = parseInt(gameFrame.width);
250
251
  gameFrameHeight = parseInt(gameFrame.height);
251
-
252
252
  // resize logic for maintaining game ratio when resizing
253
- if ((gameContainerWidth / iframeRatio) > gameContainerHeight){
254
- gameFrameHeight = gameContainerHeight;
253
+ if ((gameContainerWidth / iframeRatio) > (gameContainerHeight - buttonsContainer.clientHeight - timeContainer.clientHeight)){
254
+ gameFrameHeight = gameContainerHeight - buttonsContainer.clientHeight - timeContainer.clientHeight;
255
255
  gameFrameWidth = gameContainerHeight * iframeRatio;
256
256
  } else {
257
257
  gameFrameWidth = gameContainerWidth;
@@ -524,7 +524,7 @@
524
524
  <div id="IframeContainer" part="IframeContainer" bind:this={gameFrameContainer} class:FullsScreenLayout={isFullscreen} style="width: {modalFrameWidth}; height: {modalFrameHeight}">
525
525
  <div id="IframeGame" part="IframeGame" bind:this={gameInnerContainer} style="width: {isFullscreen ? '100%' : definitiveIframeWidth}; height: {isFullscreen ? '100%' : definitiveIframeHeight}; max-width: {isFullscreen ? 'none' : (game.width ? game.width + 'px' : '1280px')}; max-height: {isFullscreen ? 'none' : (game.height ? (Math.floor(game.height) + 100) + 'px' : '720px')}">
526
526
  <iframe title="Games" id="IframeGame" class="GamesContainer" part="GamesContainer" aria-hidden="false" src={game.launchUrl} bind:this={iframe}/>
527
- <div class="BottomGame" part="BottomGame">
527
+ <div class="BottomGame" part="BottomGame" bind:this={buttonsContainer}>
528
528
  <button class="DepositButton" part="DepositButton" on:click='{() => toggleDeposit()}'>{$_('gamePage.deposit')}</button>
529
529
  {#if haspanicbutton === "true"}
530
530
  <div class="PanicSection" part="PanicSection">
@@ -543,7 +543,7 @@
543
543
  </button>
544
544
  {/if}
545
545
  </div>
546
- <p class="Time" part="Time"><span>{time}</span></p>
546
+ <p class="Time" part="Time" bind:this={timeContainer}><span>{time}</span></p>
547
547
  </div>
548
548
  </div>
549
549
  {:else}
@@ -551,7 +551,7 @@
551
551
  <div id="IframeContainer" part="IframeContainer" bind:this={gameFrameContainer} class:FullsScreenLayout={isFullscreen} style="width: {modalFrameWidth}; height: {modalFrameHeight}">
552
552
  <div id="IframeGame" part="IframeGame" bind:this={gameInnerContainer} style="width: {isFullscreen ? '100%' : definitiveIframeWidth}; height: {isFullscreen ? '100%' : definitiveIframeHeight}; max-width: {isFullscreen || !isModal ? 'none' : (game.width ? Math.floor(game.width) + 'px' : '1280px')}; max-height: {isFullscreen || !isModal ? 'none' : (game.height ? (Math.floor(game.height) + 100) + 'px' : '720px')}">
553
553
  <iframe title="Games" class="GamesContainer" part="GamesContainer" aria-hidden="false" src={game.launchUrl} bind:this={iframe}/>
554
- <div class="BottomGame" part="BottomGame">
554
+ <div class="BottomGame" part="BottomGame" bind:this={buttonsContainer}>
555
555
  <div class="ButtonsContainer" part="ButtonsContainer">
556
556
  <button class="LoginButton" part="LoginButton" on:click='{() => toggleLogin()}'>{$_('gamePage.signIn')}</button>
557
557
  <button class="RegisterButton" part="RegisterButton" on:click='{() => toggleRegister()}'>{$_('gamePage.register')}</button>
@@ -566,7 +566,7 @@
566
566
  </button>
567
567
  {/if}
568
568
  </div>
569
- <p class="Time" part="Time"><span>{time}</span></p>
569
+ <p class="Time" part="Time" bind:this={timeContainer}><span>{time}</span></p>
570
570
  </div>
571
571
  </div>
572
572
  {:else}
@@ -600,7 +600,6 @@
600
600
  .BottomGame {
601
601
  padding-left: 60px;
602
602
  padding-right: 60px;
603
- padding-bottom: 15px;
604
603
  min-height: 85px;
605
604
  background-color: var(--emfe-w-color-contrast, #07072A);
606
605
  display: flex;
@@ -631,7 +630,6 @@
631
630
  height: 60px;
632
631
  background-color: var(--emfe-w-color-primary, #D0046C);
633
632
  float: right;
634
- margin-top: 20px;
635
633
  }
636
634
  .GameDetails {
637
635
  display: flex;