mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-24 02:20:13 +01:00
This commit is contained in:
parent
2850ab3feb
commit
407eb53ea1
1 changed files with 7 additions and 0 deletions
|
|
@ -2641,6 +2641,13 @@ export class WYSIWYG {
|
|||
if (attrElement) {
|
||||
newRange = setLastNodeRange(attrElement.previousElementSibling, newRange, false);
|
||||
}
|
||||
// https://github.com/siyuan-note/siyuan/issues/14481
|
||||
const inlineMathElement = hasClosestByAttribute(newRange.startContainer, "data-type", "inline-math");
|
||||
if (inlineMathElement) {
|
||||
newRange.setEndAfter(inlineMathElement);
|
||||
newRange.collapse(false);
|
||||
focusByRange(newRange);
|
||||
}
|
||||
/// #if !MOBILE
|
||||
if (newRange.toString().replace(Constants.ZWSP, "") !== "") {
|
||||
protyle.toolbar.render(protyle, newRange);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue