diff --git a/toMkdocs/toMkdocs.py b/toMkdocs/toMkdocs.py index 34b414f7cd595d0c6fbb26698b921611bc3cc02d..83d2b47c83f79c64edc840e96a8fc18e1aab9b87 100644 --- a/toMkdocs/toMkdocs.py +++ b/toMkdocs/toMkdocs.py @@ -34,7 +34,7 @@ class LineType(Enum): @dataclass class Line: """ Represents a line in the markdown file. """ - text:str + text:str = '' lineType:LineType = LineType.TEXT @@ -345,7 +345,8 @@ def prepareForMkdocs(clauses:list[Clause], includeHangingParagraphs:bool = False if not includeHangingParagraphs: clauses[i].lines = [] else: - clauses[i].lines = [Line("<mark>Editor note: This is a hanging paragraph and it must be moved to its own clause</mark>")] + clauses[i].lines + clauses[i].title = "Hanging Paragraph" + clauses[i].lines = [Line("<mark>Editor note: This is a hanging paragraph and it must be moved to its own clause</mark>"), Line()] + clauses[i].lines # Repair wrong markdown for indented lines. # Add 2 spaces to existing 2-space indentions