"Hover Effect on Product image"
Bootstrap 4.1.1 Snippet by limon

<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <!------ Include the above in your HEAD tag ----------> <!DOCTYPE html> <html> <body> <div class="product"> <img src="http://bestjquery.com/tutorial/product-grid/demo9/images/img-1.jpg" > <div class="overlay"> <div class="add-cart"> <ul style=""> <li><button>Add To Cart</button></li> <li ><button>Add To Cart</button></li> <li ><button>Add To Cart</button></li> </ul> </div> </div> </div> </body> </html>
.product{ width:400px; height: 400px; position: relative; } .product img{ width: 400px; height: 400px; } .overlay{ position: absolute; top: 0; left: 0; width:400px; height:0px; transition: 0.6s; background: red; opacity: 0.8; } .product:hover .overlay{ height: 400px; } .add-cart{ position: absolute; bottom: 10%; text-align: center; opacity: 0; transition: height 500ms ease 0s; } .overlay:hover .add-cart{ opacity: 1; width: 400px; } .add-cart ul{ margin:0;padding: 0; } .add-cart ul li{ list-style-type: none;display: inline-block; }

Related: See More


Questions / Comments: