You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The htmx-indicator default styles rely on opacity only. Because of this, indicator elements are only visually hidden. It still appears in the accessibility tree for screen reader users. And for hover / focus if that indicator was interactive.
Here’s a recording of VoiceOver macOS in Safari demonstrating the issue on the Cascading Selects example (though note due to the demo site’s "instant" server responses, the indicator is effectively useless there).
hx-indicator.opacity.mp4
The best fix is probably to either add, or switch to the visibility property, which preserves layout like opacity but also removes elements from the accessibility tree.
Additionally, worth noting those <img> elements are missing an alt attribute. That attribute is never optional, and will make it so screen reader users aren’t told the image’s file name or URL, which is pretty meaningless to them (related: #1431).
The htmx-indicator default styles rely on
opacityonly. Because of this, indicator elements are only visually hidden. It still appears in the accessibility tree for screen reader users. And for hover / focus if that indicator was interactive.Here’s a recording of VoiceOver macOS in Safari demonstrating the issue on the Cascading Selects example (though note due to the demo site’s "instant" server responses, the indicator is effectively useless there).
hx-indicator.opacity.mp4
The best fix is probably to either add, or switch to the visibility property, which preserves layout like
opacitybut also removes elements from the accessibility tree.Additionally, worth noting those
<img>elements are missing analtattribute. That attribute is never optional, and will make it so screen reader users aren’t told the image’s file name or URL, which is pretty meaningless to them (related: #1431).