Created
August 11, 2014 09:49
-
-
Save walidvb/7a0298c81b237f94dbb1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- @price_present = true | |
%span{"ng-cloak" => true, "ng-switch" => "currency"} | |
%span.animated{"ng-switch-when" => 'gbp'}= number_to_currency(locals[:gbp].to_d/100, {:unit => @currencies['gbp']}) | |
%span.animated{"ng-switch-when" => 'eur'}= number_to_currency(locals[:eur].to_d/100, {:unit => @currencies['eur']}) | |
%span.animated{"ng-switch-when" => 'usd'}= number_to_currency(locals[:usd].to_d/100, {:unit => @currencies['usd']}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ng\:cloak], [ng-cloak], [data-ng-cloak], [x-ng-cloak], .ng-cloak, .x-ng-cloak { | |
display: none !important; | |
} | |
/* starting animations */ | |
.animated{ | |
-webkit-transition:.5s linear all; | |
transition:.5s linear all; | |
overflow: hidden; | |
} | |
/* destination animations */ | |
.animated.ng-enter, .animated.ng-leave.ng-leave-active{ | |
max-height: 0px; | |
opacity: 0; | |
position: absolute; | |
} | |
.animated.ng-enter-active, .animated.ng-leave{ | |
max-height: 900px; | |
opacity: 1; | |
position: absolute; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment