소스 검색

:recycle:

Vanessa 2 년 전
부모
커밋
4f9dd50364
1개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 3 3
      app/src/protyle/header/Title.ts

+ 3 - 3
app/src/protyle/header/Title.ts

@@ -146,12 +146,12 @@ export class Title {
                 });
             } else {
                 const iconRect = iconElement.getBoundingClientRect();
-                this.renderMenu(protyle, iconElement, {x: iconRect.left, y: iconRect.top + 14});
+                this.renderMenu(protyle, {x: iconRect.left, y: iconRect.top + 14});
             }
         });
         this.element.addEventListener("contextmenu", (event) => {
             if (getSelection().rangeCount === 0) {
-                this.renderMenu(protyle, iconElement, {x: event.clientX, y: event.clientY});
+                this.renderMenu(protyle, {x: event.clientX, y: event.clientY});
                 return;
             }
             protyle.toolbar?.element.classList.add("fn__none");
@@ -269,7 +269,7 @@ export class Title {
         }, Constants.TIMEOUT_INPUT);
     }
 
-    private renderMenu(protyle: IProtyle, iconElement: Element, position: { x: number, y: number }) {
+    private renderMenu(protyle: IProtyle, position: { x: number, y: number }) {
         fetchPost("/api/block/getDocInfo", {
             id: protyle.block.rootID
         }, (response) => {