add cookie for slider to track state