Skip to content

Conversation

@tf
Copy link
Member

@tf tf commented Jan 27, 2026

When selecting text right-to-left and clicking outside the contenteditable to deselect, Chrome triggers toSlateRange with a selection pointing outside the editor, causing an error. This workaround catches the error and returns the current editor selection, mimicking the upstream suppressThrow fix (ianstormtaylor/slate#4584).

When selecting text right-to-left and clicking outside the
contenteditable to deselect, Chrome triggers toSlateRange with a
selection pointing outside the editor, causing an error. This
workaround catches the error and returns the current editor selection,
mimicking the upstream suppressThrow fix (ianstormtaylor/slate#4584).
@tf tf added this to the v17.2 milestone Jan 27, 2026
@tf tf merged commit f614c0e into codevise:master Jan 27, 2026
18 checks passed
@tf tf deleted the slate-workaround branch January 27, 2026 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant