Pivot filter change triggers expand and sort

Hello,

My Pivot supports collapsing all rows and sorting them.
However when I change a filter, the pivot is:

  1. filtered (as expected)

  2. all rows expanded (users need to again configure collapse\expand state)

  3. sorting rules are no longer applied (users need to re-sort the column).

This means that for each filter change the user needs to reapply all sort\collapse\expand configurations.

How can I disable this behaviour?

Filtering in the pivot is done not against the already rendered data, but against the original dataset. As result, the component needs to recreate and reload dataset after filtering ( the result dataset may differ a lot from the not-filtered one ). And as part of reloading the row collapsing state is lost.

It possible to get state of datatable ( sorting/open-close state etc. ) and reapply it after filling the pivot