How to make animations reliable in any context #12724
Description
I have a scenario where I'm distributing directives that represent UIs like dropdowns and modal dialogs. These directives come with styles, including animations, built-in. The animations rely on ngAnimate
. When these directives are used alone or in extremely simple situations, they appear to work as desired.
However, when the directives are composed into a more complex application contexts or are used to build new, more complicated directives, the animations no longer play as desired. Most especially, there are extremely common situations, such as when these directives are descendants of any element that uses ngIf
or ngShow
, where problems arise. It sounded like ngAnimateChildren
would help, but it does not behave as I expected.
I have created reduced test cases here: http://codepen.io/morewry/pen/VvwbrO