Improve workspace navigation and render isolation
This commit is contained in:
@@ -55,13 +55,12 @@ describe("buildSidebarProjectRowModel", () => {
|
||||
expect(result).toEqual({
|
||||
kind: "workspace_link",
|
||||
workspace: flattenedWorkspace,
|
||||
selected: false,
|
||||
chevron: null,
|
||||
trailingAction: "none",
|
||||
});
|
||||
});
|
||||
|
||||
it("marks flattened non-git project rows as selected when their workspace is active", () => {
|
||||
it("builds flattened non-git rows without route selection input", () => {
|
||||
const flattenedWorkspace = workspace({
|
||||
serverId: "srv-2",
|
||||
workspaceId: "ws-non-git",
|
||||
@@ -73,17 +72,15 @@ describe("buildSidebarProjectRowModel", () => {
|
||||
workspaces: [flattenedWorkspace],
|
||||
}),
|
||||
collapsed: false,
|
||||
serverId: "srv-2",
|
||||
activeWorkspaceSelection: {
|
||||
serverId: "srv-2",
|
||||
workspaceId: "ws-non-git",
|
||||
},
|
||||
});
|
||||
|
||||
expect(result).toMatchObject({
|
||||
kind: "workspace_link",
|
||||
selected: true,
|
||||
workspace: flattenedWorkspace,
|
||||
chevron: null,
|
||||
trailingAction: "none",
|
||||
});
|
||||
expect(result).not.toHaveProperty("selected");
|
||||
});
|
||||
|
||||
it("keeps single-workspace git projects as sections with the new worktree action", () => {
|
||||
|
||||
Reference in New Issue
Block a user