Skip to content

Commit f756913

Browse files
committed
refactor(web): focus workspace navigation
1 parent ffa4428 commit f756913

6 files changed

Lines changed: 168 additions & 239 deletions

File tree

‎apps/web/src/components/Sidebar.logic.test.ts‎

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -442,10 +442,6 @@ describe("shouldCreateNewThreadInCurrentProject", () => {
442442
expect(shouldCreateNewThreadInCurrentProject(false, 2)).toBe(false);
443443
});
444444

445-
it("creates directly when the sidebar is scoped to a project", () => {
446-
expect(shouldCreateNewThreadInCurrentProject(false, 2, true)).toBe(true);
447-
});
448-
449445
it("creates directly on any click with a single project", () => {
450446
expect(shouldCreateNewThreadInCurrentProject(false, 1)).toBe(true);
451447
expect(shouldCreateNewThreadInCurrentProject(true, 1)).toBe(true);

‎apps/web/src/components/Sidebar.logic.ts‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,9 +299,8 @@ export function isSidebarNestedLinkClick(target: EventTarget | null): boolean {
299299
export function shouldCreateNewThreadInCurrentProject(
300300
shiftKey: boolean,
301301
projectGroupCount: number,
302-
hasProjectScope = false,
303302
): boolean {
304-
return hasProjectScope || shiftKey || projectGroupCount <= 1;
303+
return shiftKey || projectGroupCount <= 1;
305304
}
306305

307306
export function orderItemsByPreferredIds<TItem, TId>(input: {

0 commit comments

Comments
 (0)