feat: improve app ui and project metadata
This commit is contained in:
@@ -8,8 +8,6 @@ import type { ActiveNav } from "./items";
|
||||
export interface AiToolItem {
|
||||
href: string;
|
||||
label: string;
|
||||
// 行首字形(纸感,非语义;aria-hidden 渲染)。
|
||||
glyph: string;
|
||||
// 高亮键(与 AppShell activeNav 比对)。
|
||||
key: ActiveNav;
|
||||
// 主动作(写本章)朱砂强调,其余次级。
|
||||
@@ -20,10 +18,18 @@ export interface AiToolItem {
|
||||
export function aiToolItems(projectId: string): AiToolItem[] {
|
||||
const base = `/projects/${projectId}`;
|
||||
return [
|
||||
{ href: `${base}/write`, label: "写本章", glyph: "✍", key: "write", primary: true },
|
||||
{ href: `${base}/review`, label: "审稿", glyph: "✦", key: "review" },
|
||||
{ href: `${base}/outline`, label: "大纲", glyph: "❡", key: "outline" },
|
||||
{ href: `${base}/codex`, label: "设定库", glyph: "❖", key: "codex" },
|
||||
{ href: `${base}/toolbox`, label: "工具箱", glyph: "✧", key: "toolbox" },
|
||||
{ href: `${base}/write`, label: "写本章", key: "write", primary: true },
|
||||
{ href: `${base}/review`, label: "审稿", key: "review" },
|
||||
{ href: `${base}/outline`, label: "大纲", key: "outline" },
|
||||
{ href: `${base}/codex`, label: "设定库", key: "codex" },
|
||||
{ href: `${base}/toolbox`, label: "工具箱", key: "toolbox" },
|
||||
];
|
||||
}
|
||||
|
||||
export function primaryAiToolItems(projectId: string): AiToolItem[] {
|
||||
return aiToolItems(projectId).slice(0, 2);
|
||||
}
|
||||
|
||||
export function secondaryAiToolItems(projectId: string): AiToolItem[] {
|
||||
return aiToolItems(projectId).slice(2);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user