-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Preserve list indentation from one DraftEditor to another on paste
Summary: **Summary** When pasting from one editor to another we lose list indentation. By inspecting the classList of each list item contained in HTML pasted we can preserve this state. **Test Plan** I validated behavior manually: - Rebuild - Open two tabs to rich text example - In one create indented list - Select all - Paste into other - Styling is preserved I also added some snapshot testing for regression testing. Closes facebookarchive/draft-js#1605 Reviewed By: flarnie Differential Revision: D6702583 Pulled By: flarnie fbshipit-source-id: 071cecc786e2aaef11af9bd21cc03f9b2544a2b4
- Loading branch information
1 parent
09aa0d5
commit eb4ef09
Showing
3 changed files
with
420 additions
and
0 deletions.
There are no files selected for viewing
360 changes: 360 additions & 0 deletions
360
src/model/encoding/__tests__/__snapshots__/convertFromHTMLToContentBlocks-test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.