mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-02-25 23:50:51 +08:00
fix: 前端修改:图片loading做一个适配,现在图片没加载出来会出现如下情况, 不丝滑
This commit is contained in:
@@ -48,7 +48,7 @@ function tiebaEmojiPlugin(md) {
|
||||
md.renderer.rules['tieba-emoji'] = (tokens, idx) => {
|
||||
const name = tokens[idx].content
|
||||
const file = tiebaEmoji[name]
|
||||
return `<img class="emoji" src="${file}" alt="${name}">`
|
||||
return `<BaseImage class="emoji" src="${file}" alt="${name}">`
|
||||
}
|
||||
md.inline.ruler.before('emphasis', 'tieba-emoji', (state, silent) => {
|
||||
const pos = state.pos
|
||||
|
||||
@@ -77,7 +77,7 @@ export function createVditor(editorId, options = {}) {
|
||||
const list = await fetchMentions(key)
|
||||
return list.map((u) => ({
|
||||
value: `@[${u.username}]`,
|
||||
html: `<img src="${u.avatar}" /> @${u.username}`,
|
||||
html: `<BaseImage src="${u.avatar}" /> @${u.username}`,
|
||||
}))
|
||||
},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user