mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-21 22:44:06 +01:00
This commit is contained in:
parent
09a2177b3c
commit
5b29d16915
2 changed files with 2 additions and 2 deletions
|
|
@ -130,7 +130,7 @@ ${renewHTML}<div class="fn__hr--b"></div>`;
|
|||
</div>
|
||||
</div></div>`,
|
||||
bindEvent(modelMainElement: HTMLElement) {
|
||||
modelMainElement.addEventListener("click", (event) => {
|
||||
modelMainElement.firstElementChild.addEventListener("click", (event: MouseEvent) => {
|
||||
let target = event.target as HTMLElement;
|
||||
if (typeof event.detail !== "number") {
|
||||
target = event.detail;
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ export const initAssets = () => {
|
|||
icon: "iconImage",
|
||||
html: image.genHTML(),
|
||||
bindEvent(modelMainElement: HTMLElement) {
|
||||
image.element = modelMainElement;
|
||||
image.element = modelMainElement.firstElementChild;
|
||||
image.bindEvent();
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue