NodeView Deselect on Type

Apologies if I missed something obvious in the docs or in existing threads but I have a NodeView that contains some complex media controls and when a node of that type is selected and I type a single character the deselectNode() function is called.

The characters are not entered into the document and the node is not removed, so all I need to do is not remove selection on the node when I type, is there something I am missing?

By default, typing when a node is selected replaces the node with the inserted text. Any idea why that is not happening in this case?

Sorry, I didn’t give enough information.

The node in question is an atom, it has the non-editable div and then a series of descendants including a media player/editor. I am attempting to make sure the shortcuts and mousewheel events that the media editor needs are properly passed down to it.

As far as I can tell, PM is always the focused/active dom element so I intended to pass the events down through using the NodeView, but in order to ensure that this instance of the node is the one that should receive these events I was trying to check if the node was selected which, after typing the shortcut, it is not.

If there is a better approach here that I am missing I would gladly pivot.

I believe the reason a key is not wiping out the selected node is because the NodeView has an update() function that returns true. If I set it to false then it behaves as you expect and replaces the node with the typed character.

Is the method checking the type of the new node it is passed? Or does it always return true, even when given an incompatible node type?