mirror of
https://gitee.com/spark-store-project/spark-store
synced 2026-08-10 06:14:07 +08:00
refactor(sidebar): 优化侧边栏加载逻辑,支持按来源仓库过滤请求
1. 新增SidebarEntry的origins字段标记入口所属仓库 2. 合并多仓库共享的侧边栏入口配置 3. 仅向实际存在的仓库发起分类和应用加载请求,减少无效404请求 4. 并行加载分类数据避免串行等待,调整预加载顺序优化网络资源占用
This commit is contained in:
@@ -243,6 +243,8 @@ export interface SidebarEntry {
|
||||
icon?: string;
|
||||
type?: "category" | "search" | "link" | "homeList";
|
||||
value?: string;
|
||||
/** 哪些来源仓库(spark / apm)包含此入口,用于避免对不存在的仓库发起无效请求 */
|
||||
origins?: Array<"spark" | "apm">;
|
||||
}
|
||||
|
||||
export interface SparkUser {
|
||||
|
||||
Reference in New Issue
Block a user