1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2025-02-24 07:01:05 +00:00

Fixed newlines for sub lists

This commit is contained in:
M66B 2021-05-05 15:40:10 +02:00
parent 90a00eda1b
commit f6e3e63ee5

View file

@ -969,10 +969,14 @@ public class HtmlHelper {
// Lists // Lists
for (Element e : document.select("ol,ul,blockquote")) { for (Element e : document.select("ol,ul,blockquote")) {
if (view) { if (view) {
if (!"false".equals(e.attr("x-line-before"))) Element parent = e.parent();
e.attr("x-line-before", "true"); if ("blockquote".equals(e.tagName()) || parent == null ||
if (!"false".equals(e.attr("x-line-after"))) !("ol".equals(parent.tagName()) || "ul".equals(parent.tagName()))) {
e.attr("x-line-after", "true"); if (!"false".equals(e.attr("x-line-before")))
e.attr("x-line-before", "true");
if (!"false".equals(e.attr("x-line-after")))
e.attr("x-line-after", "true");
}
} else { } else {
String style = e.attr("style"); String style = e.attr("style");
e.attr("style", e.attr("style",