-
Notifications
You must be signed in to change notification settings - Fork 27.4k
ng-hide does work when using css keyframe sprite animations #8033
Comments
Do you have a plunkr link? Also, what version are you using of Angular? There was a fix recently which prevents it from hiding whlist inside of an animation. |
And to double check, you want the animation to run for an infinite time or for 19 steps? |
@michelalbers could you please get back to me? |
@matsko Sorry for the delay! It was a loading spinner in my case - generated from http://spiffygif.com/?format=png&color=000 $scope.scan = () ->
success = (base64) ->
$ionicLoading.show
template: "<div class='text-center'><p>Verarbeite Foto ... </p><p ng-init='progress' ng-hide='progress == 100'><progress value='{{progress}}' max='100'></progress><p><div class='spinner' ng-hide='progress <= 100'></div></div></p>"
$imageService.processBase64 base64
.then (response) ->
$imageService.processRekognitionResponse response
.then (result) ->
$ionicLoading.hide()
try
$rootScope.resultPlayer = result.face_detection[0].matches[0].tag
$rootScope.id = result.id
$state.go "result"
catch e
console.error e
showErrorPopup()
,
(err) ->
$ionicLoading.hide()
showErrorPopup()
, (err) ->
showErrorPopup()
, (event) ->
if event.loaded && event.total
$rootScope.progress = Math.round event.loaded / event.total * 100 The spinner should show when the upload of the image is done and the processing of the image starts for which I cannot provide progress information. |
@michelalbers this is a case where a natural CSS animation is conflicting with ngAnimate. Unfortunetly ngAnimate is unable to detect when this happens since it assumes the animation is designed for itself. To get around this, simply do: .spinner.ng-animate {
transition: 0s none;
animation: 0s none;
-webkit-animation: 0s none;
} |
Just a note, this bit me and ate a few hours of time 🍕 🕙 , perhaps elevating a note about this in the More than willing to add the docs just let me know, thanks again for this great lib 🌴 |
- how to enable / disable animations Closes angular#8812 - how to handle conflicts with existing animations Closes angular#8033 Closes angular#11820 - what happens on boostrap / how to enable animations on bootstrap
- how to enable / disable animations Closes angular#8812 - how to handle conflicts with existing animations Closes angular#8033 Closes angular#11820 - what happens on boostrap / how to enable animations on bootstrap
thanks @Narretz 👏 |
When using CSS3 keyframe animations ng-hide does not work instantaneously but delayed.
CSS Sprite animation Code (stylus):
Dirty Fix
fixes the issue but does not feel right :/
The text was updated successfully, but these errors were encountered: