Underline and strikethrough getting lost when changing font size

1 Answer 106 Views
Editor
Shane
Top achievements
Rank 2
Iron
Iron
Iron
Shane asked on 28 Apr 2022, 06:18 PM

I am losing underline and strikethrough when I change font size, foreColor or backColor. I am changing the default font and font size in onMount.

const styles = `p {font-family: EYInterstate; font-size: 14px;}`;

const onMount = (event) => {
const iframeDocument = event.dom.ownerDocument;
const style = iframeDocument.createElement('style');
style.appendChild(iframeDocument.createTextNode(styles));
iframeDocument.head.appendChild(style);
};

 

Not sure if that is causing this. Any ideas?

 

1 Answer, 1 is accepted

Sort by
0
Accepted
Filip
Telerik team
answered on 29 Apr 2022, 11:51 AM

Hi, Shane,

I tried to reproduce the mentioned behavior in this example:

https://stackblitz.com/edit/react-1tyqho?file=app/main.jsx

But it seems that both strikethrough and underlining are working as expected.

Can you please provide an example that reproduces this behavior so that I can inspect it further?

Regards, FilipProgress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Shane
Top achievements
Rank 2
Iron
Iron
Iron
commented on 29 Apr 2022, 02:41 PM

seems this was the whole problem

removing this defaultEditMode seems to make everything work.

thank you

/*defaultEditMode="div"*/

Tags
Editor
Asked by
Shane
Top achievements
Rank 2
Iron
Iron
Iron
Answers by
Filip
Telerik team
Share this question
or