use immutable map for note objects
move toggleLocalHidden to NoteActions

for consistency sake
only call `setState` if notes changed

this improves performance, since setState needs to spend time diffing
even if nothing has changed.

we can only do this with immutable/persistent data structures, since
testing for equality for a non immutable data structure can return true
even if the constituants have changed