Chore: format

This commit is contained in:
Dorian Zedler 2023-01-05 19:46:46 +01:00
parent c517ff3c20
commit 428ed81e5b
Signed by: dorian
GPG key ID: 989DE36109AFA354
3 changed files with 23 additions and 13 deletions

View file

@ -38,12 +38,24 @@
border-top: var(--border-width) solid var(--accordion-border-color); border-top: var(--border-width) solid var(--accordion-border-color);
} }
:is(button, input[type="submit"], input[type="button"], [role="button"]).outline.invalid, input[type="reset"].outline { :is(
button,
input[type="submit"],
input[type="button"],
[role="button"]
).outline.invalid,
input[type="reset"].outline {
--color: var(--form-element-invalid-border-color); --color: var(--form-element-invalid-border-color);
--background-color: transparent; --background-color: transparent;
} }
:is(button, input[type="submit"], input[type="button"], [role="button"]).invalid, input[type="reset"] { :is(
button,
input[type="submit"],
input[type="button"],
[role="button"]
).invalid,
input[type="reset"] {
--background-color: var(--form-element-invalid-border-color); --background-color: var(--form-element-invalid-border-color);
--border-color: var(--form-element-invalid-border-color); --border-color: var(--form-element-invalid-border-color);
cursor: pointer; cursor: pointer;

View file

@ -37,8 +37,7 @@
</button> </button>
<label for="skip_switch" class="mb"> <label for="skip_switch" class="mb">
<input x-model="$store.remoteState.skipMe" <input x-model="$store.remoteState.skipMe" type="checkbox" id="skip_switch" role="switch" />
type="checkbox" id="skip_switch" role="switch" />
Skip me Skip me
</label> </label>

View file

@ -30,13 +30,12 @@ document.addEventListener("alpine:init", () => {
}); });
Alpine.effect(() => { Alpine.effect(() => {
const myTurn = this.currentPlayer == Alpine.store("localState").id const myTurn = this.currentPlayer == Alpine.store("localState").id;
if (myTurn && !this.skipMe) { if (myTurn && !this.skipMe) {
this.isMyTurn = true; this.isMyTurn = true;
Alpine.store("audio").playDing(); Alpine.store("audio").playDing();
} } else if (myTurn && this.skipMe) {
else if(myTurn && this.skipMe) { this.giveTurnToNextPlayer();
this.giveTurnToNextPlayer()
} else { } else {
this.isMyTurn = false; this.isMyTurn = false;
} }