rowIndex undefined when pressing tab key while second row is selected in (editable) DataTable #6657
Labels
Type: Bug
Issue contains a defect related to a specific component.
Milestone
Describe the bug
Pressing the tab key while a cell in any other row than the first row inside a Datatable is selected leads to a thrown exception because rowIndex is undefined.
This is caused by small typo in BodyRow.js in the definition of
onTabKey
:It should read
focusedItem !== rows[0] && (rows[props.rowIndex].tabIndex = '-1');
instead of
focusedItem !== rows[0] && (rows[rowIndex].tabIndex = '-1');
Reproducer
No response
PrimeReact version
10.6.5
React version
18.x
Language
TypeScript
Build / Runtime
Create React App (CRA)
Browser(s)
No response
Steps to reproduce the behavior
No response
Expected behavior
No response
The text was updated successfully, but these errors were encountered: