We have an issue on our application, where we import products, that show on the grid at a root level, but are also shown as nested child products. This has broken the select all, because these child products have the same row Id (which we generate from the product id) as the product at root level, select all and unselect all doesn't work correctly, as the selected length is greater than the total amount of products. For example. 25 products selected (actually 27 is selected due to 2 child products being selected). we can no longer unselect all, as that length is greater than the total.
To Reproduce
Create 3 top level products in the grid. Prod1, Prod2, Prod3.
Prod3 should be a parent, with Prod1 and Prod2 as children (while still keeping Prod1 and Prod2 in the root of grid).
attempt to select and deselect all. (ensure the row keys are the same for the nested children).
We have an issue on our application, where we import products, that show on the grid at a root level, but are also shown as nested child products. This has broken the select all, because these child products have the same row Id (which we generate from the product id) as the product at root level, select all and unselect all doesn't work correctly, as the selected length is greater than the total amount of products. For example. 25 products selected (actually 27 is selected due to 2 child products being selected). we can no longer unselect all, as that length is greater than the total.
To Reproduce
react-data-grid
version: 7.0.0-canary.47react
/react-dom
version: "17.0.2"Thanks :)