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
Bug: Pasting lists on lists results in potentially reordered content #4723
Comments
I believe the issue is definitely within this block. If I can find some time I'll do some more investigation. |
This cannot be resolved while #5124 is out there, as the behavior that is intended to handle the node insertion is broken by the fact that an empty You can test this by pasting from outside the editor, like a list from google docs, and it pastes in just fine (and as we'd expect it). The reason the re-order happens is because it ends up being treated as a whole new |
To be clear, this is the line where it fouls up. The Because of this, it ends up getting appended to the end instead of inserted as one would expect. |
@9larsons are you open to fixing this upstream? |
This seems resolved when testing again in |
Lexical version: v0.11.1
Steps To Reproduce
The current behavior
See gif above. Pasted content can be re-ordered relative to what was in the document which is definitely unintentional (ie not all pasted content is inserted at the same spot).
The expected behavior
I'd expect content to be pasted and at least maintain the correct ordering. I feel like the indentation behavior is subjective. For example, Google Docs will paste lists relative to the current indendation/list depth, while Lexical appears to paste relative to parent nodes.
The text was updated successfully, but these errors were encountered: