canvas-hypertxt
canvas-hypertxt copied to clipboard
Leading spaces are removed from all wrapped lines except the first
We are using this library to render text which the user can enter into a textarea to display as a "note" in a mapping/drawing app.
Using the text area, it's possible to add some rudimentary "formatting" by entering leading spaces, or adding lots of spaces between words.
These are lost when using this library, which loses the formatting. You can see the issue here where the text is laid out with canvas-hypertxt on the left and the textarea on the right:
The exact text is:
bbc.com and. another bbc.com
new line bbc.com
more
new
lines
bbc.com
will fix :)