From 96fd9d6b011864d40555b2b27ac047ef46484e23 Mon Sep 17 00:00:00 2001 From: MartinBraquet Date: Mon, 11 May 2026 12:59:29 +0200 Subject: [PATCH] Refactor profile header: enhance visibility notices with icons and styling; adjust layout for conditional rendering. --- web/components/profile/profile-header.tsx | 43 ++++++++++++++--------- web/components/profile/profile-info.tsx | 5 ++- 2 files changed, 30 insertions(+), 18 deletions(-) diff --git a/web/components/profile/profile-header.tsx b/web/components/profile/profile-header.tsx index 3b5f80ae..ce7f9a98 100644 --- a/web/components/profile/profile-header.tsx +++ b/web/components/profile/profile-header.tsx @@ -1,6 +1,7 @@ import { EllipsisHorizontalIcon, EyeIcon, + EyeSlashIcon, LockClosedIcon, PencilIcon, } from '@heroicons/react/24/outline' @@ -54,23 +55,25 @@ export default function ProfileHeader(props: { return ( - {currentUser && !isCurrentUser && isHiddenFromMe && ( -
- {t( - 'profile_grid.hidden_notice', - "You hid this person, so they don't appear in your search results.", - )} -
- )} - {currentUser && isCurrentUser && disabled && ( -
- {t( - 'profile.header.disabled_notice', - 'You disabled your profile, so no one else can access it.', - )} -
- )} + {currentUser && !isCurrentUser && isHiddenFromMe && ( +
+ + {t( + 'profile_grid.hidden_notice', + "You hid this person, so they don't appear in your search results.", + )} +
+ )} + {currentUser && isCurrentUser && disabled && ( +
+ + {t( + 'profile.header.disabled_notice', + 'You disabled your profile, so no one else can access it.', + )} +
+ )} {profile.pinned_url && (
@@ -85,7 +88,13 @@ export default function ProfileHeader(props: { />
)} - + diff --git a/web/components/profile/profile-info.tsx b/web/components/profile/profile-info.tsx index e4e903ef..020a0ad1 100644 --- a/web/components/profile/profile-info.tsx +++ b/web/components/profile/profile-info.tsx @@ -138,7 +138,10 @@ export function ProfileInfo(props: { {user.name?.charAt(0).toUpperCase()}