Fix: Improve location text alignment on profile page#465
Fix: Improve location text alignment on profile page#465AyushAgrawal18 wants to merge 2 commits intoNextCommunity:mainfrom
Conversation
|
Hi, I’ve submitted a PR for this issue. Please review. |
There was a problem hiding this comment.
Code Review
This pull request modifies the layout of the location section in the bio component, changing it from left-aligned to right-aligned and reducing the gap between the icon and text. The review feedback points out that these changes introduce visual inconsistencies with the rest of the sidebar and suggests using 'items-start' with the original gap size to better handle text wrapping while maintaining a uniform design.
| <div class="space-y-4 text-sm border-t border-[var(--border-color)] pt-6"> | ||
| {% if location or country %} | ||
| <div class="flex items-center gap-3"> | ||
| <div class="flex justify-end gap-2 text-right"> |
There was a problem hiding this comment.
The change to justify-end and text-right introduces a layout inconsistency with the Email and Website sections (lines 33 and 41), which are left-aligned. Additionally, the reduction of gap-3 to gap-2 breaks the uniform spacing used throughout the sidebar.
To address the wrapping issue mentioned in the PR description while maintaining UI consistency, it is recommended to use items-start instead of items-center. This ensures the icon remains aligned with the first line of text when the location name wraps, without breaking the left-aligned vertical rhythm of the profile card.
<div class="flex items-start gap-3">
There was a problem hiding this comment.
Pull request overview
Improves the visual alignment of the location/country line on user profile pages by updating the layout classes in the profile bio include.
Changes:
- Adjusted the location row to right-align its content (
justify-end,text-right) and tweaked spacing (gap-2). - Updated the flex row styling to better handle alignment when location text is long.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <div class="flex justify-end gap-2 text-right"> | ||
| <span class="text-lg">📍</span> | ||
| <span class="text-[var(--text-muted)]">{{ location }}{% if location and country %}, {% endif %}{{ country }}</span> |
Fix
Improved alignment of location text on profile pages.
Changes
Testing