feat: AI分析单页展示 + 主题切换 + 移动端适配

- AI分析页改为直接展示最新报告,历史存数据库
- 新增浅色/深色/系统自动主题切换
- 市场看板、AI分析页适配主题变量
- 移动端表格可滑动、按钮自动换行
- Mermaid图表支持
- Markdown表格渲染支持(remark-gfm)
This commit is contained in:
Sakurasan
2026-09-01 12:33:27 +08:00
parent 912a224b6b
commit 6478e0d403
16 changed files with 614 additions and 407 deletions
+7
View File
@@ -17,6 +17,13 @@ export interface AiReport {
created_at: string;
}
export async function fetchAiLatestReport(): Promise<AiReport> {
const resp = await fetch(`${API_BASE}/api/ai-analysis/latest`);
if (!resp.ok) throw new Error(`请求失败 (${resp.status})`);
const result = await resp.json();
return result.data;
}
export async function fetchAiReports(): Promise<AiReport[]> {
const resp = await fetch(`${API_BASE}/api/ai-analysis`);
if (!resp.ok) throw new Error(`请求失败 (${resp.status})`);