From 9b7758da996e2d92e8fc40da998f23edea082005 Mon Sep 17 00:00:00 2001 From: gosangam Date: Sat, 8 Aug 2026 00:12:34 +0530 Subject: [PATCH] fix: profile bio --- components/profile/profile-header.tsx | 141 ++++++++++++++------------ 1 file changed, 77 insertions(+), 64 deletions(-) diff --git a/components/profile/profile-header.tsx b/components/profile/profile-header.tsx index d55d8568..8c0f99a6 100644 --- a/components/profile/profile-header.tsx +++ b/components/profile/profile-header.tsx @@ -1,9 +1,14 @@ "use client"; /** - * ProfileHeader — Instagram-style centered header used at the top of - * /u/me and /u/[handle]. Avatar, display name, @handle, a single stat - * line, and an action row. + * ProfileHeader — the header at the top of /u/me and /u/[handle]. + * + * Layout is two stacked blocks: + * 1. An identity ROW — avatar on the left, with display name, @handle, and + * the posts/followers/following stat line stacked to its right. + * 2. Full-width rows beneath it — the bio, then the action row. Both span the + * avatar's width too, so a 200-character bio gets the whole column rather + * than the narrow gutter beside the avatar. * * The action row hosts: * • "Edit profile" link — only on the owner's own profile (via the @@ -122,61 +127,80 @@ export function ProfileHeader({ return ( <> -
- {/* Avatar, with Śrīla Prabhupāda's portrait tucked into the lower-right - for his direct disciples (verification-tick placement). */} -
- setZoomOpen(true) : undefined} - ariaLabel={`View ${name}'s profile picture`} - /> - {isDirectDisciple ? ( - - ) : null} -
-
-
-

- {name} -

-

@{handle}

+
+ {/* Identity row — avatar on the left, name + handle + stats stacked to + its right. The bio and action row sit below at full width, so long + prose gets the whole column instead of a narrow gutter. */} +
+ {/* Avatar, with Śrīla Prabhupāda's portrait tucked into the + lower-right for his direct disciples (verification-tick + placement). */} +
+ setZoomOpen(true) : undefined} + ariaLabel={`View ${name}'s profile picture`} + /> + {isDirectDisciple ? ( + + ) : null}
- {/* Stat line: posts · followers · following */} -
- {typeof postCount === "number" ? ( - - ) : null} - {showCounts ? ( - <> - setFollowList("followers") - : undefined - } - /> - setFollowList("following") - : undefined - } - /> - - ) : null} + {/* min-w-0 lets the long-name truncation actually kick in — without + it the flex child refuses to shrink below its content width. */} +
+

+ {name} +

+

+ @{handle} +

+ + {/* Stat line: posts · followers · following */} +
+ {typeof postCount === "number" ? ( + + ) : null} + {showCounts ? ( + <> + setFollowList("followers") + : undefined + } + /> + setFollowList("following") + : undefined + } + /> + + ) : null} +
+ {/* Bio — spans the full column beneath the avatar AND the name/stats + block, so a 200-character bio wraps across the whole width instead + of being squeezed into the column beside the avatar. */} + {bio?.trim() ? ( + + ) : null} + {showOwnerControls ? (
) : null} - - {/* Bio — left-aligned across the full column, unlike the centred - identity block above it. Prose reads badly centred once it wraps - past one line, and `self-stretch` overrides the header's - `items-center` so it spans edge to edge. */} - {bio?.trim() ? ( - - ) : null}
{avatarURL ? (