diff --git a/src/html_epub_preprocessor.py b/src/html_epub_preprocessor.py index 06878de..ce262cb 100644 --- a/src/html_epub_preprocessor.py +++ b/src/html_epub_preprocessor.py @@ -404,6 +404,7 @@ def preprocess_pre_tags(chapter_tag): if isinstance(child, NavigableString): child.text = escape(pre.text) pre.name = 'span' + pre.attrs['style'] = "white-space: pre-wrap;" wrap_span_with_table(chapter_tag, pre)