Skip to content

Fix SPA heading hierarchy in generated workshop docs#1803

Merged
pelikhan merged 2 commits into
mainfrom
copilot/workshop-playwright-qa-fix-accessibility-headings
Jul 21, 2026
Merged

Fix SPA heading hierarchy in generated workshop docs#1803
pelikhan merged 2 commits into
mainfrom
copilot/workshop-playwright-qa-fix-accessibility-headings

Conversation

Copilot AI commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

The workshop single-page renderer emitted every step title as an <h1>, producing 84 top-level headings in one document and breaking the accessibility heading structure. This change reserves <h1> for the overall workshop title and demotes per-step titles to section headings.

  • Renderer output

    • Change each rendered workshop step title from <h1> to <h2> in scripts/build-docs.js
    • Keep the existing per-step structure and IDs intact so hash navigation and styling continue to work
  • Document-level heading

    • Promote the persistent workshop title in the SPA header to the single document <h1>
    • Update the header markup/CSS to preserve the existing visual treatment with the new <h1><a> structure
  • Regression coverage

    • Add a focused build-output test for the generated SPA to assert:
      • exactly one <h1>
      • no step titles rendered as <h1>
      • step titles rendered as <h2>
<header class="site-header">
  <h1 class="site-title">
    <a href="#00-welcome">GitHub Agentic Workflows Workshop</a>
  </h1>
</header>

<details id="07-your-first-workflow">
  <summary>Your first workflow</summary>
  <h2 id="07-your-first-workflow-title" class="workshop-page-title">
    Your first workflow
  </h2>
</details>

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix accessibility issue by changing excessive h1 elements Fix SPA heading hierarchy in generated workshop docs Jul 21, 2026
Copilot AI requested a review from pelikhan July 21, 2026 11:15
@pelikhan
pelikhan marked this pull request as ready for review July 21, 2026 11:18
@pelikhan
pelikhan merged commit 34f99ec into main Jul 21, 2026
12 checks passed
@pelikhan
pelikhan deleted the copilot/workshop-playwright-qa-fix-accessibility-headings branch July 21, 2026 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[workshop-playwright-qa] __root__: 1 QA finding — accessibility

2 participants