-
Notifications
You must be signed in to change notification settings - Fork 204
fix: let line chart highlight all points at a given X coordinate usin… #538
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
Conversation
…g keyboard navigation
tsconfig.json
Outdated
| "compilerOptions": { | ||
| "lib": ["es5", "es2015.collection", "dom"], | ||
| "types": [], | ||
| "types": ["jest"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was necessary for WebStorm to interpret test files correctly. Opened the project with VSCode as well to make sure nothing was broken.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed in latest commit after offline conversation, since this would affect non-test files as well.
Codecov ReportBase: 92.40% // Head: 92.35% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #538 +/- ##
==========================================
- Coverage 92.40% 92.35% -0.06%
==========================================
Files 569 571 +2
Lines 16218 16255 +37
Branches 4436 4457 +21
==========================================
+ Hits 14987 15013 +26
- Misses 1148 1159 +11
Partials 83 83
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
|
|
||
| function VerticalMarker( | ||
| { height, showPoints = true, showLine = true, points }: VerticalMarkerProps, | ||
| { height, showPoints = true, showLine = true, points, ariaLabel }: VerticalMarkerProps, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, it looks like this does nothing, because it's placed on an element with aria-hidden.
Inside chart, it looks like all announcements are being made with a live region inside ChartPlot, so I don't think we don't need to pass an aria label.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed, the way this works is that the aria-label is copied over to another element which is the one that is actually focused. But on the other hand, we decided that we don't want this extra information to be announced so I've removed this prop in the latest commit.
…g keyboard navigation
Description
Issue: AWSUI-19201
Context: mouse hover on line chart allows to highlight not only one single point but also all points (from all series) at a given X coordinate, but this behavior was missing for keyboard users. This PR adds it.
The visual appearance is the same as when the points are highlighted with the mouse, but with the focus indicator around the points and the vertical marker:

How has this been tested?
Review checklist
The following items are to be evaluated by the author(s) and the reviewer(s).
Correctness
CONTRIBUTING.md.CONTRIBUTING.md.Security
checkSafeUrlfunction.Testing
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.