angularjs - ngAnimate on ngShow. Preventing animation when it starts first time -


i playing around added angular.js animations feature, , doesn't work desired

<style>     .mydiv{         width:400px;         height:200px;         background-color:red;     }     .fadein-setup,.fadeout-setup {       -webkit-transition: 1s linear opacity;       -moz-transition: 1s linear opacity;       -o-transition: 1s linear opacity;       transition: 1s linear opacity;     }     .fadein-setup{       opacity:0;     }     .fadeout-setup{       opacity:1;     }     .fadein-setup.fadein-start {       opacity: 1;     }     .fadeout-setup.fadeout-start{         opacity:0;     } </style>  <div ng-app>     <div ng-controller='ctrl'>        <input type='button' value='click' ng-click='clicked()' />          <div ng-show="foo == true"  class='mydiv' ng-animate="{show: 'fadein', hide:'fadeout'}">        </div>      </div> </div>  function ctrl($scope){     $scope.foo = false;     $scope.clicked = function(){        $scope.foo = !($scope.foo);     } } 

http://jsfiddle.net/kx4ts/1

it spoils away mydiv on dom.ready , starts fading out. whereas should hidden. how fix that?

this has been fixed now. upgrade 1.1.5.


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -