Open petervukovic opened 2 years ago
facing the same problem
facing the same problem as well
Any progress on this? Even sitting on a wired fiber connection, I get disconnected from Sanity so often that I feel like I have to compose in Word. Then when I paste in my content, I have to go back and add spaces. Not cool.
almost 2 years later and i'm still having this too. I'm trying to use the <> code format on code blocks in block content, and none of the indentation comes through. There's gotta be solution for this.
Describe the bug
When you copy & paste a piece of plain text that contains multiple spaces and indents, the spaces aren't preserved.
To Reproduce
Expected behavior
Line breaks and spaces should be preserved as in the above example.
Actual behavior
While line breaks get preserved, all extraneous spaces are removed, resulting in this output:
Which versions of Sanity are you using?
What operating system are you using?
OSX Catalina 10.15.7
Which versions of Node.js / npm are you running?
Run
npm -v && node -v
in the terminal and copy-paste the result here.Additional context
I discovered this problem while building a custom style block for preformatted text. My intention was to support copying/pasting plain text snippets (such as ASCII art or code) into the text editor in order to display them on the blog. Unfortunately, this is impossible due to the way the text editor behaves today, and building a custom paste handler for this seems like overkill.