Vollstaendige Next.js/Prisma-E-Commerce-Anwendung fuer eine Imkerei: Shop, Warenkorb, Stripe-Checkout, Kundenkonto mit 2FA, Admin-Bereich (Produkte, Ernten, Chargen, Bestellungen, Gutscheine, admin-editierbare Website-Inhalte), i18n (DE/EN), Rate-Limiting/CSP/Audit-Log-Haertung, PostgreSQL- und MySQL-Unterstuetzung ueber austauschbare Prisma- Treiber-Adapter, Unit-/Komponenten-/E2E-Tests.
35 lines
1.1 KiB
TypeScript
35 lines
1.1 KiB
TypeScript
import type { MetadataRoute } from "next";
|
|
import { getCompanyInfo } from "@/lib/company-info";
|
|
import { getLocale } from "@/i18n/locale";
|
|
import { getDictionary } from "@/i18n/get-dictionary";
|
|
|
|
/**
|
|
* Web-App-Manifest fuer "Zum Startbildschirm hinzufuegen" auf Mobilgeraeten —
|
|
* nutzt das bestehende icon.svg direkt statt zusaetzlich generierter
|
|
* Raster-Varianten (Chrome/Android unterstuetzen SVG-Manifest-Icons mit
|
|
* sizes:"any" nativ, siehe MDN). Sprachabhaengig wie der Rest der Seite.
|
|
*/
|
|
export default async function manifest(): Promise<MetadataRoute.Manifest> {
|
|
const locale = await getLocale();
|
|
const t = getDictionary(locale);
|
|
const company = await getCompanyInfo();
|
|
|
|
return {
|
|
name: `${company.name} — ${t.footer.tagline}`,
|
|
short_name: company.name,
|
|
description: t.common.siteDescription,
|
|
start_url: "/",
|
|
display: "standalone",
|
|
background_color: "#FAF8F3",
|
|
theme_color: "#24352B",
|
|
icons: [
|
|
{
|
|
src: "/icon.svg",
|
|
sizes: "any",
|
|
type: "image/svg+xml",
|
|
purpose: "any",
|
|
},
|
|
],
|
|
};
|
|
}
|