Move the field guide into the docs section
Some checks failed
Deploy MineGeo to Dokploy / deploy (push) Failing after 10m22s

This commit is contained in:
2026-10-28 11:08:36 +05:00
parent ed4d264801
commit 5898ef35a5
14 changed files with 85 additions and 103 deletions

View File

@@ -1,52 +1,5 @@
import { getI18n } from "@/lib/i18n";
import { Header, Footer } from "@/components/Shell";
import Link from "next/link";
export default async function About() {
const { t } = await getI18n();
return (
<>
<Header />
<main className="section page-content prose" id="main-content" tabIndex={-1}>
<span className="eyebrow">{t("THE EXPLORER’S FIELD GUIDE")}</span>
<h1>
{t("You know this place.")}
<br />
<span className="green">{t("Probably.")}</span>
</h1>
<p className="lead">
{t(
"MineGeo drops you into a panorama from a community Minecraft world. Find out where you are before the clock runs out.",
)}
</p>
<h2>{t("Look for the little things")}</h2>
<p>
{t(
"Drag to look around. Mountains, shorelines, roofs, and landmarks all help. You stay in one place throughout a round.",
)}
</p>
<h2>{t("Make your guess")}</h2>
<p>
{t(
"Expand the map in the bottom-right corner and click to place a pin. North is up, X increases east, and Z increases south. Move your pin until you’re ready, then submit.",
)}
</p>
<h2>{t("Five chances to find your way")}</h2>
<p>
{t(
"Easy gives you 180 seconds, Normal 90, and Hard 30. Void is the hardest: just 10 seconds, a fixed panorama and map, no zoom, no compass or coordinates, and strict scoring. A timed-out round scores zero; you can still finish the expedition.",
)}
</p>
<h2>{t("Closer means better")}</h2>
<p>
{t(
"Each round awards up to 5,000 points based on horizontal distance. A guess within one block earns a perfect score. Compare all five guesses at the end.",
)}
</p>
<Link href="/servers" className="button primary">
{t("Let’s find a world →")}
</Link>
</main>
<Footer />
</>
);
import { permanentRedirect } from "next/navigation";
export default function About() {
permanentRedirect("/docs?page=guide");
}

View File

@@ -5,6 +5,7 @@ import { Header, Footer } from "@/components/Shell";
import guides from "@/shared/player-docs.json";
import styles from "./page.module.css";
import { getI18n } from "@/lib/i18n";
import { PlayerGuide } from "@/components/PlayerGuide";
export const metadata = { title: "Player docs" };
@@ -80,7 +81,13 @@ export default async function Docs({
const { page = "welcome" } = await searchParams;
const { locale } = await getI18n();
const pages = [
...guides,
guides[0],
{
slug: "guide",
title: locale === "ru" ? "Руководство" : "Field guide",
markdown: "",
},
...guides.slice(1),
{
slug: "developer-api",
title: locale === "ru" ? "API для разработчиков" : "Developer API",
@@ -93,7 +100,11 @@ export default async function Docs({
return (
<>
<Header />
<main className={`section page-content ${styles.layout}`} id="main-content" tabIndex={-1}>
<main
className={`section page-content ${styles.layout}`}
id="main-content"
tabIndex={-1}
>
<aside>
<h2>Player docs</h2>
<nav aria-label="Documentation pages" className={styles.menu}>
@@ -109,7 +120,9 @@ export default async function Docs({
</nav>
</aside>
<article className={`prose ${styles.article}`}>
{page === "developer-api" ? (
{page === "guide" ? (
<PlayerGuide />
) : page === "developer-api" ? (
<DeveloperDocumentation locale={locale} />
) : (
content(guide.markdown)

View File

@@ -229,7 +229,7 @@ export default async function Home() {
</div>
</li>
</ol>
<Link className="text-link" href="/about">
<Link className="text-link" href="/docs?page=guide">
{t("Read the field guide")} <ArrowRight size={14} />
</Link>
</article>