EntityNormalizer: Add colons to emoji alt text.
This makes it possible to copy them and still have them work.
This commit is contained in:
parent
5ac2c365a7
commit
f197a2aa39
@ -210,7 +210,7 @@ export const addEmojis = (string, emojis) => {
|
||||
const regexSafeShortCode = emoji.shortcode.replace(matchOperatorsRegex, '\\$&')
|
||||
return acc.replace(
|
||||
new RegExp(`:${regexSafeShortCode}:`, 'g'),
|
||||
`<img src='${emoji.url}' alt='${emoji.shortcode}' title='${emoji.shortcode}' class='emoji' />`
|
||||
`<img src='${emoji.url}' alt=':${emoji.shortcode}:' title=':${emoji.shortcode}:' class='emoji' />`
|
||||
)
|
||||
}, string)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user