initial code of loading imgaes previews inside the list