This repository has been archived by the owner on Sep 6, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
for #10634 Element duplication when copying root node #10653
Open
xyin96
wants to merge
4
commits into
adobe:master
Choose a base branch
from
xyin96:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
Fantastic. Glad to see a patch for this so quickly. @xyin96++ |
Just tested this code and I'm getting an error in the console: "data-brackets-id=1 not found". |
Yeah this patch generates that error. I don't know how to fix it, but from what I've noticed, the referenced id is the tagID of the old html tag, which I assume has been replaced and deleted when the user copies and pastes an html document into the editor. |
gideonthomas
added a commit
to mozilla/brackets
that referenced
this pull request
Mar 13, 2015
gideonthomas
added a commit
to gideonthomas/brackets
that referenced
this pull request
Mar 13, 2015
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
for #10634
fixed element duplication when copy/pasting html tag.
The issue was sending a null as the oldElement in generateChildEdits, which implies an insertion edit.
The fix was to check if there was a root node in the oldNodeMap, and passing that node as the oldElement so that generateChildEdits had a node to compare to.