This commit is contained in:
parent
c4f318f805
commit
892d166acf
2 changed files with 7 additions and 10 deletions
|
@ -46,13 +46,11 @@ export const hintSlash = (key: string, protyle: IProtyle) => {
|
|||
filter: ["ai chat"],
|
||||
value: Constants.ZWSP + 5,
|
||||
html: '<div class="b3-list-item__first"><svg class="b3-list-item__graphic"><use xlink:href="#iconSparkles"></use></svg><span class="b3-list-item__text">AI Chat</span></div>',
|
||||
}];
|
||||
allList.push({
|
||||
},{
|
||||
filter: ["数据库", "属性视图", "shujuku", "shuxingshitu", "sjk", "sxst", "database", "attribute view"],
|
||||
value: '<div data-type="NodeAttributeView" data-av-type="table"></div>',
|
||||
html: `<div class="b3-list-item__first"><svg class="b3-list-item__graphic"><use xlink:href="#iconDatabase"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.database}</span></div>`,
|
||||
});
|
||||
[{
|
||||
}, {
|
||||
filter: ["文档", "子文档", "wendang", "wd", "ziwendang", "zwd", "xjwd"],
|
||||
value: Constants.ZWSP + 4,
|
||||
html: `<div class="b3-list-item__first"><svg class="b3-list-item__graphic"><use xlink:href="#iconFile"></use></svg><span class="b3-list-item__text">${window.siyuan.languages.newFile}</span><span class="b3-menu__accelerator">${updateHotkeyTip(window.siyuan.config.keymap.general.newFile.custom)}</span></div>`,
|
||||
|
@ -248,13 +246,10 @@ export const hintSlash = (key: string, protyle: IProtyle) => {
|
|||
filter: ["移除样式", "yichuyangshi", "ycys", "remove style"],
|
||||
value: `style${Constants.ZWSP}`,
|
||||
html: `<div class="b3-list-item__first"><div class="color__square">A</div><span class="b3-list-item__text">${window.siyuan.languages.clearFontStyle}</span></div>`,
|
||||
}].forEach(item => {
|
||||
allList.push(item);
|
||||
});
|
||||
allList.push({
|
||||
},{
|
||||
value: "",
|
||||
html: "separator",
|
||||
});
|
||||
}];
|
||||
let hasPlugin = false;
|
||||
protyle.app.plugins.forEach((plugin) => {
|
||||
plugin.protyleSlash.forEach(slash => {
|
||||
|
|
|
@ -784,7 +784,9 @@ ${genHintItemHTML(item)}
|
|||
} else if (value === "---") {
|
||||
focusBlock(nodeElement);
|
||||
} else if (nodeElement.classList.contains("av")) {
|
||||
avRender(nodeElement, protyle);
|
||||
avRender(nodeElement, protyle, () => {
|
||||
focusBlock(nodeElement);
|
||||
});
|
||||
} else {
|
||||
focusByWbr(nodeElement, range);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue