JSFiddle - React, Tailwind, and code Playground
HTML
<a href="#">
<div class="img">
<img src="https://habrastorage.org/files/ec1/b4b/00d/ec1b4b00d1a549eda30833f87de77246.png" alt="">
<div class="hover"><img src="http://www.huubdesign.com.au/skin/frontend/default/custom/images/search-icon-hi.png" alt=""></div>
</div>
</a>
CSS
.hover img {width: 80px; height: 80px;}
.img {
position: relative;
width: 170px;
}
.hover {
position: absolute;
top: 0;
left: 0;
background: rgba(116, 119, 208, 0.74);
width: 100%;
height: 100%;
text-align: center;
opacity: 0;
transition: opacity .2s ease-out;
}
.hover img {
transform: translateY(-50%) translateX(-50%);
position: absolute;
top: 50%;
left: 50%;
}
a:hover .hover {opacity: 1;}