mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-04-21 11:27:27 +08:00
fix: 修复贴吧表情显示问题
This commit is contained in:
@@ -48,7 +48,7 @@ function tiebaEmojiPlugin(md) {
|
|||||||
md.renderer.rules['tieba-emoji'] = (tokens, idx) => {
|
md.renderer.rules['tieba-emoji'] = (tokens, idx) => {
|
||||||
const name = tokens[idx].content
|
const name = tokens[idx].content
|
||||||
const file = tiebaEmoji[name]
|
const file = tiebaEmoji[name]
|
||||||
return `<BaseImage class="emoji" src="${file}" alt="${name}">`
|
return `<img class="emoji" src="${file}" alt="${name}">`
|
||||||
}
|
}
|
||||||
md.inline.ruler.before('emphasis', 'tieba-emoji', (state, silent) => {
|
md.inline.ruler.before('emphasis', 'tieba-emoji', (state, silent) => {
|
||||||
const pos = state.pos
|
const pos = state.pos
|
||||||
|
|||||||
Reference in New Issue
Block a user