I'm looking to enhance my video by adding images and icons using CSS, but I'm not sure how to go about it.
The image that will serve as a profile picture and the icons should be similar to the ones shown in the image below:
https://i.sstatic.net/icFVW.jpg
I've attempted to use position: absolute
, transform: translate(-50%, -50%)
, and bottom: 100%
, but unfortunately, this method hasn't been successful. Here's what I've tried so far, but I'm struggling to get it right:
This design includes Bootstrap-5 classes and Video.js with Google icons incorporated.
.img_wrapper.a img {
position: absolute;
transform: translate(-50%, -50%);
bottom: 100%;
}
.thumb{
width: 30px;
height: auto;
}
<link href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="c7a5a8a8b3b4b3b5a6b787f2e9f7e9f5">[email protected]</a>/dist/css/bootstrap.min.css"
rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC"
crossorigin="anonymous">
<link rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="debcb1b1aaadaaacbfaef3b7bdb1b0ad9eeff0efeef0ea">[email protected]</a>/font/bootstrap-icons.css">
<link href="https://vjs.zencdn.net/8.0.4/video-js.css" rel="stylesheet" />
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="15524754515527253b3b212d">[email protected]</a>,100..700,0..1,-50..200" />
<div class="container">
<div class="row justify-content-center">
<div class="col-md-2">
<div class="row">
<video id="my-video"
class="video-js text-center"
controls
preload="auto"
height="400px"
data-setup="{}"
poster="https://thumbs.dreamstime.com/b/confident-black-business-man-stylish-suit-standing-folded-arms-rooftop-n-office-block-looking-camera-69650703.jpg"
muted>
<source src="" type="video/mp4">
</video>
<div class="img_wrapper">
<a style="text-decoration: none;" href="{{ video.get_user_public_url }}">
<p><img class="rounded-circle thumb" src="https://thumbs.dreamstime.com/b/confident-black-business-man-stylish-suit-standing-folded-arms-rooftop-n-office-block-looking-camera-69650703.jpg" alt="">
<b>Bamagujen Bahaushe</b>
</p>
</a>
</div>
<div class="video-icons">
<a href="">
<span class="material-symbols-outlined">
fingerprint
</span>
</a>
<a href="{% url 'Play-Video' video.slug %}">
<span class="material-symbols-outlined">
comment
</span>
</a>
<a href="{% url 'Complain-Video' video.pk %}">
<span class="material-symbols-outlined">
flag
</span>
</a>
</div>
</div>
</div>
<div class="col-md-6">
<div class="content-right">
<p>Lorem ipsum dolor sit, amet consectetur
adipisicing elit. Qui, minus, optio atque nostrum
repellendus delectus eos non veritatis,
illum soluta quas id aliquid facilis molestiae
facere nam neque? Fugiat, repellendus.</p>
</div>
</div>
</div>
</div>