-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Inline styling lost after loading/pasting html #1580
Comments
This is a high priority issue for us, we need the ability to initialize the editor with some pre-existing HTML with inline styling. |
Is there a workaround for this? |
yeah switch to a different editor lmao |
Downgrade to version 1.0.3. (bug started with version 1.0.4) This bug only happens when the font family has quotes. import Quill from 'quill'; let Font = Quill.import('attributors/style/font'); Quill.register(Font); |
The expected case for text indent is replace with a tab character, which it already does. can't understand where you told about tab character |
I am still having this issue with version 1.3.6 with code based on this example: https://stackoverflow.com/questions/43728080/how-to-add-font-types-on-quill-js-with-toolbar-options (And the issue is -- still -- with font families having white space(s) included in their names.) The key difference compared with the test code here is how the font "module" is imported: |
how to solve this? |
@drego, Did you fix this? Still having the issue |
I've found a workaround.
Worked for me. |
Wow.... When you use
end result would be But when u change only import to After hour of search I have found out this ...which in documentation can not be found. Nice! Thank you @pdkovacs |
I'm currently trying to use Quill to create an editor and be able to format an email in HTML.
In order to allow the styling of the email content I'm using only inline styling attributes instead of the quill classes.
However, when I try to load or paste the html content into the editor, some of the inline styles are ignored/removed. I noticed that some of the inline styles (like color, background-color,text-align) are kept but others are just removed (for instance some font families and text-indent).
Here is a verifiable example of this problem.
Steps for Reproduction
Expected behavior:
The fonts and indent specified by inline styling should be recognized and kept by Quill.
Actual behavior:
Some fonts are kept and others are removed when loading Quill. Text indent specified by inline styling is also removed.
Platforms:
Google Chrome Version 58.0.3029.110 (64-bit)
Version:
1.2.6
The text was updated successfully, but these errors were encountered: