[evolution] I#1679 - e-convert.js: Do not re-wrap gmail_quote paragraphs ][



commit 406f1a242e32b4727e00df40084cf6b3f0643822
Author: Milan Crha <mcrha redhat com>
Date:   Mon Nov 8 15:27:50 2021 +0100

    I#1679 - e-convert.js: Do not re-wrap gmail_quote paragraphs ][
    
    Fix a test case for list items.
    
    Related to https://gitlab.gnome.org/GNOME/evolution/-/issues/1679

 data/webkit/e-convert.js | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/data/webkit/e-convert.js b/data/webkit/e-convert.js
index 580e5ccb93..a1fe4a4422 100644
--- a/data/webkit/e-convert.js
+++ b/data/webkit/e-convert.js
@@ -914,11 +914,12 @@ EvoConvert.processNode = function(node, normalDivWidth, quoteLevel)
 
                        var childrenWillWrap = true;
                        if (!node.classList.contains("gmail_quote")) {
+                               childrenWillWrap = node.childNodes.length > 0 && liText == "";
                                var ii;
                                for (ii = 0; childrenWillWrap && ii < node.childNodes.length; ii++) {
                                        var child = node.childNodes.item(ii);
                                        childrenWillWrap = (child.nodeType == child.ELEMENT_NODE &&
-                                                          (child.tagName == "DIV" ||
+                                                          ((child.tagName == "DIV" && 
!child.getAttribute("x-evo-li-text")) ||
                                                            child.tagName == "P" ||
                                                            child.tagName == "PRE" ||
                                                            child.tagName == "BLOCKQUOTE" ||


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]