diff --git a/lib/convert.js b/lib/convert.js index 2516e40..c82a6b5 100644 --- a/lib/convert.js +++ b/lib/convert.js @@ -65,7 +65,7 @@ function getBodyXML(chapter, contentEl) { contentEl.removeChild(contentEl.lastElementChild); } - // Remove redundant attributes + // Remove redundant attributes and style Array.prototype.forEach.call(contentEl.children, child => { if (child.getAttribute("dir") === "ltr") { child.removeAttribute("dir"); @@ -78,6 +78,9 @@ function getBodyXML(chapter, contentEl) { if (child.getAttribute("style") === "text-align:left;") { child.removeAttribute("style"); } + if (child.getAttribute("style") === "text-align:left;padding-left:30px;") { + child.setAttribute("style", "padding-left:30px;"); + } }); // Remove empty s and s