I'm trying to have a bootstrap 4 carousel use a landscape or portrait image as background for an item depending on the device orientation ...
following simplified code works somehow (with some style in the head) but I cannot find info on image-set so I do not know how to substitute 1x and 2x with landscape and portrait (or if that can be done):
<div class="container">
<div class="outer">
<div class="inner"
style="background-image: url('landscape.jpg');
background-image: -webkit-image-set(
url('landscape.jpg') 1x,
url('portrait.jpg') 2x);
background-image: -image-set(
url('landscape.jpg') 1x,
url('portrait.jpg') 2x)">
test
</div>
</div>
</div>
did someone get something like this to work, or does someone have a better approach ?