This commit is contained in:
Vanessa 2023-06-01 22:39:57 +08:00
parent 338851fcab
commit 1716436eca
13 changed files with 47 additions and 48 deletions

View file

@ -322,7 +322,7 @@ export const hintRef = (key: string, protyle: IProtyle, isQuick = false): IHintD
response.data.blocks.forEach((item: IBlock) => {
let iconHTML;
if (item.type === "NodeDocument" && item.ial.icon){
iconHTML = unicode2Emoji(item.ial.icon, false, "b3-list-item__graphic popover__block", true);
iconHTML = unicode2Emoji(item.ial.icon, "b3-list-item__graphic popover__block", true);
iconHTML = iconHTML.replace('popover__block"', `popover__block" data-id="${item.id}"`);
} else {
iconHTML = `<svg class="b3-list-item__graphic popover__block" data-id="${item.id}"><use xlink:href="#${getIconByType(item.type)}"></use></svg>`;
@ -386,7 +386,7 @@ export const hintEmbed = (key: string, protyle: IProtyle): IHintData[] => {
response.data.blocks.forEach((item: IBlock) => {
let iconHTML;
if (item.type === "NodeDocument" && item.ial.icon){
iconHTML = unicode2Emoji(item.ial.icon, false, "b3-list-item__graphic popover__block", true);
iconHTML = unicode2Emoji(item.ial.icon, "b3-list-item__graphic popover__block", true);
iconHTML = iconHTML.replace('popover__block"', `popover__block" data-id="${item.id}"`);
} else {
iconHTML = `<svg class="b3-list-item__graphic popover__block" data-id="${item.id}"><use xlink:href="#${getIconByType(item.type)}"></use></svg>`;