add loading to gallery