added transition on slides
refactored change slides