Fixed #4498 - Datatable: Cannot set properties of null (setting 'tabIndex')

pull/4713/head
tugcekucukoglu 2023-10-27 17:52:34 +03:00
parent c8e065e73a
commit 4934e0e146
1 changed files with 2 additions and 0 deletions

View File

@ -787,6 +787,8 @@ export default {
this.rowTouched = false; this.rowTouched = false;
if (focusedItem) { if (focusedItem) {
if (e.originalEvent.target.getAttribute('data-pc-section') === 'rowtogglericon' || e.originalEvent.target.parentElement.getAttribute('data-pc-section') === 'rowtogglericon') return;
const targetRow = e.originalEvent.target.closest('tr[data-p-selectable-row="true"]'); const targetRow = e.originalEvent.target.closest('tr[data-p-selectable-row="true"]');
focusedItem.tabIndex = '-1'; focusedItem.tabIndex = '-1';