hide function moved after slider init