public IBlockElement Execute(IBlock block) { Markdig.Syntax.ParagraphBlock paragraph = (Markdig.Syntax.ParagraphBlock)block; Logger.LogDebug($"The paragraph being parsed: {paragraph.Lines}"); return(new Paragraph { Inlines = Parser.Process(paragraph.Inline)?.ToList() }); }
public void Visit(Paragraph paragraph) { var paragraphBlock = new MD.ParagraphBlock(); _block = paragraphBlock; foreach (IInline inline in paragraph.Inlines) { //Visit(inline); } Document.Add(paragraphBlock); }
public static string ToMarkdownString(this Markdig.Syntax.ParagraphBlock paragraphBlock) { var str = string.Empty; str += paragraphBlock.Inline.ToMarkdownString(); if (paragraphBlock.IsBreakable) { str += "\n"; } return(str); }