mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-21 15:56:10 +01:00
This commit is contained in:
parent
1e11df1222
commit
27d36e776b
1 changed files with 3 additions and 3 deletions
|
|
@ -1003,12 +1003,12 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
|
||||
if (matchHotKey(window.siyuan.config.keymap.editor.general.quickMakeCard.custom, event)) {
|
||||
const selectElement: Element[] = [];
|
||||
if (!hasClosestByClassName(nodeElement, "protyle-wysiwyg--select")) {
|
||||
nodeElement.classList.add("protyle-wysiwyg--select");
|
||||
}
|
||||
protyle.wysiwyg.element.querySelectorAll(".protyle-wysiwyg--select").forEach(item => {
|
||||
selectElement.push(item);
|
||||
});
|
||||
if (selectElement.length === 0) {
|
||||
selectElement.push(nodeElement)
|
||||
}
|
||||
quickMakeCard(selectElement);
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue