add max-width/height properties