Description
Is this a regression?
- Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was
No response
Description
When a MatSort is applied to a MatTable, the animation start/done callbacks do not (sometimes) work. Even though the animation appears to happen, the callbacks do not get called. When the sort is not applied, this does not ever seem to be the case.
This seems to be related to changes to/from void
, but as best I can tell from the docs, these should still trigger the callbacks.
I believe this is related to this issue #13431 in that both are related to the sort causing animation to default to void (instead of whatever the default state is when rows are not sorted).
Reproduction
StackBlitz link: https://stackblitz.com/edit/sreaf6
Steps to reproduce:
- Click the "symbol" header once to sort by symbol.
- Click the Fluorine row to expand the row details.
- Repeatedly collapse and expand this row.
Expected Behavior
The "Last animation" section on the row should change between:
- Last animation: Fluorine - expanded started
- Last animation: Fluorine - expanded done
- Last animation: Fluorine - collapsed started
- Last animation: Fluorine - collapsed done
(depending on the last user action and whether the animation is still in progress)
Additionally, the console should have logged each of these animation state changes occurring for the row.
Actual Behavior
The "Last animation" section on the row just says "Last animation: Neon - void done".
The console never logs either collapse or expand animations starting or finishing, even though the animation event is clearly occurring.
Environment
- Angular: 16.2.8, 17.0.0
- CDK/Material: 16.2.10, 17.0.1
- Browser(s): Firefox
- Operating System (e.g. Windows, macOS, Ubuntu): Ubuntu
Activity