JSFiddle - React, Tailwind, and code Playground
HTML
<div id="wrapper">
<div class="arrow">
</div>
<div class="arrow right">
</div>
</div>
CSS
#wrapper {
background:black;
overflow: hidden;
width: 600px;
height: 400px;
position: relative;
}
.arrow {
display:none;
overflow: hidden;
height: 100%;
position: absolute;
top: 0;
width: 50px;
background: red;
display: block;
}
.right {
right: 0;
}
JavaScript
$('#wrapper').hover(function() {
$('.arrow').stop(true,true).fadeIn();
}, function() {
$('.arrow').stop(true,true).fadeOut();
});