Post

Fancy tooltips that use popover and anchor positioning are great. But sometimes all you need is a trustworthy title HTML attribute for a text-only tooltip. 😭 Only problem is: it can't be styled! Do you want these tooltips to be stylable? Maybe with a ::tooltip pseudo. Let me know your use cases!

I may be missing your point I think. My thinking is that it took long to convince (most, I hope?) devs to not use the attribute because the tooltip is not accessible to all users. Making it styleable is like signaling that the only usability issue was with the visual styling, if that makes sense.

Don't get me wrong: I would personally like to have the ability to style the title attribute. But even if I did, I'd rarely ever use it because I rarely ever use the title attribute (only to provide a name to <iframe>s)

If I could snap my fingers and change it overnight, I'd alias it to a popover, with proper keyboard handling and focus baked in. It would wreck iframe backwards compat, but maybe you just can't give an iframe a tooltip or the like.

Here's an article by @scottohara.me that sums up the most important things to know about the title attribute a11y: www.24a11y.com/2017/the-tri... — I pulled this from my course as it's one of the recommended resources I list in the accName computation chapter.

24a11y.comThe Trials and Tribulations of the Title Attribute - 24 AccessibilityScott O’Hara returns, examining the accessibility pitfalls of HTML’s title attribute, its inconsistent support & when it should & shouldn’t be used.

Due to SEO abuse of the title attribute some screen readers ignore it or can be configured to ignore it. So it’s a bit of an unreliable utility. But that could change if it’s actually useful?

Maybe? The accName problem is roughly: - People use title to create a tooltip. - That tooltip can be supplementary content to the control’s accessible name. - title can override the intended accName. - This is confusing for both screen reader and voice control users.