Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

Angular 1.4.x breaks Angular Material Select menu #12375

Closed
ThomasBurleson opened this issue Jul 17, 2015 · 7 comments
Closed

Angular 1.4.x breaks Angular Material Select menu #12375

ThomasBurleson opened this issue Jul 17, 2015 · 7 comments

Comments

@ThomasBurleson
Copy link

See issue for details

@ThomasBurleson
Copy link
Author

Appears to have been an issue with transitionEnd events not firing and our wait process timing out;
Perhaps Angular 1.4.x is interfering with some dispatching of transitionEnd events... meanwhile AMv1 appears to account for this now.

Occassionally the transitionEnd event will not fire and the '$mdUtil. waitTransitionEnd()' process will timeout; which rejects the pending promise. Using '.finally()' [consistently] allows the correct handlers to fire and will continuing to propagate the rejected promise.

@ThomasBurleson
Copy link
Author

@matsko - Reopening to investigate why Angular 1.4.x appears to interfere with transitionEnd events.

@petebacondarwin
Copy link
Member

This line looks a bit "unusual":

https:/angular/material/blob/d6a938e983690c229c1ee856c0416ae1832cffb4/src/core/services/interimElement/interimElement.js#L405

Am I wrong or are you assigning true to a promise (showDone) and then also rejecting the original promise. Later on you are creating a new promise that uses $q.when(showDone). Depending upon when this gets called you could be getting the original promise here or true, right.

That seems quite convoluted.

@ThomasBurleson
Copy link
Author

@petebacondarwin - That is some legacy code that should be cleaned...

The issue is the show() returns a promise... which can fail. I think the intent was that the remove() should not block on a failed show. Recently we updated the code to use a .finally() handler, however:

return removeDone = $q.when(showDone).finally(function() {

Which means that we no longer have to spoof the show rejected promise.

Your comment above has prompted me to revisit some of the more convoluted promise chainings. Thx.

@ThomasBurleson
Copy link
Author

@petebacondarwin Per your thoughts and hints, I decided to refactor and fix our promise-chain logic: Fixes to InterimElement and More Tests

@Narretz
Copy link
Contributor

Narretz commented Aug 3, 2015

@ThomasBurleson Looks like this will be fixed by angular/material#3949 right?

@Narretz Narretz added this to the Ice Box milestone Aug 3, 2015
@Narretz
Copy link
Contributor

Narretz commented Aug 13, 2015

I see your changes landed as angular/material@d2a76c2. angular 1.4.4 is also released later today, so this will hopefully resolve this. I am tentatively going to close this issue then

@Narretz Narretz closed this as completed Aug 13, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants