A single HTML blank line from a gmail pastes into a WF note as 7 blank lines

I regularly copy/paste text from a gmail message into a WF note (not node). When the gmail message includes a single line break (a new line but no blank line), then the result matches the original as expected.

But when there is a blank line in the pasted text (i.e. 0D0A0D0A in the plain text version), then Gmail’s HTML rendering is more complicated (see below), and WF interprets the single blank line as 7 blank lines, presumably from over-interpreting the <div> and/or <span> tags.

I expect that this will be easy to reproduce, but for reference, gmail’s HTML rendering to clipboard is below (with style details removed for ease of reading).

Sometimes a workaround is to paste plain text, but of course that loses any useful formatting. Or to paste to nodes and then to copy/paste those nodes to the note, but then the blank lines are gone, and it’s a lot more work.

This bug has been present for many months, perhaps since the old opposite bug was fixed (where such text pasted into a note stripped out all line breaks).

4.3.2611251320 [beta, edge, win], also 4.3.2611241705-beta [desktop, win]

Here’s the clipboard HTML copied from such a gmail:

<html>
<body>
<!--StartFragment-->
<span style="…">This is para 1, followed by no blank line. </span>
<div style="…">This is para 2, followed by one blank line.</div>
<div style="…"><span style="background-color: transparent;"><br></span></div>
<div style="…"><span style="background-color: transparent;">This is para 3, followed by no blank line. </span></div>
<!--EndFragment-->
</body>
</html>
1 Like