mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 00:20:47 +02:00
🎨 https://github.com/siyuan-note/siyuan/issues/15330 经查看 lute 现在没有限制,因此前端也移除对其的限制
This commit is contained in:
parent
03b83d1247
commit
b126d34dde
1 changed files with 10 additions and 17 deletions
|
@ -555,15 +555,11 @@ export class Gutter {
|
|||
public renderMultipleMenu(protyle: IProtyle, selectsElement: Element[]) {
|
||||
let isList = false;
|
||||
let isContinue = false;
|
||||
let hasEmbedBlock = false;
|
||||
selectsElement.find((item, index) => {
|
||||
if (item.classList.contains("li")) {
|
||||
isList = true;
|
||||
return true;
|
||||
}
|
||||
if (item.classList.contains("sb") || item.classList.contains("p")) {
|
||||
hasEmbedBlock = true;
|
||||
}
|
||||
if (item.nextElementSibling && selectsElement[index + 1] &&
|
||||
item.nextElementSibling === selectsElement[index + 1]) {
|
||||
isContinue = true;
|
||||
|
@ -612,19 +608,16 @@ export class Gutter {
|
|||
type: "Blocks2Blockquote"
|
||||
}));
|
||||
}
|
||||
// 多选引用转换为块的时候 id 不一致
|
||||
if (!hasEmbedBlock) {
|
||||
turnIntoSubmenu.push(this.turnsInto({
|
||||
menuId: "paragraph",
|
||||
icon: "iconParagraph",
|
||||
label: window.siyuan.languages.paragraph,
|
||||
accelerator: window.siyuan.config.keymap.editor.heading.paragraph.custom,
|
||||
protyle,
|
||||
selectsElement,
|
||||
type: "Blocks2Ps",
|
||||
isContinue
|
||||
}));
|
||||
}
|
||||
turnIntoSubmenu.push(this.turnsInto({
|
||||
menuId: "paragraph",
|
||||
icon: "iconParagraph",
|
||||
label: window.siyuan.languages.paragraph,
|
||||
accelerator: window.siyuan.config.keymap.editor.heading.paragraph.custom,
|
||||
protyle,
|
||||
selectsElement,
|
||||
type: "Blocks2Ps",
|
||||
isContinue
|
||||
}));
|
||||
turnIntoSubmenu.push(this.turnsInto({
|
||||
menuId: "heading1",
|
||||
icon: "iconH1",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue