I want to display an image like in the screenshot below. It should start inside the grid but scale to the left or right of the screen.
At the moment, I'm not sure how to achieve this because the container limits the with. But I need the container to let it start inside the grid?!
I've tried this: Extend bootstrap row outside the container
Here's the code:
#main {
background: lightgreen;
height: 100vh;
}
#main > .row {
height: 100vh;
}
.left {
background: red;
position: relative;
top: 50%;
transform: translateY(-50%);
}
.left:before {
left: -999em;
background: red;
content: '';
display: block;
position: absolute;
width: 999em;
top: 0;
bottom: 0;
}
<div class="container" id="main">
<div class="row">
<div class="col-lg-6 left">
..
</div>
</div>
</div>
But the solution isn't working with images.