Refactor note-toggle (part 2)

This PR abstracts user data into a config object, adds a few helper utils and has moved create note at caret into its own module.

### QA
- Test creating new notes without a selection heavily 
Nit picking now, but:

1. Clearer as `key.replace('-data', '')`?
2. And maybe avoid mutating `key` as that could be confusing/makes the two lines dependent on each other.