Added toggle functions. Dried up localstorage init.