CSS Transition on Hover

后端 未结 6 651
再見小時候
再見小時候 2021-01-28 13:50

I have a problem. I actually try to do a transition at a div when I hover the mouse over an object. So basically I have a div, and when I hover my mouse the div, it should displ

6条回答
  •  有刺的猬
    2021-01-28 14:23

    #on-hover {
        opacity: 0;
        transition: opacity 0.5s;
        -webkit-transition: opacity 0.5s;
    }
    #first:hover #on-hover {
        opacity: 1;
    }
    

    This is only about the animation. A more detailed example here: http://jsfiddle.net/ELa6X/

提交回复
热议问题