Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EuiTimeline][COGNITION]: Could we refine the HTML to make this an ordered list with list items? #5782

Closed
1Copenut opened this issue Apr 12, 2022 · 4 comments · Fixed by #5791

Comments

@1Copenut
Copy link
Contributor

Description

@miukimiu is / will be releasing an EuiTimeline component as part of PR #5730. I would like to consider a feature request to adjust the HTML to make this component an ordered list (OL) with list items and an optional accessible label. This should allow us to retain the current styling and improve the semantic meaning for screen readers.

By making this a list with an accessible name, the timeline will appear in screen readers' "Lists" menu and be available in the List shortcut key. I'm proposing HTML something like the following:

<ol class="euiTimeline" aria-label="Project Beta Timeline">
  <li class="css-88d0w-euiTimelineItem">...</li>
  <li class="css-88d0w-euiTimelineItem">...</li>
  <li class="css-88d0w-euiTimelineItem">...</li>
</ol>

Guidance


Screen Shot 2022-04-12 at 3 32 37 PM

@miukimiu
Copy link
Contributor

Thanks, @1Copenut. I'll prioritize this issue before going back to #5692.

@1Copenut
Copy link
Contributor Author

Thank you @miukimiu!

@chandlerprall
Copy link
Contributor

Talked through this with @miukimiu a bit and we'll try out ol+li by default but exposing an as prop to allow overriding for other scenarios (ul, and non-wrapped timeline items should be a div - or at least not an li)

@1Copenut
Copy link
Contributor Author

Thank you both for the quick turnaround and collaborative approach to enhancement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants