[paragon-openedx.netlify.app] Feedback (on /components/datatable/)
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 140
- Forks
- 100
- Avg merge
- 1h 3m
- Merged PRs (30d)
- 30
Description
Bugs
I believe there may be an a11y/usability bug surrounding sortable columns in the DataTable component regarding the title attribute value on sortable column headers. As is, every sortable column header has the same title attribute of "Toggle SortBy".
There are two primary issues with this:
titleis the same value across all column headers.titledoes not include any mention of the actual column header.
The current value of these title attributes on sortable column headers is coming from @tanstack/react-query's getSortByToggleProps called within TableHeaderCell.
It's not entirely clear whether we can deduce a user-friendly string version of the column header name (e.g., based on render('Header)), or whether DataTable can support custom title attribute values for each column for more granular control by consumers.
### Tasks
- [ ] Ensure each sortable column header has a unique `title` attribute, including the column header text to be more descriptive than just "Toggle SortBy" across all sortable column headers.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the DataTable component to TableHeaderCell and the getSortByToggleProps call that supplies sortable header titles. Determine whether the column header text can be used or whether consumers need custom title values; done means each sortable header has a unique, descriptive title including its column text, with the existing component behavior covered as appropriate.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- accessibility, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100