Skip to content

Commit 081160a

Browse files
committed
fix: prevent shortcut loss on editor blur
1 parent f78af38 commit 081160a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

website/src/extensions/main/index.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -392,8 +392,7 @@ export const mainExt: IExtension = {
392392
}
393393
});
394394

395-
molecule.editor.onFocus((item) => {
396-
const groupId = (molecule.editor.getCurrentGroup() || -1) as UniqueId;
395+
molecule.editor.onModelMount((_, groupId) => {
397396
const tab = molecule.editor.getCurrentTab();
398397
if (tab?.id && tab.language) {
399398
molecule.editor.setCurrent(tab?.id, groupId);

0 commit comments

Comments
 (0)