aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/packages/ui/src/components/sidebar.tsx
diff options
context:
space:
mode:
authorNtskwK <natsukawa247@outlook.com>2026-03-30 17:28:40 +0800
committerNtskwK <natsukawa247@outlook.com>2026-03-30 17:28:40 +0800
commit0c689afe68792fafca67746b9ece2a06760c6069 (patch)
tree8d0feac4fec8c8ac06994f28949915d348eb3cc9 /packages/ui/src/components/sidebar.tsx
parent382dfc68f1ecb09f277f82b0b2e0b466e1c79d06 (diff)
parentc4dc0676d794bca2613be282867d369328ebf073 (diff)
downloadDropOut-0c689afe68792fafca67746b9ece2a06760c6069.tar.gz
DropOut-0c689afe68792fafca67746b9ece2a06760c6069.zip
Merge branch 'main' of https://github.com/HydroRoll-Team/DropOut into chore/docs
Diffstat (limited to 'packages/ui/src/components/sidebar.tsx')
-rw-r--r--packages/ui/src/components/sidebar.tsx12
1 files changed, 6 insertions, 6 deletions
diff --git a/packages/ui/src/components/sidebar.tsx b/packages/ui/src/components/sidebar.tsx
index d81156f..e615274 100644
--- a/packages/ui/src/components/sidebar.tsx
+++ b/packages/ui/src/components/sidebar.tsx
@@ -23,10 +23,6 @@ function NavItem({ Icon, label, to }: NavItemProps) {
const location = useLocation();
const isActive = location.pathname === to;
- const handleClick = () => {
- navigate(to);
- };
-
return (
<Button
variant="ghost"
@@ -35,7 +31,7 @@ function NavItem({ Icon, label, to }: NavItemProps) {
isActive && "relative bg-accent",
)}
size="lg"
- onClick={handleClick}
+ onClick={() => navigate(to)}
>
<Icon className="size-5" strokeWidth={isActive ? 2.5 : 2} />
<span className="hidden lg:block text-sm relative z-10">{label}</span>
@@ -185,7 +181,11 @@ export function Sidebar() {
<div className="w-full lg:px-3 flex-1 flex flex-col justify-end">
<DropdownMenu>
- <DropdownMenuTrigger render={renderUserAvatar()} className="w-full">
+ <DropdownMenuTrigger
+ render={renderUserAvatar()}
+ nativeButton={false}
+ className="w-full"
+ >
Open
</DropdownMenuTrigger>
<DropdownMenuContent align="end" side="right" sideOffset={20}>