Support math rendering on MFM (#3260)
This commit is contained in:
parent
d2385a0e52
commit
ad84901f39
7 changed files with 75 additions and 0 deletions
|
|
@ -53,6 +53,12 @@ const handlers: { [key: string]: (window: any, token: any, mentionedRemoteUsers:
|
|||
document.body.appendChild(element);
|
||||
},
|
||||
|
||||
math({ document }, { formula }) {
|
||||
const element = document.createElement('code');
|
||||
element.textContent = formula;
|
||||
document.body.appendChild(element);
|
||||
},
|
||||
|
||||
link({ document }, { url, title }) {
|
||||
const a = document.createElement('a');
|
||||
a.href = url;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue