When I set overflow: scroll
to a div, I'm expecting to have a scrollbar even when the content doesn't scroll (for design purposes)
but when there's no need to scroll, chrome mobile hides the scrollbar anyway.
.div-scroll{
background-color: red;
height: 300px;
overflow-y: scroll;
}
.div-inner {
background-color: blue;
height: 200px;
}
<div class="div-scroll">
<div class="div-inner">
</div>
</div>
I'd like to show a disabled scroll on Chrome Mobile when the content doesn't scroll, or at least a way to know from pure CSS that it doesn't scroll, to avoid using width: calc(100% - 17px);