Summary: Fixed a bug bug with the quoted text clearing the bodies on replies
Test Plan: all the tests
Reviewers: dillon, bengotow
Reviewed By: bengotow
Differential Revision: https://phab.nylas.com/D1981
Summary: fix(service): Remove redundant tail newline when hiding previous in compose view. Fixes T2467.
Test Plan: Added a test to verify that all tail newlines are removed except one. Added another to verify that non-tail newlines aren't removed. Tweaked an existing test to make it pass.
Reviewers: bengotow
Reviewed By: bengotow
Maniphest Tasks: T2467
Differential Revision: https://phab.nylas.com/D1864
Summary:
We need to remove quoted text completely from bodies in a composer.
Unfortunately, that makes it very difficult to determine how to put it
back in.
For now the scheme is to append the quoted text at the end. However, that
means that we need to only pull out quoted text at the end of a message.
Unfortunately there are lots of places that quoted text appears inline
with regular text.
Determining whether or not some content is at the "end" of a message
turned out to be non-trivial.
We now have a new `DOMUtils` that looks for empty areas at the end.
We also have a new quoted HTML parser that finds trailing quotes.
Fixes T2335
Test Plan: lots of new quoted text tests
Reviewers: bengotow
Reviewed By: bengotow
Maniphest Tasks: T2335
Differential Revision: https://phab.nylas.com/D1773