fix(LocalBook/EpubFile): remove next chapter duplicated title
This commit is contained in:
1 parent
2c57e8e651
commit
6a1b01e631
1 file changed
+4
-1
@@ -159,7 +159,10 @@ class EpubFile(var book: Book) {
|
|||||||
body.getElementById(startFragmentId)?.previousElementSiblings()?.remove()
|
body.getElementById(startFragmentId)?.previousElementSiblings()?.remove()
|
||||||
}
|
}
|
||||||
if (!endFragmentId.isNullOrBlank() && endFragmentId != startFragmentId) {
|
if (!endFragmentId.isNullOrBlank() && endFragmentId != startFragmentId) {
|
||||||
body.getElementById(endFragmentId)?.nextElementSiblings()?.remove()
|
body.getElementById(endFragmentId)?.run {
|
||||||
|
nextElementSiblings()?.remove()
|
||||||
|
remove()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
/*选择去除正文中的H标签,部分书籍标题与阅读标题重复待优化*/
|
/*选择去除正文中的H标签,部分书籍标题与阅读标题重复待优化*/
|
||||||
val tag = Book.hTag
|
val tag = Book.hTag
|
||||||
|
|||||||
Reference in new issue
Block a user