Some design fixes
This commit is contained in:
@@ -44,7 +44,7 @@
|
|||||||
{player.points}
|
{player.points}
|
||||||
{/if}
|
{/if}
|
||||||
</td>
|
</td>
|
||||||
<td class="text-end whitespace-nowrap">{player.name}</td>
|
<td class="pe-4 text-end whitespace-nowrap">{player.name}</td>
|
||||||
</tr>
|
</tr>
|
||||||
{/each}
|
{/each}
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|||||||
@@ -68,8 +68,6 @@
|
|||||||
public answerIsShowing = $state(false);
|
public answerIsShowing = $state(false);
|
||||||
public questionIsShowing = $state(false);
|
public questionIsShowing = $state(false);
|
||||||
|
|
||||||
public pointsGivenForCurrentQuestion = $state(false);
|
|
||||||
|
|
||||||
constructor(game: Game) {
|
constructor(game: Game) {
|
||||||
this.game = game;
|
this.game = game;
|
||||||
}
|
}
|
||||||
@@ -190,7 +188,6 @@
|
|||||||
} else {
|
} else {
|
||||||
player.points += this.question.points;
|
player.points += this.question.points;
|
||||||
}
|
}
|
||||||
this.pointsGivenForCurrentQuestion = true;
|
|
||||||
this.sendPlayers();
|
this.sendPlayers();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -212,7 +209,6 @@
|
|||||||
setupGoingBack(): void {
|
setupGoingBack(): void {
|
||||||
this.answerIsShowing = false;
|
this.answerIsShowing = false;
|
||||||
this.questionIsShowing = false;
|
this.questionIsShowing = false;
|
||||||
this.pointsGivenForCurrentQuestion = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
finishQuestion(): void {
|
finishQuestion(): void {
|
||||||
@@ -350,7 +346,7 @@
|
|||||||
<p>Type of question unknown</p>
|
<p>Type of question unknown</p>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
<div class="m-4 flex items-center gap-4">
|
<div class="m-4 flex flex-wrap items-center gap-4">
|
||||||
<button class="btn" onclick={() => gameManager.goBack()}>Zurück</button>
|
<button class="btn" onclick={() => gameManager.goBack()}>Zurück</button>
|
||||||
{#if gameManager.questionIsShowing}
|
{#if gameManager.questionIsShowing}
|
||||||
<button class="btn" onclick={() => gameManager.hideQuestion()}
|
<button class="btn" onclick={() => gameManager.hideQuestion()}
|
||||||
@@ -379,7 +375,7 @@
|
|||||||
/>
|
/>
|
||||||
{/each}
|
{/each}
|
||||||
<div class="grow"></div>
|
<div class="grow"></div>
|
||||||
{#if gameManager.answerIsShowing && gameManager.pointsGivenForCurrentQuestion}
|
{#if gameManager.answerIsShowing}
|
||||||
<button class="btn" onclick={() => gameManager.finishQuestion()}
|
<button class="btn" onclick={() => gameManager.finishQuestion()}
|
||||||
>Abschließen</button
|
>Abschließen</button
|
||||||
>
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user