Emulating a specific CSS hover effect -
i'm trying emulate hover effect can see here: http://www.timeout.com/newyork (when hover on articles.)
i understand how make div move on :hover, don't understand how they've hidden "read more" button until div hovered over.
essentially know how hide div until mouse over, have slide out under another.
here pure css solution hacked up: css hover effect
h1, h2, h3, h4, h5{ margin:0px; } .tile{ overflow: hidden; width: 400px; height:350px; } .tile:hover > .body{ transition: 0.5s ease; top: -3em; } .body{ transition: 0.5s ease; background-color: #333; margin:0px; color: #fafafa; padding: 1em; position:relative; top: -1em; }
<div class="tile"> <img src="http://lorempixel.com/400/300"> <div class="body"> <h2>test header</h2> <p>info display</p> </div> </div>
basically, change position of text div when hover on main div , add transition animation it.
Comments
Post a Comment