Added auto image sizing