torchbox / torchbox/django-pattern-library
Accessibility issue: Heading levels should only increase by one on /django-pattern-library/demo/render-pattern/patterns_jinja/pages/test_page/test_page.html
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 423
- Forks
- 53
- PR merge metrics
- No merged PRs in 30d
Description
[!NOTE]
This is a best-practice recommendation, not a definite WCAG failure.
What
An accessibility scan flagged an element on https://torchbox.github.io/django-pattern-library/demo/render-pattern/patterns_jinja/pages/test_page/test_page.html because heading levels should only increase by one. Learn more about why this was flagged by visiting https://dequeuniversity.com/rules/axe/4.11/heading-order?application=playwright.
The following element needs attention:
<h3 class="accordion__title heading heading--4">(selector:.accordion__panel[data-accordion-panel=""]:nth-child(1) > h3)
To fix this, ensure the order of headings is semantically correct.
Specifically:
Fix any of the following:
- Heading order invalid
Acceptance Criteria
- The specific violation reported in this issue is no longer reproducible.
- The fix MUST meet the accessibility standards specified by the repository or organization (WCAG 2.2 if applicable).
- A test SHOULD be added to ensure this specific violation does not regress.
- This PR MUST NOT introduce any new accessibility issues or regressions.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the rendered test page at the issue URL and inspect the .accordion__panel[data-accordion-panel=""]:nth-child(1) > h3 element, then trace it to the source template for test_page. Correct the heading order without introducing new accessibility issues, and rerun the repository's Playwright accessibility scan to confirm the violation is gone; add a regression test if the existing test setup supports it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- django
- Domain
- accessibility, frontend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100