css3 - 用angularjs给元素添加和删除样式类时,css规定的transition动画未出现
黄舟
黄舟 2017-04-17 11:11:16
0
1
658

css

我在css中定义了上面这样的动画,想通过添加/删除.checked类来控制img元素淡入淡出。

html

这个.checked是用angularjsng-class来添加和删除的,也就是上面红色框里的hideCheck变量为true,则添加这个类,为false,则删除这个类。

javascript

然后如上图,我在js代码中赋值hideCheckfalse,然后再赋值为true,没有发生任何动画效果,请问应该怎样才能使动画出现?

黄舟
黄舟

人生最曼妙的风景,竟是内心的淡定与从容!

reply all(1)
左手右手慢动作

Write transition inside checked.

Also, I want to complain, why do so many people here like to post codes into pictures? Is it so difficult to format the code here? If the question you asked contained a little more code, would you still be thinking about someone else typing the code in it line by line?

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template