Skip to content

fix(a11y/seo): downgrade FeedbackButton dialog titles from h1 to h2#50

Open
forgetso wants to merge 1 commit into
mainfrom
fix/duplicate-h1-feedback-dialog
Open

fix(a11y/seo): downgrade FeedbackButton dialog titles from h1 to h2#50
forgetso wants to merge 1 commit into
mainfrom
fix/duplicate-h1-feedback-dialog

Conversation

@forgetso

@forgetso forgetso commented Jul 7, 2026

Copy link
Copy Markdown
Member

Summary

  • The feedback modal is hidden by default but still lives in the DOM on every docs page, so crawlers were seeing two extra <h1> elements (feedback.formTitle and feedback.sendFeedback) alongside the real page <h1>.
  • This tripped duplicate-H1 audit warnings on every localised copy of the docs (~250+ URLs across en/es/pt-br/fr/de/it).
  • Both dialog titles are now <h2 class="dialog-title">; the scoped h1 { … } selector is renamed to .dialog-title { … } so the styling is preserved without depending on the tag name.
  • Nested .select-buttons h2 rules are unaffected.

Test plan

  • Open a docs page, click the feedback button in the sidebar, and confirm the dialog still renders with the same title styling.
  • Confirm the two internal panes (select pane and form pane) both show their heading correctly.
  • View source on any docs URL and confirm exactly one <h1> remains (the Starlight page title).

🤖 Generated with Claude Code

The feedback modal is hidden by default but still lives in the DOM on every
docs page, so crawlers were seeing two extra h1 elements ("What's on your
mind?" and "Send us feedback") alongside the real page h1, tripping duplicate
H1 audit warnings across the entire site (including every localised copy).

Both dialog titles become h2s with a shared .dialog-title class; the scoped
selector is renamed to match, preserving the existing styling. Nested
.select-buttons h2 rules are unaffected.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@netlify

netlify Bot commented Jul 7, 2026

Copy link
Copy Markdown

Deploy Preview for peaceful-pothos-9e62ce ready!

Name Link
🔨 Latest commit 3adf8df
🔍 Latest deploy log https://app.netlify.com/projects/peaceful-pothos-9e62ce/deploys/6a4ccb59ef075a0008b4914b
😎 Deploy Preview https://deploy-preview-50--peaceful-pothos-9e62ce.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

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.

1 participant