Skip to content

Commit

Permalink
fix: Add button role to table header interactive element (#289)
Browse files Browse the repository at this point in the history
  • Loading branch information
StoianLucian authored Dec 13, 2023
1 parent 19c2665 commit 7384f9f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions coral-component-table/src/scripts/Table.js
Original file line number Diff line number Diff line change
Expand Up @@ -2467,6 +2467,10 @@ const Table = Decorator(class extends BaseComponent(HTMLTableElement) {
headerCell.setAttribute('role', 'rowheader');
}
headerCell.setAttribute('scope', scope);

if(headerCell.hasAttribute('sortable')){
headerCell.content.setAttribute('role', 'button');
}
}

/** @private */
Expand Down

0 comments on commit 7384f9f

Please sign in to comment.