The letter avatar placeholder is rendered as nested divs, which is
invalid inside phrasing contexts such as the paragraph on the group
view page. Browsers eject the placeholder from the paragraph while
parsing, so the DOM no longer matches the markup, and validators
reject the page. Render the placeholder as spans instead; all of its
styling addresses the classes and sets explicit display values, and
as a flex item the initials element is blockified either way, so the
rendering is unchanged.
The functional test framework reads the logged in username from the
first span inside the header profile link that is not the avatar, so
the placeholder span must be excluded there as well.
PHPBB-17646
Checklist:
Tracker ticket:
https://tracker.phpbb.com/browse/PHPBB-17646
The markup reported in the ticket, with the placeholder inside <span class="avatar">, cannot be produced by current core, as that span only ever wraps image avatars. The real instance is the group view page, where the placeholder divs render inside a paragraph. Browsers eject the invalid divs from the paragraph while parsing, so the DOM no longer matches the delivered markup and validators reject the page.
The placeholder now renders as spans. Its styling addresses the classes with explicit display values and the initials element keeps its layout as a flex item, so rendering is identical everywhere. Verified on a live board, including the avatar cropper page where the show and hide cycle still restores the flex display.