Uh oh!
There was an error while loading. Please reload this page.
fix(expansion-panel): emitting events twice on some browsers - #13600
Conversation
Fixes the expansion panel emitting the `afterExpand` and `afterCollapse` events twice on IE and Edge due to a bug in `@angular/animations`.
Along the same lines as angular#13600 and angular#13587. The `animationDone` will be emitted twice in a row for some browsers due to a bug in `@angular/animations`.
| this._bodyAnimationDone.pipe(distinctUntilChanged((x, y) => { | ||
| return x.fromState === y.fromState && x.toState === y.toState; | ||
| })).subscribe(event => { | ||
| if (event.fromState !== 'void') { |
There was a problem hiding this comment.
Instead of removing the _bodyAnimation method, can we call it here since an upstream fix to this from angular/angular will likely have us essentially reverting this change?
There was a problem hiding this comment.
I don't mind re-adding, but I don't see why it's an issue, considering that it's a private API. Once the upstream fix gets merged, we can turn it back into a private method.
There was a problem hiding this comment.
Yeah, its fine to leave it as is. I just wanted us to consider it.
| this._bodyAnimationDone.pipe(distinctUntilChanged((x, y) => { | ||
| return x.fromState === y.fromState && x.toState === y.toState; | ||
| })).subscribe(event => { | ||
| if (event.fromState !== 'void') { |
There was a problem hiding this comment.
Yeah, its fine to leave it as is. I just wanted us to consider it.
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Fixes the expansion panel emitting the
afterExpandandafterCollapseevents twice on IE and Edge due to a bug in@angular/animations.