I'm trying to animate a div using ng-show with CSS3 transitions. There are 2 divs: One in the foreground and another hidden behind it. The hidden div should slide up when the user mouse's over the foreground div. It should also remain shown if the users cursor moves over the slide div. If the users cursor leaves the slide div or the foreground div, it should slide back down. It doesn't seem to work correctly though. Here's a plunker: http://plnkr.co/edit/C1RaDTOXwpEMECGMkt19?p=preview
Is the css correct?
div#cover {
background-color: lightblue;
width: 90px;
height: 30px;
position:absolute;
bottom: 0px;
z-index:10;
}
.slide {
background-color: white;
width: 90px;
height: 30px;
position:absolute;
bottom: 0px;
z-index:5;
}
.slide.ng-hide-add, .slide.ng-hide-remove {
transition: bottom 1s ease;
}
.slide.ng-hide-remove-active {
bottom: 30px
}
.slide.ng-hide-add-active {
bottom: 0px
}
Any ideas?