diff --git a/astro.config.mjs b/astro.config.mjs index 9d5f075..ba3c8e2 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -5,6 +5,8 @@ import configureI18n from "./astro-i18n.adapter"; import sitemap from "@astrojs/sitemap"; import robotsTxt from "astro-robots-txt"; +import {resolve} from "node:url"; +import path from "node:path"; // https://astro.build/config export default defineConfig({ @@ -30,5 +32,19 @@ export default defineConfig({ disallow: ["/admin", "/login", "/dashboard", "/de", "/_astro"] }] })], - vite: {} + vite: { + resolve: { + alias: { + "@components": path.resolve("./src/components"), + "@pages": path.resolve("./src/pages"), + "@styles": path.resolve("./src/styles"), + "@utils": path.resolve("./src/util"), + "@type": path.resolve("./src/components/types"), + "@images": path.resolve("./src/images"), + "@layouts": path.resolve("./src/layouts"), + "@repo": path.resolve("./src/components/repo"), + "@stores": path.resolve("./src/components/stores"), + } + } + } }); \ No newline at end of file diff --git a/src/components/Dashboard.svelte b/src/components/Dashboard.svelte index 6ba2181..8331297 100644 --- a/src/components/Dashboard.svelte +++ b/src/components/Dashboard.svelte @@ -19,7 +19,7 @@
- {#each Array(rows) as _} + {#each Array(rows) as i (i)} + {/each} {#each window(event.fights.filter(f => f.group === group), rows) as fights} - {#each fights as fight} + {#each fights as fight (fight.id)} + {/each} {/each} @@ -56,6 +71,6 @@ @apply w-full; } div { - @apply p-3 bg-gray-200 dark:bg-gray-800 rounded-2xl w-3/4 mx-auto; + @apply p-3 bg-gray-200 dark:bg-neutral-800 rounded-2xl w-3/4 mx-auto; } \ No newline at end of file diff --git a/src/components/GroupTable.svelte b/src/components/GroupTable.svelte index 3d50299..3edb0bf 100644 --- a/src/components/GroupTable.svelte +++ b/src/components/GroupTable.svelte @@ -20,7 +20,7 @@ diff --git a/src/components/admin/pages/event/modals/CreateFightModal.svelte b/src/components/admin/pages/event/modals/CreateFightModal.svelte index 927d9d3..3e47aae 100644 --- a/src/components/admin/pages/event/modals/CreateFightModal.svelte +++ b/src/components/admin/pages/event/modals/CreateFightModal.svelte @@ -19,10 +19,9 @@ -
dragover = false}> +
dragover = false} role="none">
diff --git a/src/components/admin/pages/generate/GroupGenerator.svelte b/src/components/admin/pages/generate/GroupGenerator.svelte index f14b897..c76837b 100644 --- a/src/components/admin/pages/generate/GroupGenerator.svelte +++ b/src/components/admin/pages/generate/GroupGenerator.svelte @@ -18,14 +18,14 @@ -->
{t("announcements.table.time")} {t("announcements.table.blue")} {t("announcements.table.red")}{t("announcements.table.winner")}
{Intl.DateTimeFormat(astroI18n.locale, { hour: "numeric", minute: "numeric", }).format(new Date(fight.start))} {fight.blueTeam.kuerzel} {fight.redTeam.kuerzel}{getWinner(fight)}