Skip to content

Conversation

@TianyangRen
Copy link
Contributor

Fixes #495

Description

Fixed the row height inconsistency on the friends page where the current user's row was shorter than other rows.

Changes

  • Added a hidden "Unfriend" button for the current user's row to maintain consistent height with other rows
  • The button uses visibility: "hidden" and aria-hidden="true" for accessibility

@vercel
Copy link

vercel bot commented Dec 18, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
testaustime Ready Ready Preview, Comment Dec 18, 2025 9:06pm
testaustime-storybook Ready Ready Preview, Comment Dec 18, 2025 9:06pm

</TableTd>
<TableTd style={{ textAlign: "right", padding: "7px 0px" }}>
{!isMe && (
{isMe ? (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this condition could be removed/the buttons could be combined, and then add style={{visibility: isMe ? "hidden" : undefined}} and aria-hidden={isMe ? "true" : undefined}. That way we don't need to duplicate the variant and size and text

</TableTd>
<TableTd style={{ textAlign: "right", padding: "7px 0px" }}>
{!isMe && (
{isMe ? (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And also could add a comment for future reference, explaining why it was made like this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And also could add a comment for future reference, explaining why it was made like this

Combined into one button and added a brief comment explaining the hidden state keeps row height consistent for the current user. Deletion behavior unchanged for other users.

@Eldemarkki Eldemarkki merged commit fe88a7a into Testaustime:main Dec 18, 2025
6 checks passed
@Eldemarkki
Copy link
Member

Thank you for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Your row on friends page is shorter than other rows

2 participants