Are there any hacks for max-width:-webkit-fit-content; , i.e. eight?
Trying to get a child div so as not to take the whole width of the parent, and this works well with ff, chrome and safari; hoping there would be a little hack to make it work with v. 8.
Script showing the behavior: http://jsfiddle.net/XtZq9/ Code for the behavior I want in ie8:
#wrap { background-color: aqua; width:300px; height: 50px; padding-top: 1px; } .textbox { background-color: yellow; max-width: intrinsic; max-width:-webkit-fit-content; max-width: -moz-max-content; margin-top: 2px; } <div id="wrap"> <div class="textbox"> Here is some text </div> <div class="textbox"> Here is other, longer, text </div> </div>
source share