
Подробное описание и демонстрацией работы эффекта наведения под номером №84 для бибилиотеки 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-84/img-1.jpg"> <div class="icon"> <a href="#" class="icon1"><i class="fa fa-link"></i></a> <a href="#" class="icon2"><i class="fa fa-plus"></i></a> </div> <div class="box-content"> <h3 class="title">Williamson</h3> <span class="post">web designer</span> </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-84/img-2.jpg"> <div class="icon"> <a href="#" class="icon1"><i class="fa fa-link"></i></a> <a href="#" class="icon2"><i class="fa fa-plus"></i></a> </div> <div class="box-content"> <h3 class="title">Kristiana</h3> <span class="post">web designer</span> </div> </div> </div> </div> </div>css разметка для реализации данного эффекта
.box{ position: relative; overflow: hidden; text-align: center; } .box:after{ content: ""; width: 100%; height: 100%; position: absolute; top: 0; left: 0; background-color: rgba(0,0,0,0.6); opacity: 0; transition: all 0.5s ease 0s; } .box:hover:after{ opacity: 1; } .box img{ width: 100%; height: auto; } .box .icon1, .box .icon2{ display: inline-block; width: 50px; height: 50px; line-height: 50px; border-radius: 50%; margin-right: 20px; background: #dff3e4; position: absolute; top: 35%; opacity: 0; z-index: 2; transition: all 0.5s ease 0s; } .box .icon1{ left: 15%; } .box:hover .icon1{ left: 30%; opacity: 1; } .box .icon2{ right: 15%; } .box:hover .icon2{ right: 30%; opacity: 1; } .box .icon a{ display: block; font-size: 22px; color: #1ed295; } .box .box-content{ width: 100%; background: #1ed295; position: absolute; bottom: -100%; left: 0; padding: 15px 0; color: #fff; z-index: 2; transition: all 0.5s ease 0s; } .box:hover .box-content{ bottom: 0; } .box .title{ font-size: 24px; margin: 0; } .box .post{ display: block; font-size: 14px; text-transform: capitalize; margin-top: 5px; } @media only screen and (max-width:990px){ .box{ margin-bottom: 30px; } } @media only screen and (max-width:480px){ .box:hover .icon1{ left: 27%; } .box:hover .icon2{ right: 27%; } }