Skip to content

Commit 3135251

Browse files
author
Marvin Zhang
committed
fix: Update project navigation to use window.location.assign for better state management; improve CommandItem cursor style
1 parent d6933b2 commit 3135251

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/ui/src/components/project-switcher.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ export function ProjectSwitcher({ collapsed }: ProjectSwitcherProps) {
8282
}
8383

8484
// Full page navigation - ensures clean state for new project
85-
window.location.href = `/projects/${projectId}${subPath}`;
85+
window.location.assign(`/projects/${projectId}${subPath}`);
8686
};
8787

8888
const sortedProjects = [...projects].sort((a, b) => {

packages/ui/src/components/ui/command.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ const CommandItem = React.forwardRef<
115115
<CommandPrimitive.Item
116116
ref={ref}
117117
className={cn(
118-
"relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
118+
"relative flex cursor-pointer gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
119119
className
120120
)}
121121
{...props}

0 commit comments

Comments
 (0)