
Подробное описание и демонстрацией работы эффекта наведения под номером №102 для бибилиотеки Bootstrap. Html и CSS код для реализации hover effect как на изображении.
html разметка для реализации данного эффекта<div class="container"> <div class="row"> <div class="col-md-4 col-sm-6"> <div class="box"> <img src="https://fokit.ru/demo/images/hover-effect/hover-effect-style-102/img-1.jpg" alt=""/> <div class="box-content"> <ul class="icon"> <li><a href="#"><i class="fa fa-search"></i></a></li> <li><a href="#"><i class="fa fa-link"></i></a></li> </ul> <h3 class="title">willimson</h3> </div> </div> </div> <div class="col-md-4 col-sm-6"> <div class="box"> <img src="https://fokit.ru/demo/images/hover-effect/hover-effect-style-102/img-2.jpg" alt=""/> <div class="box-content"> <ul class="icon"> <li><a href="#"><i class="fa fa-search"></i></a></li> <li><a href="#"><i class="fa fa-link"></i></a></li> </ul> <h3 class="title">Kristiana</h3> </div> </div> </div> </div> </div>css разметка для реализации данного эффекта
.box{ text-align: center; position: relative; box-shadow: 0 0 5px #a3a3a3; } .box img{ width: 100%; height: auto; } .box .box-content{ width: 100%; height: 100%; background: transparent; padding-top: 25%; position: absolute; top: 0; left: 0; transition: all 0.3s ease 0s; } .box:hover .box-content{ background: rgba(0,0,0,0.5); } .box .title{ font-size: 24px; color: #fff; text-transform: capitalize; transform: scale(0); transition: all 0.2s ease 0s; } .box:hover .title{ transform: scale(1); } .box .icon{ list-style: none; padding: 0; margin: 0; opacity: 0; transition: all 0.2s ease 0s; } .box:hover .icon{ opacity: 1; } .box .icon li{ display: inline-block; } .box .icon li:first-child a, .box .icon li:last-child a{ display: block; width: 50px; height: 50px; line-height: 50px; font-size: 24px; color: #fff; border: 1px solid #fff; position: relative; } .box .icon li a{ top: -150px; } .box:hover .icon li a{ top: 0; } .box:hover .icon li a:hover{ background: #a46789; border-color: #a46789; } .box .icon li:first-child a{ transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0s; } .box .icon li:last-child a{ transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.1s; } @media only screen and (max-width:990px){ .box{ margin-bottom: 30px; } } @media only screen and (max-width:360px){ .box .box-content{ padding-top: 20%; } }