mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-06 16:58:49 +01:00
This commit is contained in:
parent
d355423cab
commit
559ef4aae7
1 changed files with 3 additions and 1 deletions
|
|
@ -689,7 +689,9 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
// https://github.com/siyuan-note/siyuan/issues/5547
|
||||
const previousSibling = hasPreviousSibling(range.startContainer) as HTMLElement;
|
||||
if (range.startOffset === 1 && range.startContainer.textContent === Constants.ZWSP &&
|
||||
previousSibling && previousSibling.nodeType !== 3) {
|
||||
previousSibling && previousSibling.nodeType !== 3 &&
|
||||
event.key === "Backspace" // https://github.com/siyuan-note/siyuan/issues/6786
|
||||
) {
|
||||
if (previousSibling.classList.contains("img")) {
|
||||
previousSibling.classList.add("img--select");
|
||||
} else if (previousSibling.getAttribute("data-type")?.indexOf("inline-math") > -1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue