Add saving to block prefs

Preferences are saved to localstorage