forked from LiveCarta/BookConverter
fix heading in json
This commit is contained in:
@@ -37,10 +37,10 @@ class JSONConverter:
|
|||||||
:param ind: Index of header in content list.
|
:param ind: Index of header in content list.
|
||||||
"""
|
"""
|
||||||
if self.content[ind].name in LawCartaConfig.SUPPORTED_HEADERS:
|
if self.content[ind].name in LawCartaConfig.SUPPORTED_HEADERS:
|
||||||
title = self.content[ind].text
|
title = self.content[ind]
|
||||||
curr_outline = int(re.sub(r"^h", "", self.content[ind].name)) # extract outline from tag
|
curr_outline = int(re.sub(r"^h", "", self.content[ind].name)) # extract outline from tag
|
||||||
result = {
|
result = {
|
||||||
'title': title,
|
'title': f'{title}',
|
||||||
'contents': [],
|
'contents': [],
|
||||||
'sub_items': []
|
'sub_items': []
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user