cfpb / design-system

CFPB's work-in-progress design system
https://cfpb.github.io/design-system
Creative Commons Zero v1.0 Universal
42 stars 13 forks source link

Date picker documentation page fails Lighthouse checks #2124

Closed chosak closed 4 days ago

chosak commented 4 days ago

Describe the bug The date picker page fails Lighthouse checks due to a missing heading h2 element.

See nightly GitHub Action failure here and failing Lighthouse report here.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://cfpb.github.io/design-system/components/date-picker.
  2. Run Lighthouse check in Chrome.
  3. See error.

Screenshots

image image

@sonnakim for awareness, assigning to @anselmbradford as last modifier of this page.

anselmbradford commented 4 days ago

What happened here is the date picker had a "Types" h2 heading (see https://web.archive.org/web/20240927164342/https://cfpb.github.io/design-system/admin/#/collections/pages/entries/date-picker), which in the markdown is called the variation group name. When I added a second date picker example, this group name was inadvertently indented one level too deep in the markdown, so it was ignored. Decap allowed this because the variation group name is optional

Screenshot 2024-11-22 at 12 48 22 PM

This should be fixed for the date picker page now, but because the variation group name is optional it's possible this failure could crop up again in the future across edits to any of the pages.