I understand that KendoReact is 508 compliant by certain standards, but my agency tests to a different standard.
I'm getting reports that the grid is not associated cells with headers. I've researched different ways to get around this and the solution I've come up with is to add ID to the TH tags and then using the HEADERS attribute to the data cells with the ID in the associated header. Example below:
<table>
<tr>
<th id="colOneHeader">Col One</th>
<th id="colTwoHeader">Col Two</th>
</tr>
<tr>
<td headers="colOneHeader">Col One Data</td>
<td headers="colTwoHeader">Col Two Data</td>
</tr>
</table>
My issue is adding the ID attribute to the TH tags in the grid. I've attempted the following:
const HeaderCustomCell = (props: any) => {
return (
<HeaderThElement scope="col" columnId={ props.thProps?.columnId || "" } id={ props.thProps.title + "_Header" } { ...props.thProps }>
{ props.children }
</HeaderThElement>
);
};
<Grid cells={{ headerCell: HeaderCustomCell }} ...
The SCOPE and ID attributes are ignored and do not show up in the TH tags in the source code. I also tried just returning a basic <th> node from the HeaderCustomCell method and it did not work.
Is there a different method to add custom attributes to the HeaderThElement?
Thanks in advance