-
Notifications
You must be signed in to change notification settings - Fork 27.4k
ng-animate breaks with ngMaterial #11658
Comments
Can you please provide more info, such as a runnable example that shows the problem? |
I encountered this exception today as well on 1.4.0-rc.0. We don't use ng-messages yet, so it's not necessarily related to that. I'm attempting an upgrade from 1.2, and the workflow that this is happening in is pretty complex, so I don't have a dumbed down enough example to make any sense of it, but I'll update this if/when I do. |
You could try with the latest snapshot of 1.4 or wait for rc.1 that is coming later today. It includes quite a few animation fixes. |
I just checked it on build.3984, and it's still an issue there. I'll check out rc.1 when that is released. |
I just realized the original post included a trace from a minified angular, so here's one without minification:
|
Are you guys by chance using bower? Sometimes there's a version mismatch where the core version of Angular differs from the animate version. Can you double check on that please? |
I am using bower, and I have both angular-animate and angular (and all of the angular modules, in fact) set explicitly as 1.4.0-rc.0 |
OK. Can you post a plnkr example? Maybe we can get this out the door in time for RC1. |
Actually @borgdylan can you test this out on master using the snapshot build of angular: https://code.angularjs.org/snapshot/angular.js and https://code.angularjs.org/snapshot/angular-animate.js. #11620 did fix something similar here. |
Having a hell of a time reproducing this with a simpler example on plnkr, so I'm kind of hoping @borgdylan has more luck. If it helps, feel free to use my plnkr as a jumping off point: http://plnkr.co/edit/Tw8aKVY1PRD90qjp7KLt |
I found the issue using the latest git masters of both angular and angular-material. I do not have a small example to reproduce it (this happened in a large project). However I did manage to patch the angular-animate.js file to make the problem go away. |
This doesn't seem to be related to ngMaterial. Here's a very simple example using only Steps: Focus in the text box, type something, hit enter. This produces the following error
for this line in
The runner that appears to have been removed is for Bootstrap's border transition on I also get the same error using ui-router so it's not |
@philBrown I can't reproduce this error in FF or Chrome |
@philBrown That does indeed recreate the exact error stack I had listed earlier. In firefox, the message is @Narretz I was able to reproduce the issue consistently using @philBrown's plnkr and following his exact steps (focus, type some characters, hit enter) in Firefox 37. |
Seems to be related to ngModel somehow; without the model, the issue doesn't arise. I guess having the model adds it to the list of children with animations to close (those with the @Narretz I get the issue on Linux in both Firefox 37.0.1 and Chrome 42.0.2311.90 (64-bit) |
Testing further, it's got nothing to do with transitions on the form control (I figured that was the problem because it's an I've removed the Bootstrap CSS and it still occurs. If you don't type anything in to the text field and hit Enter, it works correctly. If you click the submit button, it works correctly. The only thing that causes the issue is typing into the text field (thus toggling the model controller I've updated the Plunker to reflect this - http://plnkr.co/edit/mAqeERAPox7uyypYceFG?p=preview |
I've been having a similar issue. I've posted on StackOverflow on it here: http://stackoverflow.com/questions/29740618/angular-animate-runner-is-undefined My stack trace is:
|
I think that this might be related to another bug I found: If you click on the Home link when it is already active then In the plunker provided by @philBrown it seems a similar thing is happening. If you look the input still has |
Looking at it now. Thanks guys. |
The bug is still present in the latest master. Simply checking if animationDetails.runner is defined before accessing patches the issue. |
…perly Prior to this fix if a form DOM element was fed into parts of the ngAnimate queuing code it would attempt to detect if it is a jqLite object in an unstable way which would allow a form element to return an inner input element by index. This patch ensures that jqLite instances are properly detected using a helper method. Closes angular#11658
…perly Prior to this fix if a form DOM element was fed into parts of the ngAnimate queuing code it would attempt to detect if it is a jqLite object in an unstable way which would allow a form element to return an inner input element by index. This patch ensures that jqLite instances are properly detected using a helper method. Closes angular#11658
Here's a PR for the fix: #11760 Turns it that |
Ah, good old @matsko nice work! |
Brilliant and speedy resolution, thanks! Now that I come to think of it, it did start happening as I added a form to my page. I apologize for neglecting to mention this detail earlier. |
No worries. I didn't want to patch it with just an if statement and I knew that there was something fishy going on. I learned a lot from this issue. |
Nice work @matsko !! |
Most excellent, thanks @matsko |
…perly Prior to this fix if a form DOM element was fed into parts of the ngAnimate queuing code it would attempt to detect if it is a jqLite object in an unstable way which would allow a form element to return an inner input element by index. This patch ensures that jqLite instances are properly detected using a helper method. Closes angular#11658
…perly Prior to this fix if a form DOM element was fed into parts of the ngAnimate queuing code it would attempt to detect if it is a jqLite object in an unstable way which would allow a form element to return an inner input element by index. This patch ensures that jqLite instances are properly detected using a helper method. Closes angular#11658
…perly Prior to this fix if a form DOM element was fed into parts of the ngAnimate queuing code it would attempt to detect if it is a jqLite object in an unstable way which would allow a form element to return an inner input element by index. This patch ensures that jqLite instances are properly detected using a helper method. Closes angular#11658
AN exception in angular-animate.js is allowing the creation of more than one ng-view instance in teh pnge.:
The text was updated successfully, but these errors were encountered: