JSFiddle - React, Tailwind, and code Playground
HTML
<div class="module m-slide">
<img src="http://placehold.it/1200x800" alt="" />
<img src="http://placehold.it/1200x800" alt="" />
<div class="m-slide-ctrl">
<div class="dot"></div>
</div>
</div>
<p></p>
CSS
img {
max-width: 100%;
}
.module {
width: 350px;
position: relative;
}
.m-slide-ctrl {
position: absolute;
bottom: 15px;
right: 15px;
}
.dot {
width: 15px;
height: 15px;
background-color: #000;
border-radius: 15px;
display: inline-block;
}
.dot:hover {
opacity: 0.3;
}
JavaScript
var dot = '<div class="dot"></div>'
var number = 5;
for (var i = 0; i < number; i++) {
$(dot).appendTo('.m-slide-ctrl');
}