Is there a way to detect using JavaScript / jQuery if the element is end-to-end and underlined.
So, let's say we have:
<u><s>text here.</s>other text here.</u>
Is it possible to determine if the text is underlined inside <s>?
* Ideally, it will not be allowed to see if there are any <u>for children <s>.
I did this, and it seems strange that both styles use the same CSS property, which in turn makes me wonder how it works even in the first place.
To make my problem more clear:
I play with the homemade wysiwyg editor, for reasons of ease of use, I am trying to implement a text listener that modifies (lights up) the edit buttons. for example, when part of the text is in bold, the “B” button will go into an active state. I am currently processing this by getting the element in the cursor and checking if the element is bold or inherits it.
The problem with underline and line is that they do not overwrite text-decoration attribute from each other and are not visible in css
, text-decoration underline, - underline line-through. , <u> <s>; , <s> 100 .
, , - .