These docs are for CORA 0.10, an older release. Read this page in the newest docs.
Blinking text needs a way to stop
- Rule:
axe/blink - Checks: <blink> elements are deprecated and must not be used
- WCAG: 2.2.2
- Fix class:
mechanical: A fix needs no authored text or visual decision.
Who it affects
Section titled “Who it affects”- People whom moving, blinking or flashing content distracts, disorients or harms.
- People with cognitive, learning or attention disabilities.
How to fix it
Section titled “How to fix it”The page uses a <blink> element
Section titled “The page uses a <blink> element”Replace it with static emphasis: <strong> for importance, or a class that styles the text. <blink> is obsolete and gives people no built-in way to stop it.
<p><strong>Sale ends Friday.</strong></p>The text still needs to draw attention
Section titled “The text still needs to draw attention”Use color, weight, an icon or placement rather than motion. If it must animate, never let it flash more than three times a second, stop it within five seconds or give people a visible control that pauses it, and keep it still under prefers-reduced-motion: reduce.
Fixes that fail
Section titled “Fixes that fail”Recreating the blink with a CSS animation or script that never stops
Section titled “Recreating the blink with a CSS animation or script that never stops”The rule passes because the element is gone, but text that blinks for more than five seconds with no way to pause, stop or hide it still fails WCAG 2.2.2.
More on the rule
Section titled “More on the rule”axe-core’s documentation of the rule
CORA’s fix guidance adapts content from accessibility-agents, under the MIT License: see its notice.