make condition for cylce slideshow