fix: align role period text to end in experience item (#2876) (#2908)

When an experience entry has multiple roles (Role Progression),
the period/date for each role was left-aligned in the grid layout,
causing it to appear off-center instead of right-aligned under the
location field.

Added `text-end` class to the role period element to match the
alignment behavior of the single-role header period. Uses `text-end`
instead of `text-right` for proper RTL language support.
This commit is contained in:
JamesGoslings
2026-04-25 15:43:31 +08:00
committed by GitHub
parent 2d2d5cd505
commit ff3d4b1337
@@ -70,7 +70,7 @@ export function ExperienceItem({ className, ...item }: ExperienceItemProps) {
<div key={role.id} className="experience-item-role">
<div className="grid grid-cols-2 items-start justify-between gap-x-2">
<div className="section-item-metadata experience-item-role-position">{role.position}</div>
<div className="section-item-metadata experience-item-role-period">{role.period}</div>
<div className="section-item-metadata experience-item-role-period text-end">{role.period}</div>
</div>
{stripHtml(role.description) && (