我有一个问题:我将效果悬停在一个div中,但是当光标悬停在另一个div上时,我想触发该效果。就像是:
<div id='mouse-hover-in-this-div'>
blablabla
<div id='should-trigger-mouse-hover-in-this-div'></div>
</div>
我在这里看到了一些解决方案,但是它们没有用。特别是,我尝试使用jquery .css方法更改内部div的css属性,但未能成功提供以下选项:
-webkit-transform: translateY(16px);
transform: translateY(16px);
-webkit-animation-name: hang;
animation-name: hang;
-webkit-animation-duration: 1.5s;
animation-duration: 1.5s;
-webkit-animation-delay: 0.3s;
animation-delay: 0.3s;
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
-webkit-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-direction: alternate;
animation-direction: alternate;
我要悬停的悬停来自库hover.css,我只是希望在整个div悬停时触发箭头的反弹效果,而不仅仅是小箭头。有解决我问题的方法吗?
#outside-box:hover .animated-div {
-webkit-transform: translateY(6px);
transform: translateY(6px);
-webkit-animation-name: hang;
animation-name: hang;
-webkit-animation-duration: 1.5s;
animation-duration: 1.5s;
-webkit-animation-delay: 0.3s;
animation-delay: 0.3s;
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
-webkit-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-direction: alternate;
animation-direction: alternate;
}
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句