Clean up bio and profiles#453
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the bio template to conditionally render the location and professional bio sections, ensuring they are hidden when data is missing. It also removes the website and email fields for the user jbampton. Feedback suggests simplifying the location display logic using the join filter and making the bio presence check more robust by using the trim filter to handle whitespace-only content.
| <div class="flex items-center gap-3"> | ||
| <span class="text-lg">📍</span> | ||
| <span class="text-[var(--text-muted)]">{{ location }}{% if country %}, {{ country }}{% endif %}</span> | ||
| <span class="text-[var(--text-muted)]">{{ location }}{% if location and country %}, {% endif %}{{ country }}</span> |
There was a problem hiding this comment.
The logic for displaying the location and country can be simplified and made more robust by using the join filter. This ensures that the comma and space are only added when both values are present, and it handles potential whitespace issues more cleanly if combined with trim.
<span class="text-[var(--text-muted)]">{{ [location, country] | select | join(', ') }}</span>
| </div> | ||
|
|
||
| <div class="lg:col-span-2 space-y-8"> | ||
| {% if bio %} |
No description provided.