Highlight by text-color instead of background-color
golopot opened this issue · comments
Chiawen Chen commented
Highlight like a normal text editor does.
This might be achieved by hiding the textarea and showing the fake layer.
Will Boyd commented
I didn't think this would work because of issues with selecting text and caret visibility, but... it totally works. :) Will test further and consider more cases.
Test CSS:
.hwt-content {
color: transparent;
caret-color: black; /* Edge ignores this, but luckily doesn't need it */
}
.hwt-highlights {
color: black !important;
}
.hwt-content mark {
color: red;
background-color: transparent;
}