Sfoglia il codice sorgente

:art: fix https://github.com/siyuan-note/siyuan/issues/12230

Vanessa 9 mesi fa
parent
commit
ef8561cf18
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  1. 4 0
      app/src/protyle/util/selection.ts

+ 4 - 0
app/src/protyle/util/selection.ts

@@ -538,6 +538,7 @@ export const focusBlock = (element: Element, parentElement?: HTMLElement, toStar
             range.collapse(true);
             setRange = true;
         } else if (type === "NodeAttributeView") {
+            /// #if !MOBILE
             const cursorElement = element.querySelector(".av__cursor");
             if (cursorElement) {
                 range.setStart(cursorElement.firstChild, 0);
@@ -545,6 +546,9 @@ export const focusBlock = (element: Element, parentElement?: HTMLElement, toStar
             } else {
                 return false;
             }
+            /// #else
+            return false;
+            /// #endif
         }
         if (setRange) {
             focusByRange(range);