Просмотр исходного кода

:bug: fix https://github.com/siyuan-note/siyuan/issues/5303

Vanessa 3 лет назад
Родитель
Сommit
dc0a6fa57c
2 измененных файлов с 2 добавлено и 0 удалено
  1. 1 0
      app/src/editor/index.ts
  2. 1 0
      app/src/protyle/index.ts

+ 1 - 0
app/src/editor/index.ts

@@ -62,6 +62,7 @@ export class Editor extends Model {
                 }
             },
         });
+        // 需在 after 回调之前,否则不会聚焦 https://github.com/siyuan-note/siyuan/issues/5303
         this.editor.protyle.model = this;
     }
 }

+ 1 - 0
app/src/protyle/index.ts

@@ -185,6 +185,7 @@ class Protyle {
                     });
                 }
             });
+            // 需等渲染完后再回调,用于定位搜索字段 https://github.com/siyuan-note/siyuan/issues/3171
             if (mergedOptions.after) {
                 mergedOptions.after(this);
             }