Skip to content
This repository was archived by the owner on Sep 23, 2025. It is now read-only.

Conversation

@tsanjoto
Copy link

@tsanjoto tsanjoto commented Oct 5, 2017

What issue is this PR resolving? Alternatively, please describe the bugfix/enhancement this PR aims to provide
I used the loading bar and a spinner template with grey overlay. I notice that my HTTP success/error callback ran first before the loading animation finish dismissing.

I found that your _completeAnimation only trigger when the bar finished the animation. It should wait for both bar and spinner animation finished animating and put it as complete.

Additionally
the $animate.leave, returns a promise when they are finished animating, so by putting
$animate.leave(...)
$rootScope.$broadcast(...)

would result the broadcast to run asynchronously.
it should be:
var promise = $animate.leave(...)
promise.then(function(){
$rootScope.$broadcast(...)
})

Have you provided unit tests that either prove the bugfix or cover the enhancement?
no

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant