-
Notifications
You must be signed in to change notification settings - Fork 233
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
Reloading state from HTML with colors? #120
Comments
I found a snippet that almost makes this work:
but as #114 states, you can't have a color and a font style at the same time. |
I have the same problem. No styles are carrying over to draft from I am using your snippet to try this and logging out the result of the
|
@gtwilliams03 same here , i console log the color and i have the same result did you manage to fix that if so please tell me how |
actually after spending 4 hours understanding how the plugin works and investigating more
|
I was struggling with this problem for few hours but but maybe this can be helpful for somebody else.
.... now I get the colors imported into my Editor. |
@RobertJoseR You just saved my day... For those that don't use typescript,
worked for me. |
@ckastrinos Do you have the |
Anyone knows how to add background-color for text. The solution given in #120 (comment) worked for text color. I want solution for the background color. I have tried the following code but it is not working.
|
Maybe useful for someone else: The following approach worked for me: |
If you are using react-draft-wysiwyg as your editor, this worked for me for font-color as well as background-color when converting html to editor state. Hope it helps. :)
But both font-color and background-color not working at the same time. Anyone have the solution so that font-color and background-color works at the same time? |
I added a color picker to my toolbar, had it change the color and stored it as HTML.
Now I want to edit the content again so I use:
The HTML I have is:
after I load the HTML back in I no longer have the color.
The text was updated successfully, but these errors were encountered: