Here I’ve got some simple jQuery which sets the height of a series of floated elements based on their width. Inside each element I have an image, which is forced to remain inside the floated elements using max-width and max-height.
This almost works perfectly. Chrome is giving me grief. While viewing that fiddle in Chrome, restore down Chrome and reduce Chrome’s width. Then, maximize Chrome. The images do not scale as they should.
I’ve tested this in Firefox, Internet Explorer, and Chrome. Chrome is the only one of those three that exhibits this behavior. How can I fix this??
The solution ended up being to use jQuery to “jiggle” the containing element, forcing Chrome to reevaluate the sizing of the contained images.
The jsFiddle
The new jQuery:
EDIT:
For anyone reading this later, this bug has been fixed. The original code (linked to in the question) now works.