1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-08 21:42:24 +03:00

Treat links as external in report content admin message

This marks all the links in the report content admin message (in Markdown
format) as external so they open in a new tab.
This commit is contained in:
J. Ryan Stinnett
2020-01-22 22:08:34 +00:00
parent 2e0977fb0c
commit a504faa2f6
2 changed files with 20 additions and 2 deletions

View File

@@ -102,7 +102,7 @@ export default class ReportEventDialog extends PureComponent {
SdkConfig.get().reportEvent.adminMessageMD;
let adminMessage;
if (adminMessageMD) {
const html = new Markdown(adminMessageMD).toHTML();
const html = new Markdown(adminMessageMD).toHTML({ externalLinks: true });
adminMessage = <p dangerouslySetInnerHTML={{ __html: html }} />;
}