From 59ba7c37e2d7cedec41739d1d999a420e2bf108a Mon Sep 17 00:00:00 2001 From: bufan Date: Fri, 15 Mar 2024 18:21:55 +0800 Subject: [PATCH] fix mobile header style --- apps/u3/src/container/fav/FavMobileHeader.tsx | 6 +++++- .../notification/NotificationMobileHeader.tsx | 6 +++++- .../src/container/profile/ProfileLayout.tsx | 2 +- apps/u3/src/container/profile/ProfileMenu.tsx | 15 +------------ .../container/profile/ProfileMobileHeader.tsx | 21 +++++++------------ 5 files changed, 19 insertions(+), 31 deletions(-) diff --git a/apps/u3/src/container/fav/FavMobileHeader.tsx b/apps/u3/src/container/fav/FavMobileHeader.tsx index dbb2c1f9..8318598f 100644 --- a/apps/u3/src/container/fav/FavMobileHeader.tsx +++ b/apps/u3/src/container/fav/FavMobileHeader.tsx @@ -8,12 +8,16 @@ import { ComponentPropsWithRef } from 'react'; import { MobileHeaderWrapper } from '@/components/layout/mobile/MobileHeaderCommon'; import LoginButtonV2Mobile from '@/components/layout/LoginButtonV2Mobile'; +import SearchIconBtn from '@/components/layout/SearchIconBtn'; export default function FavMobileHeader(props: ComponentPropsWithRef<'div'>) { return (
My Favorites
- +
+ + +
); } diff --git a/apps/u3/src/container/notification/NotificationMobileHeader.tsx b/apps/u3/src/container/notification/NotificationMobileHeader.tsx index f434cb64..693001e0 100644 --- a/apps/u3/src/container/notification/NotificationMobileHeader.tsx +++ b/apps/u3/src/container/notification/NotificationMobileHeader.tsx @@ -8,12 +8,16 @@ import { ComponentPropsWithRef } from 'react'; import { MobileHeaderWrapper } from '@/components/layout/mobile/MobileHeaderCommon'; import LoginButtonV2Mobile from '@/components/layout/LoginButtonV2Mobile'; +import SearchIconBtn from '@/components/layout/SearchIconBtn'; export default function FavMobileHeader(props: ComponentPropsWithRef<'div'>) { return (
Notifications
- +
+ + +
); } diff --git a/apps/u3/src/container/profile/ProfileLayout.tsx b/apps/u3/src/container/profile/ProfileLayout.tsx index 32c16733..bea296e0 100644 --- a/apps/u3/src/container/profile/ProfileLayout.tsx +++ b/apps/u3/src/container/profile/ProfileLayout.tsx @@ -85,7 +85,7 @@ export default function ProfileLayout() { {/* Desktop */}
- +
{ - isSelf: boolean; -} - export default function ProfileMenu({ - isSelf, className, ...props -}: ProfileMenuProps) { +}: ComponentPropsWithRef<'div'>) { const { user } = useParams(); const { pathname } = useLocation(); const pathSuffix = user ? `/${user}` : ''; @@ -48,14 +43,6 @@ export default function ProfileMenu({ > Activity - {isSelf && ( - - Favorites - - )} {/* ) { - const { pathname } = useLocation(); - const { user } = useParams(); - // const isPostsPath = pathname === '/u'; - // const isContactsPath = pathname === '/u/contacts'; - // const isActivityPath = pathname === '/u/activity'; - const isFavPath = pathname === '/u/fav'; - return ( - {(() => { - if (isFavPath) { - return ; - } - return ; - })()} + ; +
+ + +
); }