do not construct Markdown links in code spans and code blocks
Signed-off-by: chrispy <chrispy@synopsys.com>
This commit is contained in:
@@ -264,6 +264,8 @@ class MarkdownConverter(object):
|
||||
return '\n\n%s\n%s\n\n' % (text, pad_char * len(text)) if text else ''
|
||||
|
||||
def convert_a(self, el, text, convert_as_inline):
|
||||
if el.find_parent(['pre', 'code', 'kbd', 'samp']):
|
||||
return text
|
||||
prefix, suffix, text = chomp(text)
|
||||
if not text:
|
||||
return ''
|
||||
|
||||
Reference in New Issue
Block a user