mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-17 06:05:29 +01:00
This commit is contained in:
parent
0e3a56826d
commit
2260832ae6
2 changed files with 5 additions and 5 deletions
|
|
@ -128,8 +128,7 @@ export const initAnno = (element: HTMLElement, pdf: any) => {
|
|||
}
|
||||
};
|
||||
});
|
||||
|
||||
element.addEventListener("click", (event) => {
|
||||
element.firstElementChild.addEventListener("click", (event: MouseEvent) => {
|
||||
let processed = false;
|
||||
let target = event.target as HTMLElement;
|
||||
if (typeof event.detail === "string") {
|
||||
|
|
|
|||
|
|
@ -102,8 +102,10 @@ export class Asset extends Model {
|
|||
this.element.innerHTML = `<div class="asset"><video controls="controls" src="${this.path.startsWith("file") ? this.path : document.getElementById("baseURL").getAttribute("href") + "/" + this.path}"></video></div>`;
|
||||
} else if (type === ".pdf") {
|
||||
/// #if !MOBILE
|
||||
if (isInit) {
|
||||
this.element.innerHTML = `<div class="pdf__outer" id="outerContainer">
|
||||
if (!isInit) {
|
||||
this.pdfObject.close();
|
||||
}
|
||||
this.element.innerHTML = `<div class="pdf__outer" id="outerContainer">
|
||||
<div id="sidebarContainer">
|
||||
<div id="toolbarSidebar">
|
||||
<div id="toolbarSidebarLeft">
|
||||
|
|
@ -478,7 +480,6 @@ export class Asset extends Model {
|
|||
</div>
|
||||
</div> <!-- outerContainer -->
|
||||
<div id="printContainer"></div>`;
|
||||
}
|
||||
const localPDF = window.siyuan.storage[Constants.LOCAL_PDFTHEME];
|
||||
const pdfTheme = window.siyuan.config.appearance.mode === 0 ? localPDF.light : localPDF.dark;
|
||||
const darkElement = this.element.querySelector("#pdfDark");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue