mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 15:10:12 +01:00
🚨
This commit is contained in:
parent
a03dda30ea
commit
20270f67e9
6 changed files with 9 additions and 9 deletions
|
|
@ -822,7 +822,7 @@ app.whenReady().then(() => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
});
|
});
|
||||||
ipcMain.on("siyuan-send_windows", (event, data) => {
|
ipcMain.on("siyuan-send_windows", (event, data) => {
|
||||||
BrowserWindow.getAllWindows().forEach(item => {
|
BrowserWindow.getAllWindows().forEach(item => {
|
||||||
|
|
|
||||||
|
|
@ -73,4 +73,4 @@ export const globalClick = (event: MouseEvent & { target: HTMLElement }) => {
|
||||||
) {
|
) {
|
||||||
currentPDFViewerObject.findBar.close();
|
currentPDFViewerObject.findBar.close();
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
|
||||||
|
|
@ -1308,10 +1308,10 @@ export const sendGlobalShortcut = (app: App) => {
|
||||||
app.plugins.forEach(plugin => {
|
app.plugins.forEach(plugin => {
|
||||||
plugin.commands.forEach(command => {
|
plugin.commands.forEach(command => {
|
||||||
if (command.globalCallback) {
|
if (command.globalCallback) {
|
||||||
hotkeys.push(command.customHotkey)
|
hotkeys.push(command.customHotkey);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
ipcRenderer.send(Constants.SIYUAN_HOTKEY, {
|
ipcRenderer.send(Constants.SIYUAN_HOTKEY, {
|
||||||
languages: window.siyuan.languages["_trayMenu"],
|
languages: window.siyuan.languages["_trayMenu"],
|
||||||
id: getCurrentWindow().id,
|
id: getCurrentWindow().id,
|
||||||
|
|
|
||||||
|
|
@ -115,4 +115,4 @@ export const windowKeyUp = (app: App,event:KeyboardEvent, switchDialog:Dialog)
|
||||||
switchDialog = undefined;
|
switchDialog = undefined;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
|
||||||
|
|
@ -253,7 +253,7 @@ export const bindMenuKeydown = (event: KeyboardEvent) => {
|
||||||
|| event.altKey || event.shiftKey || isCtrl(event)) {
|
|| event.altKey || event.shiftKey || isCtrl(event)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
const target = event.target as HTMLElement
|
const target = event.target as HTMLElement;
|
||||||
if (window.siyuan.menus.menu.element.contains(target) && (target.tagName === "INPUT" || target.tagName === "TEXTAREA")) {
|
if (window.siyuan.menus.menu.element.contains(target) && (target.tagName === "INPUT" || target.tagName === "TEXTAREA")) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -150,10 +150,10 @@ export const insertHTML = (html: string, protyle: IProtyle, isBlock = false,
|
||||||
editableElement.innerHTML = replaceInnerHTML;
|
editableElement.innerHTML = replaceInnerHTML;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const editWbrElement = editableElement.querySelector("wbr")
|
const editWbrElement = editableElement.querySelector("wbr");
|
||||||
if (editWbrElement && editableElement && !trimStartText.endsWith("\n")) {
|
if (editWbrElement && editableElement && !trimStartText.endsWith("\n")) {
|
||||||
// 数学公式后无换行,后期渲染后添加导致 rang 错误,中文输入错误 https://github.com/siyuan-note/siyuan/issues/9054
|
// 数学公式后无换行,后期渲染后添加导致 rang 错误,中文输入错误 https://github.com/siyuan-note/siyuan/issues/9054
|
||||||
const previousElement = hasPreviousSibling(editWbrElement) as HTMLElement
|
const previousElement = hasPreviousSibling(editWbrElement) as HTMLElement;
|
||||||
if (previousElement && previousElement.nodeType !== 3 && previousElement.dataset.type.indexOf("inline-math") > -1 &&
|
if (previousElement && previousElement.nodeType !== 3 && previousElement.dataset.type.indexOf("inline-math") > -1 &&
|
||||||
!hasNextSibling(editWbrElement)) {
|
!hasNextSibling(editWbrElement)) {
|
||||||
editWbrElement.insertAdjacentText("afterend", "\n");
|
editWbrElement.insertAdjacentText("afterend", "\n");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue