I want add color and background color to text like this way
<span style="color: #ff0000; background-color: #00ff00'>123</span>
I want achieve these with a single mark with color and background attrs;
If I use “style” to match the DOM in parseDOM, then I will lose the previous attribute. I can only keep one of color or backgroundColor because they belong to different parsing rules.
If I using ‘tag’ to match DOM and parse style attribute by myself. I may lost style when they are not using the tag I specific;
if I using multi mark to achieve these. It will render like below which I do not want.
Any suggestion?Thanks