fix resizing images in gallery component