Bug: Lexical RichText is not keeping empty lines between sentences on specific case
- Dominant language
- TypeScript
- Stars
- 23.9k
- Forks
- 2.2k
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 61
Description
Lexical version: 0.11.3
## Steps To Reproduce
1. Create and send an Email using Gmail
1.1. The email needs to have empty lines between paragraphs
2. Copy email's body
The pasted DataTransfer data
```html
Text
Text 2
Text 3
```
3. Paste email's body specifically on Lexical RichText Editor
Link to code example: [CodeSandBox](https://codesandbox.io/s/dazzling-stonebraker-8pwxhw?file=/src/Editor.js)
## The current behavior
| Creating email | Copying email | Pasting on Lexical Rich Text Editor |
| --- | --- | --- |
| |
|
|
## The expected behavior
Expect Lexical RichText Editor to keep empty lines between sentences
Contributor guide
Research direction
Start with the linked CodeSandbox at src/Editor.js and reproduce the Gmail HTML paste in the Lexical RichText Editor. Trace how the pasted DataTransfer HTML is handled, using the supplied empty div and br cases as the fixture. Done means the editor preserves the empty lines between Text, Text 2, Text 3, and Text 4.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100