`handleClickOn` in footnote nodeView considered not inside

Hi y’all!

Our editor uses footnotes whose implementation is inspired by the footnote example. We use react-prosemirror, but I don’t think this is relevant for the problem we are facing.

We also use a plugin to modify the behaviour of internal links to open them inside the application. For that, we use handleClickOn() to trigger the internal state change and handleDOMEvents() to prevent the default behaviour. In the main editor, the plugin works well.

Yet in the subordinate footnote editor, handleClickOn() does not fire. We suspect the following:

I frankly don’t thoroughly understand the logic around NodeViewDesc, but this behaviour seems odd. Is there a way to avoid it?

A workaround we found is using handleClick instead of handleClickOn but that might have other consequences that we are unaware of.

Thank you.

Are you registering the handleClickOn handler in the inner editor, or only the outer one?