You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-07-28 15:22:05 +03:00
match all, not just first instance of tokens to escape
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
@ -51,9 +51,9 @@ describe('editor/serialize', function() {
|
||||
});
|
||||
it('displaynames containing an opening square bracket work', function() {
|
||||
const pc = createPartCreator();
|
||||
const model = new EditorModel([pc.userPill("Displayname[", "@user:server")]);
|
||||
const model = new EditorModel([pc.userPill("Displayname[[", "@user:server")]);
|
||||
const html = htmlSerializeIfNeeded(model, {});
|
||||
expect(html).toBe("<a href=\"https://matrix.to/#/@user:server\">Displayname[</a>");
|
||||
expect(html).toBe("<a href=\"https://matrix.to/#/@user:server\">Displayname[[</a>");
|
||||
});
|
||||
it('displaynames containing a closing square bracket work', function() {
|
||||
const pc = createPartCreator();
|
||||
|
Reference in New Issue
Block a user