I have a parent div that has scroll enabled and a width limit, underneath it I have another div with content.
I want to centralize this content in relation to the parent div so that the content is centralized, note:
<div class="scroll">
<div class="content">
00000000000000000111000000000000000000
</div>
</div>
.scroll {
overflow:auto;
width: 100px;
background-color:black;
}
.content {
background-color:red;
display:inline-block;
}
In this way only 0
appear but in the centralized way would appear the 1
also.
Are there any tricks in CSS or jQuery / JavaScript to accomplish such?