From 8abcf0235a5bfb8c108ed9e13a1ba393941616de Mon Sep 17 00:00:00 2001 From: haorwen Date: Mon, 22 Jun 2026 11:00:09 +0800 Subject: [PATCH] feat: navigate to home page when clicking server avatar --- src/components/Server.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/Server.tsx b/src/components/Server.tsx index 4062c73d..0844e2cf 100644 --- a/src/components/Server.tsx +++ b/src/components/Server.tsx @@ -1,5 +1,5 @@ import { useTranslation } from "react-i18next"; -import { NavLink, useLocation } from "react-router-dom"; +import { NavLink } from "react-router-dom"; import Tippy from "@tippyjs/react"; import { useAppSelector } from "@/app/store"; @@ -13,7 +13,6 @@ type Props = { }; export default function Server({ readonly = false }: Props) { const { t } = useTranslation(); - const { pathname } = useLocation(); const { name, description, logo } = useAppSelector((store) => store.server, shallowEqual); const userCount = useAppSelector((store) => store.users.ids.length, shallowEqual); // console.log("server info", server); @@ -42,7 +41,7 @@ export default function Server({ readonly = false }: Props) { return (
- +