In my case downgrading @angular/animations worked, if you can afford to do that, run the command
npm i @angular/[email protected]
Or use another version that might work for you from the Versions tab here: https://www.npmjs.com/package/@angular/animations