slider refactoring

needs testing