Inappropriate Font Size Check
Description
The “Inappropriate Font Size Check” evaluates whether there is any CSS declaration where an absolute unit (like px, pt, cm, or in) are used to set font sizes.
Example outcome
I identified 1 instance where the font size is expressed in absolute measurement units.
Impact
- Visual Impairments: Users with visual impairments may need to increase text size to read comfortably. Absolute units don’t scale well with browser zoom or user stylesheets.
- Cognitive Disabilities: Being unable to enlarge text means reduced readability, especially when line spacing, font style, and size are not adaptable, presenting challenges for users with cognitive disabilities.
- Elderly: Age-related vision issues often require larger or adjustable text. Absolute units restrict user control.
Fixes
To address inappropriate font size declarations:
- Locate the CSS code where the font size is expressed using absolute units.
- Replace the absolute units by either relative units (e.g.,
em,rem, or%) or viewport-based units (e.g.,vw,vh)