Render text editor contents inside shadow DOM

Closes #1800

## Tasks

* [x] Fix git diff styling
* [x] Fix specs
* [x] Fix loss of ability to insert text after autocompleting when the menu doesn't pop up
* [x] Add a feature flag
Well, not quite. It's still there but no more reason to call it out in a class specifically.