@ctlyst.id/internal-ui 5.0.1 → 5.0.3

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.js CHANGED
@@ -1501,7 +1501,9 @@ var useDataTable = ({
1501
1501
  const { getSelectedRowModel, toggleAllRowsSelected } = table;
1502
1502
  const { flatRows } = getSelectedRowModel();
1503
1503
  React5.useEffect(() => {
1504
- console.log("changed");
1504
+ table.setRowSelection(selectedRow != null ? selectedRow : {});
1505
+ }, [selectedRow]);
1506
+ React5.useEffect(() => {
1505
1507
  const rowData = flatRows.map((row) => row.original);
1506
1508
  if (onSelectedRow) {
1507
1509
  onSelectedRow(rowData);