Pasting in Firefox strips line endings
Closed this issue · 3 comments
Lexikos commented
When I paste v1 code into the translator using Firefox 91.0.2, the v1 code ends up on one line, as though each line ending has been replaced with a single space. I have disabled all addons and tested in a Private Window. It does not occur in Chrome.
FuPeiJiang commented
but when you copy from v1 <textarea>, the newlines are still there
hmmmm
FuPeiJiang commented
it's because I have style="white-space: nowrap;"
on the <textarea>
I don't remember why I put white-space: nowrap
oh, it's so that long lines don't wrap
FuPeiJiang commented
I tried these and white-space: pre;
is what I want
https://developer.mozilla.org/en-US/docs/Web/CSS/white-space
I also tested on chromium Edge lol
thanks for the issue title, I'll use that as commit message