perf(dashboard): 仪表盘加载提速

- models-dev 快照移出主 bundle(1.35MB→515KB),改为 /models-dev.json 运行时异步加载,就绪后重渲染
- Rust 启动时后台预热价格索引(warm_price_index),首次 get_summary 不再卡
- get_summary 扫描结果 8s TTL 缓存(按 home),切 tab/改范围复用;刷新按钮 refresh=true 强制重扫
This commit is contained in:
KimiSwitch Dev committed 2026-08-01 19:37:20 +08:00
1 parent 9fd22ef55a
commit 1fecb161a9
7 files changed
+64112 -23

No files matched your search

+2 -2
View File
@@ -71,7 +71,7 @@ export function DashboardPage() {
<div className="text-red-400 mb-2">{t("dashLoadFailed")}</div>
<div className="text-sm text-content-muted">{error}</div>
<button
onClick={() => refresh()}
onClick={() => refresh(true)}
className="mt-4 px-4 py-2 rounded bg-blue-600 hover:bg-blue-700 text-white text-sm"
>
{t("retry")}
@@ -145,7 +145,7 @@ export function DashboardPage() {
</div>
<button
type="button"
onClick={() => refresh()}
onClick={() => refresh(true)}
disabled={loading}
className="px-3 py-1.5 text-sm border border-border rounded hover:bg-hover-2 text-content-muted hover:text-content-primary disabled:opacity-50"
>