remove ticks from codeblock
This commit is contained in:
parent
af97f6b291
commit
784f353487
1 changed files with 6 additions and 2 deletions
|
|
@ -34,9 +34,9 @@ let toCSS = (message, currentStream) => {
|
|||
content = re_path.exec(message.content)[1];
|
||||
return { className: '', emoji_code: '', rules: [], parentClassName: '', id: id, content: font(content), type: type }
|
||||
} else if (is_codeblock) {
|
||||
return { className: '', emoji_code: '', rules: [], parentClassName: '', id: id, content: content, type: type }
|
||||
return { className: '', emoji_code: '', rules: [], parentClassName: '', id: id, content: cleanupCodeBlock(content), type: type }
|
||||
} else if (results.length > 0) { // rule and raw
|
||||
className = emoji.methods.shortcodeToEmoji(results[0]['groups']['selector']);
|
||||
className = emoji.methods.replaceAllEmojiCodes(results[0]['groups']['selector']);
|
||||
if (emoji.methods.containsEmoji(className)) {
|
||||
emoji_code = emoji.methods.toEmojiCode(className);
|
||||
}
|
||||
|
|
@ -48,6 +48,10 @@ let toCSS = (message, currentStream) => {
|
|||
return null;
|
||||
}
|
||||
|
||||
let cleanupCodeBlock = (content) => {
|
||||
return content.replaceAll('```', '');
|
||||
}
|
||||
|
||||
let font = (content) => {
|
||||
let font = {
|
||||
family: "",
|
||||
|
|
|
|||
Loading…
Reference in a new issue