Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div class="play" ng-click="animate($event)"></div>
- $scope.animate = function(event) {
- var el = event.srcElement;
- angular.element(el).addClass('animate');
- $timeout(function() {
- angular.element(el).removeClass('animate');
- }, 1000);
- };
- .play.animate {
- animation:0.5s bounceIn ease;
- }
- this.animated = false;
- this.animationToggle = function(){
- this.animated = !this.animated;
- };
- <div ng-class="{'play' : ctrl.animate}" ng-click="ctrl.menuToggle()"></div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement