mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-20 02:05:21 -04:00
fix(frontend): simplify asciinema regex
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
215ceea72c
commit
3f8771a15e
2 changed files with 7 additions and 8 deletions
|
@ -25,6 +25,12 @@ describe('Replace asciinema link', () => {
|
|||
)
|
||||
})
|
||||
|
||||
it('will replace a valid URL with appendix', () => {
|
||||
expect(markdownIt.renderInline('https://asciinema.org/a/123981234?a=1')).toBe(
|
||||
`<app-asciinema id='123981234'></app-asciinema>`
|
||||
)
|
||||
})
|
||||
|
||||
it("won't replace an URL without path", () => {
|
||||
expect(markdownIt.renderInline('https://asciinema.org/123981234')).toBe(`https://asciinema.org/123981234`)
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue