Show content when hovering over DIV

后端 未结 4 1757
余生分开走
余生分开走 2021-02-14 01:18

Is it possible to show content when hovering over the DIV. See Image

When I hover over the div, the transition takes place, but is it possible to show content inside the

4条回答
  •  执笔经年
    2021-02-14 01:59

    Yes, it is possible.

    But wrap your .flowingdown within a div. Inorder to show the entire content,

    CSS:

    .flowingdown {
        width:1045px;
        background-image:url(http://i.imgur.com/hHUa9Ty.jpg);
        height:50px;
        float:left;
        margin-top:2px;
        margin-bottom:2px;
        border-radius:0 0 55px 55px;
        transition: height 1s;
        -webkit-transition: height 1s;
    }
    .flowingdown:hover {
        height:100%; //Inorder to show the entire content within the parent.
    }
    

    Check this JSFiddle

提交回复
热议问题