-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
[lexical-text] Test for handling multiple matches on hashtags #6056
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
bf6448e
to
3178daa
Compare
2024-05-08.11.32.08.movNow it seems to work well. cc @Sahejkm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi thanks @2wheeh, we could pull now for the tests to pass, then will approve and close this.
5c7e10f
to
4d0ed6e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks for adding extensive tests for this!
Description
#6053 deleted escape on adjacent next matches. but it turns out it was needed in different place (probably after replacement for current match has done ?)without it, editor breaks on pasting or importing text that has adjacent matches.=> #6067
And
nodeToReplace
can beundefined
implicitly. Now it's the case. So I added null check for it.This could occur in other places especially around
TextNode.splitText()
unless we use--noUncheckedIndexedAccess
.Test plan
Before
2024-05-08.6.17.02.mov
2024-05-08.6.18.39.mov
2024-05-08.6.41.48.mov
After
2024-05-08.6.27.26.mov
2024-05-08.6.43.12.mov