From d19f2f9efae72214b1addf08ad895806e501fe27 Mon Sep 17 00:00:00 2001 From: TerryM Date: Sat, 30 May 2026 00:59:06 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=A7=BB=E9=99=A4=E3=80=8C=E5=85=B3?= =?UTF-8?q?=E4=BA=8E=E6=9C=AC=E7=AB=99=E3=80=8D=E6=8C=89=E9=92=AE=E4=B8=8E?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - PublicLayout: 删除桌面导航/下拉菜单/页脚三处入口及空页脚,移除 about 导航类型与判断 - App: 移除 /about 路由及 AboutPage 引入 - 删除 pages/About 页面 - DocumentMeta: 移除 /about 的 meta 处理与 about 描述文案(中/英) - i18n: 移除 aboutTitle / aboutIntro / footerAbout(中/英) Co-Authored-By: Claude Opus 4.8 (1M context) --- src/App.tsx | 2 -- src/components/DocumentMeta.tsx | 10 ---------- src/i18n.tsx | 8 -------- src/layouts/PublicLayout.tsx | 33 +-------------------------------- src/pages/About/index.tsx | 18 ------------------ 5 files changed, 1 insertion(+), 70 deletions(-) delete mode 100644 src/pages/About/index.tsx diff --git a/src/App.tsx b/src/App.tsx index dc69c41..ff79fed 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -11,7 +11,6 @@ import { OfficialRecommendationsPage } from "./pages/OfficialRecommendations"; import { SearchPage } from "./pages/Search"; import { PostRedirect } from "./pages/PostRedirect"; import { ScrollToTop } from "./components/ScrollToTop"; -import { AboutPage } from "./pages/About"; import Favorites from "./pages/Favorites"; import { adminUiPrefix } from "./adminPaths"; import { AdminRouteTree } from "./adminRouteTree"; @@ -46,7 +45,6 @@ export default function App() { /> } /> } /> - } /> } /> diff --git a/src/components/DocumentMeta.tsx b/src/components/DocumentMeta.tsx index bf2c859..fc459ae 100644 --- a/src/components/DocumentMeta.tsx +++ b/src/components/DocumentMeta.tsx @@ -15,7 +15,6 @@ const descriptions: Record> = { "按分类探索 ARK 官方资料,快速定位所需教材、公告、视频、图片与文件。", official: "查看 ARK 官方推荐资料,获取优先整理的重点内容与可信资源。", favorites: "收藏功能开发中,未来可在这里集中管理常用 ARK 资料。", - about: "了解 ARK 资料库的用途、资料范围与本站索引说明。", search: "在 ARK 资料库中搜索标题、分类、标签、简介、文件类型与正文内容。", }, en: { @@ -28,8 +27,6 @@ const descriptions: Record> = { "View official ARK recommendations and prioritized trusted resources.", favorites: "Favorites are in development and will help you manage commonly used ARK resources.", - about: - "Learn about the ARK Library purpose, resource scope, and indexing notes.", search: "Search ARK Library titles, categories, tags, summaries, file types, and body text.", }, @@ -136,13 +133,6 @@ function routeMeta( }; } - if (pathname === "/about") { - return { - title: t("footerAbout"), - description: metaDescription(lang, "about"), - }; - } - return { title: t("brand"), description: metaDescription(lang, "home") }; } diff --git a/src/i18n.tsx b/src/i18n.tsx index 72f1887..ca3b7d7 100644 --- a/src/i18n.tsx +++ b/src/i18n.tsx @@ -122,10 +122,6 @@ const zhDict: Dict = { resourceLangFilter: "资料语言", filterTagClear: "清除标签", filterLanguageAll: "全部语言", - aboutTitle: "关于本站", - aboutIntro: - "ARK 数据库汇总官方教材、公告、视频与常用文件,帮助社区快速获取一致版本的可信内容。\n\n本站仅供展示与索引;权利归属以官方公告为准。", - footerAbout: "关于本站", footerAdminLogin: "管理员登录", adminSearchLogs: "搜索记录", adminMetricShares: "分享", @@ -254,10 +250,6 @@ const enDict: Dict = { resourceLangFilter: "Resource language", filterTagClear: "Clear tag", filterLanguageAll: "All languages", - aboutTitle: "About this site", - aboutIntro: - "The ARK library brings together official decks, announcements, videos, and common files so the community can find consistent, trustworthy versions quickly.\n\nThis site is for discovery and indexing only; rights remain with official notices.", - footerAbout: "About", footerAdminLogin: "Admin sign-in", adminSearchLogs: "Search logs", adminMetricShares: "Shares", diff --git a/src/layouts/PublicLayout.tsx b/src/layouts/PublicLayout.tsx index 6b78a19..c48b6ca 100644 --- a/src/layouts/PublicLayout.tsx +++ b/src/layouts/PublicLayout.tsx @@ -17,8 +17,7 @@ type PublicNavWhich = | "browseLatest" | "browseRecommended" | "browsePopular" - | "favorites" - | "about"; + | "favorites"; function navIsActive( pathname: string, @@ -47,8 +46,6 @@ function navIsActive( return ( pathname === "/favorites" || (pathname === "/" && hash === "#favorites") ); - case "about": - return pathname === "/about"; default: return false; } @@ -477,13 +474,6 @@ export function PublicLayout() { > {t("favorites")} - - {t("footerAbout")} -
@@ -593,14 +583,6 @@ export function PublicLayout() { > {t("favorites")} - setOpen(false)} - > - {t("footerAbout")} -
) : null} @@ -637,19 +619,6 @@ export function PublicLayout() { -
-
- - {t("footerAbout")} - -
-
-