creating image slider for pc and mobile view