Skip to content

Commit

Permalink
Merge branch 'master' into fix/filter-bar-label-and-expanding
Browse files Browse the repository at this point in the history
  • Loading branch information
Lukas742 authored Aug 19, 2020
2 parents 9586f16 + e3b1117 commit fe96948
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/main/src/components/AnalyticalTable/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,16 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<

useEffect(() => {
toggleAllRowsSelected(false);
const validChars = /^(\d\.)*\d$/;
// eslint-disable-next-line guard-for-in
for (const row in selectedRowIds) {
toggleRowSelected(row, selectedRowIds[row]);
if (reactTableOptions?.getRowId) {
toggleRowSelected(row, selectedRowIds[row]);
} else if (validChars.test(row)) {
toggleRowSelected(row, selectedRowIds[row]);
}
}
}, [toggleRowSelected, toggleAllRowsSelected, selectedRowIds]);
}, [toggleRowSelected, toggleAllRowsSelected, selectedRowIds, reactTableOptions?.getRowId]);

const calcRowHeight = parseInt(
getComputedStyle(tableRef.current ?? document.body).getPropertyValue('--sapWcrAnalyticalTableRowHeight') || '44'
Expand Down

0 comments on commit fe96948

Please sign in to comment.