esc_html__( 'Missing Subheadings', 'accessibility-checker' ),
'info_url' => 'https://a11ychecker.com/help1967',
'slug' => 'missing_headings',
'rule_type' => 'warning',
'summary' => sprintf(
// translators: %1$s is <h1>, %2$s is <h6>, %3$s is the word count threshold.
esc_html__( 'This page does not contain any heading elements between %1$s and %2$s in the main content area and has more than %3$s words.', 'accessibility-checker' ),
'<h1>',
'<h6>',
'400'
),
'summary_plural' => sprintf(
// translators: %1$s is <h1>, %2$s is <h6>, %3$s is '400' or the number defined in the setting.
esc_html__( 'These pages do not contain any heading elements between %1$s and %2$s in the main content area and have more than %3$s words.', 'accessibility-checker' ),
'<h1>',
'<h6>',
'400'
),
'why_it_matters' => esc_html__( 'Headings provide structure and make content easier for users of all abilities to scan. They also help screen reader users and keyboard-only users navigate the page. Without headings, users must read through content linearly without an easy way to jump between sections.', 'accessibility-checker' ),
'how_to_fix' => sprintf(
// translators: %1$s is <h1><h1>'
),
'references' => [
[
'text' => __( 'W3C Tutorial: Headings', 'accessibility-checker' ),
'url' => 'https://www.w3.org/WAI/tutorials/page-structure/headings/',
],
],
'viewable' => false,
'ruleset' => 'js',
'wcag' => '1.3.1',
'severity' => 3, // Medium.
'affected_disabilities' => [
AffectedDisabilities::BLIND,
AffectedDisabilities::LOW_VISION,
AffectedDisabilities::DEAFBLIND,
AffectedDisabilities::COGNITIVE,
AffectedDisabilities::MOBILITY,
],
];
}
}