I want to avoid squeezing of elements when using the below CSS code, especially for Chrome browser, ver. 39.
This CSS code works well on Chrome ver. 46. But I need to use old version like v.39 of Google Chrome. Because I use this version as a wrapper to create a desktop PC application.
Here is the squeezing effect which I want to avoid:
Here it looks fine:
#bascket {
overflow: hidden;
position: absolute;
width: 100%;
height: 52.9%;
top: 14.72%;
left: 0px;
background: rgb(255, 255, 255);
outline: none;
cursor: -webkit-grab;
display: flex;
flex-direction: column-reverse;
flex-grow: 1;
flex-shrink: 1;
justify-content: flex-start;
}
<div id="bascket">
<div class="order-item">
<div class="oi-p1">1</div>
<div class="oi-p2">Item Name 1</div>
<div class="oi-p3"></div>
<div class="oi-p4">77</div>
</div>
<div class="order-item">
<div class="oi-p1">1</div>
<div class="oi-p2">Item Name 2</div>
<div class="oi-p3"></div>
<div class="oi-p4">77</div>
</div>
<div class="vertical-line-1"></div>
<div class="vertical-line-2"></div>
</div>
This is a web app wrapped into a desktop application. And what i do here is just adding items to bascket area. I use this javascript code to add items:
var bascket = document.getElementById("bascket");
var item = document.createElement("DIV");
item.innerHTML = "...see the above full html code sample"
bascket.insertBefore(item, bascket.firstChild);
If I do this:
document.getElementById('bascket').style.height = '100%';
Then it is better, but this changes item display, and I lose the bottom which shows the last item , see this image:
I think I should play with height stretch and fit, but I cannot find how to do that