-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
selection event should trigger when the element changes node type #1156
Comments
Thanks, but that’s still the same selection, so I won’t expect the event to be triggered. As you said, you'd probably use the onUpdate event to listen for updates. ✌️ |
True... ish? IMO - the selection has changed in that If I tap an arrow key to move my cursor, the event fires, which makes sense since the resolvedPos changes. I think the same is true here. I guess this is an upstream issue anyhow... |
What happens?
I expect the
selection
event to be triggered when the focussed element changes type. It doesn'tHow can others reproduce the issue?
selection
listener to the documenteditor.chain().focus().toggleHeading({ level: 1 }).run()
selection
event does not fire, even though we've now focussed a different elementWhat behavior did you expect?
Since the node changes, I expected the
selection
event to trigger.Do you have a screenshot?
What’s your environment?
What else?
I can use the
update
event instead, but that feels like overkill for my requirement.The text was updated successfully, but these errors were encountered: