Compare commits

..

No commits in common. "f53dc28597031975141a110219422d3d49717b1c" and "5fd7f715e7cdea9b6c445871cb8e91d9da122487" have entirely different histories.

8 changed files with 29 additions and 16 deletions

13
package-lock.json generated
View File

@ -35,6 +35,7 @@
"svelte": "^4.2.7",
"svelte-check": "^3.6.2",
"svelte-heros-v2": "^0.10.12",
"svelte-local-storage-store": "^0.6.4",
"svelte-multicssclass": "^2.1.1",
"svelte-preprocess": "^5.1.1",
"tailwindcss": "^3.3.5",
@ -4937,6 +4938,18 @@
"svelte": "^3.19.0 || ^4.0.0"
}
},
"node_modules/svelte-local-storage-store": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/svelte-local-storage-store/-/svelte-local-storage-store-0.6.4.tgz",
"integrity": "sha512-45WoY2vSGPQM1sIQJ9jTkPPj20hYeqm+af6mUGRFSPP5WglZf36YYoZqwmZZ8Dt/2SU8lem+BTA8/Z/8TkqNLg==",
"dev": true,
"engines": {
"node": ">=0.14"
},
"peerDependencies": {
"svelte": "^3.48.0 || >4.0.0"
}
},
"node_modules/svelte-multicssclass": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/svelte-multicssclass/-/svelte-multicssclass-2.1.1.tgz",

View File

@ -32,6 +32,7 @@
"svelte": "^4.2.7",
"svelte-check": "^3.6.2",
"svelte-heros-v2": "^0.10.12",
"svelte-local-storage-store": "^0.6.4",
"svelte-multicssclass": "^2.1.1",
"svelte-preprocess": "^5.1.1",
"tailwindcss": "^3.3.5",

View File

@ -33,7 +33,7 @@ export const rulesShort = {
`
},
{
title: 'Redstone-Bauten und überdimensionierte Villager-Baukomplexe',
title: 'Redstone bauten und überdimensionierte Villager-Baukomplexe',
content: `
Das Erbauen und Betreiben lag-erzeugender Maschinen, Farmen (Zero-Tick-Farmen etc.) oder andere Bauten, die
den Spielfluss stören könnten, ist verboten.
@ -143,7 +143,7 @@ export const rulesLong = {
`
},
{
title: 'Redstone-Bauten und überdimensionierte Villager-Baukomplexe',
title: 'Redstone bauten und überdimensionierte Villager-Baukomplexe',
content: `
Das Erbauen und Betreiben lag-erzeugender Maschinen, Farmen (Zero-Tick-Farmen etc.) oder andere Bauten, die
den Spielfluss stören könnten, ist verboten. Im Zweifelsfall ist eine Anfrage bei den Administratoren

View File

@ -1,6 +1,9 @@
import { persisted } from 'svelte-local-storage-store';
import type { Writable } from 'svelte/store';
import { writable } from 'svelte/store';
export const playAudio: Writable<boolean> = persisted('playAudio', false);
export const errorMessage: Writable<string | null> = (() => {
const store: Writable<string | null> = writable(null);
return {

View File

@ -2,6 +2,7 @@
import '../app.css';
import { env } from '$env/dynamic/public';
import { goto } from '$app/navigation';
import { playAudio } from '$lib/stores';
import { page } from '$app/stores';
let navPaths = [
@ -92,6 +93,10 @@
let activePath = navPaths.find((path) => path.active);
if (activePath !== undefined) {
goto(activePath.href);
} else if ($playAudio) {
new Audio(
`${env.PUBLIC_BASE_PATH}/aud/chest-${showMenuPermanent ? 'close' : 'open'}.mp3`
).play();
}
showMenuPermanent = !showMenuPermanent;
}

View File

@ -1,7 +1,7 @@
<script lang="ts">
import { env } from '$env/dynamic/public';
import Countdown from '$lib/components/Countdown/Countdown.svelte';
import { Clock, User, WrenchScrewdriver } from 'svelte-heros-v2';
import { User, WrenchScrewdriver } from 'svelte-heros-v2';
import Crosshairs from '$lib/components/CustomIcons/Crosshairs.svelte';
import Skull from '$lib/components/CustomIcons/Skull.svelte';
@ -86,7 +86,7 @@
<div>
<h3 class="text-center text-2xl mb-6">2022 in Zahlen</h3>
<div class="flex flex-col lg:flex-row gap-4">
<div class="stats stats-vertical xl:stats-horizontal shadow">
<div class="stats stats-vertical sm:stats-horizontal shadow">
<div class="stat">
<div class="stat-figure">
<WrenchScrewdriver />
@ -103,16 +103,7 @@
<div class="stat-value">135</div>
</div>
</div>
<div class="stats stats-vertical xl:stats-horizontal shadow h-min xl:h-[initial]">
<div class="stat">
<div class="stat-figure">
<Clock />
</div>
<div class="stat-title">Gesamtspielzeit</div>
<div class="stat-value">210 Tage</div>
</div>
</div>
<div class="stats stats-vertical xl:stats-horizontal shadow">
<div class="stats stats-vertical sm:stats-horizontal shadow">
<div class="stat">
<div class="stat-figure">
<Crosshairs />

View File

@ -64,7 +64,7 @@ export const POST = (async ({ request }) => {
) {
throw error(
400,
'Du hast Dich bereits angemeldet. Sollte dies nicht der Fall sein, wende dich bitte an einen Administrator'
'Du hast dich bereits angemeldet. Sollte dies nicht der Fall sein, wende dich bitte an einen Administrator'
);
}

View File

@ -23,7 +23,7 @@
<h1 class="text-center text-xl sm:text-3xl m-auto">Registrierung erfolgreich</h1>
</div>
<p>
<b>Du hast Dich erfolgreich für Craftattack 6 registriert</b>. Spielstart ist am {new Date(
<b>Du hast dich erfolgreich für Craftattack 6 registriert</b>. Spielstart ist am {new Date(
env.PUBLIC_START_DATE
).toLocaleString('de-DE', startDayOptions)} um {new Date(env.PUBLIC_START_DATE).toLocaleString(
'de-DE',