alpha01 filetti: web app, crossword service and tor batch

This commit is contained in:
2026-06-05 16:22:17 +02:00
parent 47d8957e15
commit 9cb8a5aa8f
29 changed files with 8590 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
import { notFound } from "next/navigation";
import { CrosswordRuntimePage } from "@/components/crossword-runtime-page";
import { LanguageSwitcher } from "@/components/language-switcher";
import { getDictionary, isLocale } from "@/lib/i18n";
type CrosswordPageProps = {
params: Promise<{ locale: string; id: string }>;
};
export default async function CrosswordPage({ params }: CrosswordPageProps) {
const { locale, id } = await params;
if (!isLocale(locale)) {
notFound();
}
const dict = getDictionary(locale);
return (
<main className="shell stack">
<section className="card play-header">
<div className="hero__topline">
<span className="hero__badge">{dict.play.badge}</span>
<LanguageSwitcher locale={locale} path={`/crosswords/${id}`} />
</div>
<h1 className="page-title">Progetto Enigma</h1>
<p className="page-subtitle">{dict.play.subtitle}</p>
</section>
<CrosswordRuntimePage
id={id}
locale={locale}
labels={{
player: dict.player,
clues: dict.clues,
play: dict.play,
loading: dict.play.loading,
errorPrefix: dict.play.errorPrefix,
}}
/>
</main>
);
}

View File

@@ -0,0 +1,42 @@
import { notFound } from "next/navigation";
import { CrosswordSolutionRuntimePage } from "@/components/crossword-solution-runtime-page";
import { LanguageSwitcher } from "@/components/language-switcher";
import { getDictionary, isLocale } from "@/lib/i18n";
type CrosswordSolutionPageProps = {
params: Promise<{ locale: string; id: string }>;
};
export default async function CrosswordSolutionPage({ params }: CrosswordSolutionPageProps) {
const { locale, id } = await params;
if (!isLocale(locale)) {
notFound();
}
const dict = getDictionary(locale);
return (
<main className="shell stack">
<section className="card play-header">
<div className="hero__topline">
<span className="hero__badge">{dict.solution.badge}</span>
<LanguageSwitcher locale={locale} path={`/crosswords/${id}/solution`} />
</div>
<h1 className="page-title">Progetto Enigma</h1>
<p className="page-subtitle">{dict.solution.subtitle}</p>
</section>
<CrosswordSolutionRuntimePage
id={id}
locale={locale}
labels={{
player: dict.player,
clues: dict.clues,
solution: dict.solution,
loading: dict.play.loading,
errorPrefix: dict.play.errorPrefix,
}}
/>
</main>
);
}