Accordion focus state in Windows High Contrast Mode has an overhanging border #2354
Labels
accessibility
accordion
🐛 bug
Something isn't working the way it should (including incorrect wording in documentation)
What
This is a fairly minor issue but there's an odd looking overhanging right border on the new accordion focus state in Windows High Contrast mode, see below:
This appears to be caused by the pseudo element fix that is there to limit the width of the focus state to the width of its contents (it was originally introduced to fix an issue in NVDA but I think we found in later testing that it might not be necessary for NVDA, only to make the focus state work - we should clarify this in the code comments to be clear why the fix is there).
This is what I suspect anyway because it seems to happen to all the elements that are followed by an element with the above mentioned
:before
, as is the case here where I duplicated the "Show" element - the first "Show" now has the overhanging border which the last one (the same element) still doesn't have:If you manipulate the positioning in the pseudo elements so that the elements flow to one line, you can see the overhanging border is created by overlapping borders.
Why
The actual Windows High Contrast Mode bug is a minor issue but it could be indicative of other issues we haven't discovered around the pseudo element fix.
Who needs to know about this
Developers
Done when
<span>
we need to add inside of them so that we can set the width of the focus state only to span the width of the text.The text was updated successfully, but these errors were encountered: