From e1fe2ac2691e319473ed2bbca501fc6b641024e5 Mon Sep 17 00:00:00 2001
From: Matias Niemelä
Date: Mon, 29 Jul 2013 19:45:59 -0400
Subject: chore(ngdocs): all animation-supported directives working with docs
examples and jsFiddle/Plunkr pages
---
src/ng/directive/ngShowHide.js | 71 +++++++++++++-----------------------------
1 file changed, 22 insertions(+), 49 deletions(-)
(limited to 'src/ng/directive/ngShowHide.js')
diff --git a/src/ng/directive/ngShowHide.js b/src/ng/directive/ngShowHide.js
index 1bba11ef..e5ce713d 100644
--- a/src/ng/directive/ngShowHide.js
+++ b/src/ng/directive/ngShowHide.js
@@ -27,56 +27,42 @@
Click me:
Show:
-
+
I show up when your checkbox is checked.
-
+
Hide:
-
+
I hide when your checkbox is checked.
-
+
- .example-show-hide {
+ .animate-show.ng-hide-add,
+ .animate-show.ng-hide-remove {
-webkit-transition:all linear 0.5s;
-moz-transition:all linear 0.5s;
- -ms-transition:all linear 0.5s;
-o-transition:all linear 0.5s;
transition:all linear 0.5s;
- display:block;
- }
- .example-show-hide.ng-hide {
- display:none;
+ display:block!important;
}
- .example-show-hide.ng-hide-remove {
- display:block;
+ .animate-show.ng-hide-add.ng-hide-add-active,
+ .animate-show.ng-hide-remove {
line-height:0;
opacity:0;
padding:0 10px;
}
- .example-show-hide.ng-hide-remove.ng-hide-remove-active {
- line-height:20px;
- opacity:1;
- padding:10px;
- border:1px solid black;
- background:white;
- }
- .example-show-hide.ng-hide-add {
+ .animate-show.ng-hide-add,
+ .animate-show.ng-hide-remove.ng-hide-remove-active {
line-height:20px;
opacity:1;
padding:10px;
border:1px solid black;
background:white;
}
- .example-show-hide.ng-hide-add.ng-hide-add-active {
- line-height:0;
- opacity:0;
- padding:0 10px;
- }
.check-element {
padding:10px;
@@ -132,55 +118,42 @@ var ngShowDirective = ['$animate', function($animate) {
Click me:
Show:
-
+
I show up when your checkbox is checked.
-
+
Hide:
-
+
I hide when your checkbox is checked.
-
+
- .example-show-hide {
+ .animate-hide.ng-hide-add,
+ .animate-hide.ng-hide-remove {
-webkit-transition:all linear 0.5s;
-moz-transition:all linear 0.5s;
-o-transition:all linear 0.5s;
transition:all linear 0.5s;
- display:block;
- }
- .example-show-hide.ng-hide {
- display:none;
+ display:block!important;
}
- .example-show-hide.ng-hide-remove {
- display:block;
+ .animate-hide.ng-hide-add.ng-hide-add-active,
+ .animate-hide.ng-hide-remove {
line-height:0;
opacity:0;
padding:0 10px;
}
- .example-show-hide.ng-hide-remove.ng-hide-remove-active {
- line-height:20px;
- opacity:1;
- padding:10px;
- border:1px solid black;
- background:white;
- }
- .example-show-hide.ng-hide-add {
+ .animate-hide.ng-hide-add,
+ .animate-hide.ng-hide-remove.ng-hide-remove-active {
line-height:20px;
opacity:1;
padding:10px;
border:1px solid black;
background:white;
}
- .example-show-hide.ng-hide-add.ng-hide-add-active {
- line-height:0;
- opacity:0;
- padding:0 10px;
- }
.check-element {
padding:10px;
--
cgit v1.2.3