--- import NavbarLayout from "@layouts/NavbarLayout.astro"; import {Image} from "astro:assets"; import Card from "@components/Card.svelte"; import localBau from "@images/2023-10-08_20.43.43.png"; import {CaretRight, Archive, Rocket, Bell} from "@astropub/icons"; import {t} from "astro-i18n"; import {l} from "@utils/util"; import PlayerCount from "@components/PlayerCount.svelte"; import "../../public/fonts/barlow-condensed/barlow-condensed.css"; import type {Player} from "@components/types/data"; const teamMember = await fetch("http://127.0.0.1:1337/data/team").then(value => value.json()); function groupByGroup(array) { const groups = new Map(); for (let user of array) { if (groups.has(user.prefix)) { groups.get(user.prefix).push(user); } else { groups.set(user.prefix, [user]); } } return groups; } const groupedTeamMember = groupByGroup(teamMember); function mapMap(i: Map, fn: (key: T, value: K) => J): J[] { const arr = []; for (let [key, value] of i) { arr.push(fn(key, value)); } return arr; } ---
Bau

{t("home.title.first")}{t("home.title.second")}

{t("home.subtitle.1")}

{t("home.subtitle.2")}

{t("home.subtitle.3")}

{t("home.join")}

{t("home.benefits.historic.title")}

{t("home.benefits.historic.description.1")}

{t("home.benefits.historic.description.2")}

{t("home.benefits.server.title")}

{t("home.benefits.server.description")}

{t("home.benefits.events.title")}

{t("home.benefits.events.description.1")}

{t("home.benefits.events.description.2")}

{t("home.benefits.read")}
{mapMap(groupedTeamMember, (key, value) => (

{t("home.prefix." + key)}

{value.map(v => (
{v.name}
{v.name
))}
))}