feat: 添加 PWA 支持 — 可安装到主屏幕、离线缓存、刘海屏适配

This commit is contained in:
2026-02-26 16:37:40 +08:00
parent 31003110e1
commit 20f63c67cb
10 changed files with 182 additions and 4 deletions
+32
View File
@@ -0,0 +1,32 @@
import type { MetadataRoute } from "next";
export default function manifest(): MetadataRoute.Manifest {
return {
name: "NoWhatever — 别说随便",
short_name: "NoWhatever",
description: "像 Tinder 一样滑卡片,和朋友一起决定去哪吃!",
start_url: "/",
display: "standalone",
background_color: "#030712",
theme_color: "#10b981",
orientation: "portrait",
icons: [
{
src: "/icon-192x192.png",
sizes: "192x192",
type: "image/png",
},
{
src: "/icon-512x512.png",
sizes: "512x512",
type: "image/png",
},
{
src: "/icon-512x512.png",
sizes: "512x512",
type: "image/png",
purpose: "maskable",
},
],
};
}