This commit is contained in:
Li1304553726 2025-07-01 09:03:49 +08:00
parent 271f2e081e
commit da7d02fd11
3 changed files with 17 additions and 1 deletions

View File

@ -0,0 +1,3 @@
export default function HeaderPage() {
return <>header</>
}

View File

@ -4,6 +4,7 @@ import React, { useMemo } from "react";
import {
CommentOutlined,
FileSearchOutlined,
FireOutlined,
FormOutlined,
InboxOutlined,
MailOutlined,
@ -55,6 +56,11 @@ export function useNavItem() {
label: "心理锦囊",
icon: <CommentOutlined className="text-base" />,
},
header: {
to: env.LIB_URL || "https://27.57.72.21",
label: "南天烽火",
icon: <FireOutlined className="text-base" />,
},
};
// 按照指定顺序返回导航项
return [
@ -63,6 +69,7 @@ export function useNavItem() {
staticItems.letterProgress,
staticItems.letterList,
staticItems.help,
staticItems.header,
].filter(Boolean);
}, [data, user]);

View File

@ -18,6 +18,8 @@ import NewsEditorPage from "../app/main/help/news/page";
import ScienceEditorPage from "../app/main/help/science/page";
import ExampleEditorPage from "../app/main/help/example/page";
import { NewsCard } from "../app/main/help/news/NewsCard";
import WithAuth from "../components/utils/with-auth";
import HeaderPage from "../components/layout/main/HeaderPage";
export const routes: CustomRouteObject[] = [
{
path: "/",
@ -85,7 +87,11 @@ export const routes: CustomRouteObject[] = [
{
path: "submission-success",
element: <SubmissionSuccess></SubmissionSuccess>,
}
},
{
path: "header",
element: <HeaderPage></HeaderPage>,
},
],
},
adminRoute,