View: don't destroy book on close

The book object is not created by the view class so it has no business
destroying it.

Fix bug caused by 1e952102bd where closing
the footnote view destroys the book, when it should not be destroyed,
being still displayed by another view
This commit is contained in:
John Factotum
2024-09-30 18:50:07 +08:00
parent 4cd2ca2eb3
commit 916dfb13ac
-1
View File
@@ -175,7 +175,6 @@ export class View extends HTMLElement {
close() {
this.renderer?.destroy()
this.renderer?.remove()
this.book?.destroy?.()
this.#sectionProgress = null
this.#tocProgress = null
this.#pageProgress = null