parpalak / upmath.me

Markdown and LaTeX online editor - create text for web with equations and diagrams
https://upmath.me/
MIT License
323 stars 40 forks source link

hide underliying textarea completly #17

Closed sajozsattila closed 3 years ago

sajozsattila commented 4 years ago

First of all thanks, your amazing work. I have a minor suggestion: I am a little bit annoyed with the input textarea still visible. It is changing the colours of the code highlight, and sometimes even visible. So I recommend changing the CSS from:

.ldt textarea {  
    color: rgba(0,0,0,0.6) !important;     
}

to:

.ldt textarea {
    color: rgba(0,0,0,0.0) !important; 
    caret-color: rgb(255, 255, 255, 1);
}
parpalak commented 4 years ago

It's a trade-off for old browsers that do not support caret-color property. It was annoying for me too, so I used a hack for modern webkit browsers with the -webkit-text-fill-color property. Works fine in Chrome, Firefox and Edge. And still somehow works in other old browsers.

parpalak commented 3 years ago

I've moved to the caret-color property instead of-webkit-text-fill-color. I've decided to set opacity to 10% and not to hide textarea completely because it helps when debugging cases like this: https://github.com/parpalak/upmath.me/issues/22