This repository has been archived by the owner on Feb 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add utilty methods for creating a new parent & updating node to becom…
…e sibling's child Summary: Implement some tree operations that will be used in the `NestedRichTextEditorUtil onTab` method. Specifically: - Creating a new parent for a node - Updating the node so that it is a child of its previous or next sibling The `onTab` use case is sketched out in the diagram below. The red stars represent the `createNewParent` operation & the red squares represent the `updateAsSiblingsChild` operation. {F137497472} (also added a new utility method `replaceParentChild` that switches one child for another & is used in createNewParent) Reviewed By: mitermayer Differential Revision: D9624285 fbshipit-source-id: f5701373ce1734cb8f21aca154ed45d656a47c54
- Loading branch information
1 parent
e2c24cf
commit 6f73657
Showing
3 changed files
with
1,700 additions
and
91 deletions.
There are no files selected for viewing
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.