Would it be possible to add the following styling for <ins> and <del>?
ins { text-decoration: underline; }
del { text-decoration: line-through; }
Example:
But soft, what light through thatyonder window breaks?
Red for deletions and green for insertions are very much conventional. Word processor features, such as Word’s Track Changes, universally use underlining and strikeout, as well. The default stylesheet of my Chrome browser does likewise. But I just see background-colored text on Discourse forums.
I suspect Discourse’s CSS reset may be clobbering it.
So you are suggesting we use both color and underline / strikeout here? It’s fine with me, @awesomerobot if you want to fold that in it seems like a tiny easy change.
The norm in law is green text and underline for insertions and red text and strikethrough for deletions. I believe GitHub prose diff does green background and underline for insertions and red background and strikethrough for deletions.
I would strongly recommend combining color and text decoration. I have no strong opinion about whether to color text, background, or both, as long as the approach for insertions and deletions is the same.
It might also be worth thinking about dark mode. I just pulled up a GitHub prose diff, and it’s hard to see the styling on the dark mode background grey.
I noticed that GitHub only does underline and strikeout for <ins> and <del> in comments. But I can confirm that I really miss the color. It’s hard to pick out all the changes to a big chunk of content at a glance without the color cues.
Perhaps @ThunderThighs would like styles for mark.red, mark.green, mark.blue, and so on?
Many friends who use highlighters enjoy having several colors of them.
You might also consider :before and :after content for screen readers if the color coding is important. Otherwise, I understand that many screen readers do not pronounce mark tags, just their contents.