You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After applying "bold format" to only parts of a text in the editor, and then calling "dangerouslyPasteHTML()", the whole text becomes bold. I know in the documentation it says:
The snippet is interpreted by Clipboard matchers, which may not produce the exactly input HTML.
But to me this is a bug, so I'm posting this.
Note that this behaviour is also the case for "underline" and "italic" formatting. (This occurs only in my use-case, not in the codepen).
Paste: <div><p><strong>Heading (Bold)</strong></p><p>This should not be bold until the user decides to format it bold.</p><p>But instead "dangerouslyPasteHTML()" formats the whole text. </p><p>However it does this all the time. Try to "unbold" everything except the heading and try again.</p></div> into text input.
Click "pasteHtml" Button to paste it into the editor.
Click again to trigger the bug.
Expected behavior: Calling "dangerouslyPasteHTML()" with the same value should return the same HTML everytime it is called.
Actual behavior: Calling the function for the first time returns the correct HTML. For calling it the second time it has added <strong>-Tags to every node with text.
Platforms: Mac OSX Yosemite 10.10.3:
Chrome 54.0.2840.59 (64-bit)
Safari 8.0.6 (10600.6.3)
Firefox 49.0.2 Win10 v.1607:
Microsoft Edge 38.14393.0.0
Include browser, operating system and respective versions
Version: quill v1.1.0
Run v1.1.0 to find out
The text was updated successfully, but these errors were encountered:
philly385
changed the title
"dangerouslyPasteHTML()" applies format to whole text
calling "dangerouslyPasteHTML()" with same value wont always return the same HTML
Oct 21, 2016
philly385
changed the title
calling "dangerouslyPasteHTML()" with same value wont always return the same HTML
calling "dangerouslyPasteHTML()" with the same value wont always return the same HTML
Oct 21, 2016
After applying "bold format" to only parts of a text in the editor, and then calling "dangerouslyPasteHTML()", the whole text becomes bold. I know in the documentation it says:
But to me this is a bug, so I'm posting this.
Note that this behaviour is also the case for "underline" and "italic" formatting. (This occurs only in my use-case, not in the codepen).
Steps for Reproduction
<div><p><strong>Heading (Bold)</strong></p><p>This should not be bold until the user decides to format it bold.</p><p>But instead "dangerouslyPasteHTML()" formats the whole text. </p><p>However it does this all the time. Try to "unbold" everything except the heading and try again.</p></div>
into text input.Expected behavior: Calling "dangerouslyPasteHTML()" with the same value should return the same HTML everytime it is called.
Actual behavior: Calling the function for the first time returns the correct HTML. For calling it the second time it has added
<strong>
-Tags to every node with text.Platforms:
Mac OSX Yosemite 10.10.3:
Chrome 54.0.2840.59 (64-bit)
Safari 8.0.6 (10600.6.3)
Firefox 49.0.2
Win10 v.1607:
Microsoft Edge 38.14393.0.0
Include browser, operating system and respective versions
Version: quill v1.1.0
Run
v1.1.0
to find outThe text was updated successfully, but these errors were encountered: