Emphasis around link doesn't get parsed
I'm having an issue trying to parse a markdown which has some emphasis around a link.
- [x]
Parser - [ ]
HtmlRenderer - [ ]
Formatter - [ ]
FlexmarkHtmlParser - [ ]
DocxRenderer - [ ]
PdfConverterExtension - [ ] extension(s)
To Reproduce
Here is an **$[example](https://www.example.com)**
I'm setting the options with setFrom(ParserEmulationProfile.MARKDOWN), and have a few extensions:
TablesExtension.create(),
StrikethroughExtension.create(),
AttributesExtension.create(),
FootnoteExtension.create(),
WikiLinkExtension.create(),
GitLabExtension.create(),
Expected behavior
I would expect the document to parse to an AST with Document->Paragraph->"Here is an "Emphasis->Link
Resulting Output
However the Emphasis is omitted and I can only find the link inside the paragraph, and the asterisks are left as plain text.
Is there any settings I'm missing or is this expected behavior? Is there any way to parse the emphasis regardless if it wraps a link?
It turns out I had a custom extension that removed the emphasis node. Closing.
Actually, I noticed that if a space is included between the link and the asterisks, the issue persists:
Here is an ** $[example](https://www.example.com) **.
This will keep the asterisks instead of wrapping with an emphasis node.
Works as designed. Changing this behaviour would adversely affect existing documents. The Markdown specification suggests that only *** stars *** directly touching text are interpreted as a style (emphasis, bold, or bold emphasis) for the text that they touch.