SIA-R73Paragraphs of text have sufficient line height

Accessibility requirements

This rule tests conformance of the following accessibility requirements:

Description

This rule checks that the line height in paragraphs of text is at least 1.5 times the font size.

Applicability

This rule applies to every element that has a semantic role of paragraph and is visible.

Expectations

  1. The element has a computed line-height of at least 1.5 times the computed font-size.

Assumptions

This rule makes the following assumptions:

Accessibility support

This rule has no known accessibility support concerns.

Examples

Passed

This paragraph of text has a line height of 1.5 and therefore passes the rule:

<style>
    p {
        line-height: 1.5;
    }
</style>

<p>
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas nec diam
    ullamcorper, cursus nulla non, congue purus. Cras vehicula risus lacus, ac
    placerat diam vestibulum a. Maecenas lobortis enim interdum nisl vehicula
    eleifend. Sed et velit nulla.
</p>

Failed

This paragraph of text has a line height of 1 and therefore fails the rule:

<style>
    p {
        line-height: 1;
    }
</style>

<p>
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas nec diam
    ullamcorper, cursus nulla non, congue purus. Cras vehicula risus lacus, ac
    placerat diam vestibulum a. Maecenas lobortis enim interdum nisl vehicula
    eleifend. Sed et velit nulla.
</p>

Inapplicable

This paragraph of text is hidden and is therefore inapplicable:

<p hidden>
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas nec diam
    ullamcorper, cursus nulla non, congue purus. Cras vehicula risus lacus, ac
    placerat diam vestibulum a. Maecenas lobortis enim interdum nisl vehicula
    eleifend. Sed et velit nulla.
</p>