refactored sliders and fixed firefox js