mirror of
https://github.com/xoofx/markdig.git
synced 2026-11-16 17:30:52 +00:00
fix whitespace in HtmlBlock within ListItemBlock
This commit is contained in:
@@ -876,10 +876,13 @@ namespace Markdig.Parsers
|
||||
{
|
||||
if (!result.IsDiscard())
|
||||
{
|
||||
bool isParagraph = block is ParagraphBlock;
|
||||
if (TrackTrivia && isParagraph)
|
||||
if (TrackTrivia)
|
||||
{
|
||||
UnwindAllIndents();
|
||||
if (block is ParagraphBlock ||
|
||||
block is HtmlBlock)
|
||||
{
|
||||
UnwindAllIndents();
|
||||
}
|
||||
}
|
||||
leaf.AppendLine(ref Line, Column, LineIndex, CurrentLineStartPosition, TrackTrivia);
|
||||
}
|
||||
|
||||
@@ -277,7 +277,7 @@ namespace Markdig.Parsers
|
||||
Type = type,
|
||||
// By default, setup to the end of line
|
||||
Span = new SourceSpan(startPosition, startPosition + state.Line.End),
|
||||
BeforeWhitespace = state.PopBeforeWhitespace(startPosition - 1),
|
||||
//BeforeWhitespace = state.PopBeforeWhitespace(startPosition - 1),
|
||||
LinesBefore = state.UseLinesBefore(),
|
||||
Newline = state.Line.Newline,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user