[charts] Remove usage of focus outline for item highlight#19856
Conversation
|
Deploy preview: https://deploy-preview-19856--material-ui-x.netlify.app/ Updated pages: Bundle size report
|
|
This pull request has conflicts, please resolve those before we can evaluate the pull request. |
CodSpeed Performance ReportMerging #19856 will not alter performanceComparing Summary
Footnotes |
| // import { FocusedBar } from '@mui/x-charts/BarChart'; | ||
| import { LineFocusedMark } from '@mui/x-charts/LineChart'; | ||
| import { ScatterFocusedMark } from '@mui/x-charts/ScatterChart'; |
There was a problem hiding this comment.
Should we follow the same pattern on all focused mark?
| // import { FocusedBar } from '@mui/x-charts/BarChart'; | |
| import { LineFocusedMark } from '@mui/x-charts/LineChart'; | |
| import { ScatterFocusedMark } from '@mui/x-charts/ScatterChart'; | |
| import { FocusedBar } from '@mui/x-charts/BarChart'; | |
| import { FocusedMark } from '@mui/x-charts/LineChart'; | |
| import { FocusedMark } from '@mui/x-charts/ScatterChart'; |
Or
| // import { FocusedBar } from '@mui/x-charts/BarChart'; | |
| import { LineFocusedMark } from '@mui/x-charts/LineChart'; | |
| import { ScatterFocusedMark } from '@mui/x-charts/ScatterChart'; | |
| import { FocusedBar } from '@mui/x-charts/BarChart'; | |
| import { FocusedLineMark } from '@mui/x-charts/LineChart'; | |
| import { FocusedScatterMark } from '@mui/x-charts/ScatterChart'; |
There was a problem hiding this comment.
The other option would be BarFocusedItem to keep consistency with "all bar element start with Bar". But it's less expressive
There was a problem hiding this comment.
It depends on what it aggregates on I suppose. Since this doc is standalone, it feels like we should aggregate on the Focused which is the common ground
prakhargupta1
left a comment
There was a problem hiding this comment.
The bar highlight looks quite good now! 👏
All of these refinements might call for a blog post on charts accessibility!
Fix #19754
I moved all the the focus elements outside of their plot.
The only exception is the pie chart. But to do it properly I will have to move the pie layout computation in the seriesLayout selector