Gate workspace_update emissions to prevent unnecessary sidebar re-renders
Server: remove activityAt computation from workspace descriptors (always sends null for backwards compat) and deduplicate emissions in emitWorkspaceUpdatesForWorkspaceIds using fast-deep-equal — workspace updates are now only sent when the descriptor actually changed. Client: remove activityAt from WorkspaceDescriptor, sidebar entry types, and baseline sort comparators. Workspace/project ordering is fully handled by the persisted sidebar order store.
This commit is contained in:
@@ -13,7 +13,6 @@ function workspace(serverId: string, cwd: string): SidebarWorkspaceEntry {
|
||||
workspaceId: cwd,
|
||||
workspaceKind: "local_checkout",
|
||||
name: cwd,
|
||||
activityAt: null,
|
||||
statusBucket: "done",
|
||||
diffStat: null,
|
||||
};
|
||||
@@ -28,7 +27,6 @@ function project(projectKey: string, workspaces: SidebarWorkspaceEntry[]): Sideb
|
||||
statusBucket: "done",
|
||||
activeCount: 0,
|
||||
totalWorkspaces: workspaces.length,
|
||||
latestActivityAt: null,
|
||||
workspaces,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user