make parseDOM() tag rule behave the same way style rule does #828
Unanswered
benmandr
asked this question in
Questions & Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The title might be a bit "bad". But examples explain what I have in mind perfectly:
I am trying to make bold extension work not only with
style
attribute, but also withclass
one.If I pass a text with font weight style (ex.
<h1 class="h2" style="font-weight:bold" >Text</h1>
), I get the following result:Parent node attributes are preserved (I have a custom Heading extension that preserves style and class attributes), but when I pass this
<h1 class="h-1" >Text</h1>
, and the TAG rule gets triggered, this is what I get:All my parent node styles/classes get reset to defaults. What can I do to avoid this behavior ?
Beta Was this translation helpful? Give feedback.
All reactions