返回 CodeWhale
manifest.ts
根目录 / web / app / manifest.ts
1 import type { MetadataRoute } from "next";
2 import { SITE_NAME } from "@/lib/page-meta";
3
4 /**
5 * Web app manifest. Icons are the founder's whale mark in white on the
6 * #142352 navy tile, rasterised from app/icon.svg by
7 * scripts/brand/trace-brand.py. Static rasters live in public/ next to the
8 * other shipped assets; the field naming follows the Next.js metadata-file
9 * convention already used by app/icon.svg and app/opengraph-image.tsx.
10 */
11 export default function manifest(): MetadataRoute.Manifest {
12 return {
13 name: SITE_NAME,
14 short_name: SITE_NAME,
15 icons: [
16 {
17 src: "/icon-192.png",
18 sizes: "192x192",
19 type: "image/png",
20 },
21 {
22 src: "/icon-512.png",
23 sizes: "512x512",
24 type: "image/png",
25 },
26 ],
27 // Brand navy: the icon tile, so the installed shell's splash and chrome
28 // are one surface with the mark.
29 theme_color: "#142352",
30 background_color: "#142352",
31 display: "standalone",
32 };
33 }
34
34 lines TYPESCRIPT