diff --git a/FSharp.Formatting.sln b/FSharp.Formatting.sln index 51f598f37..9f3ce0808 100644 --- a/FSharp.Formatting.sln +++ b/FSharp.Formatting.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.40629.0 +# Visual Studio 14 +VisualStudioVersion = 14.0.23107.0 MinimumVisualStudioVersion = 12.0.31101.0 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "project", "project", "{194BD478-0DB5-44F3-A6C2-1FC75D3F3294}" ProjectSection(SolutionItems) = preProject diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 76e820e49..635355700 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,3 +1,10 @@ +## 2.12.2 (30 December, 2015) + - Be compatible with the common-mark spec for 'Fenced code blocks' and 'Indented code blocks'. + See https://github.com/tpetricek/FSharp.Formatting/pull/343. + Please follow-up by adding support for more sections of the spec! + Just add the section to https://github.com/tpetricek/FSharp.Formatting/blob/master/tests/FSharp.Markdown.Tests/CommonMarkSpecTest.fs#L20 + and fix the newly enabled tests. + ## 2.12.1 (24 December, 2015) - update dependencies - Upgrade the CommandTool to F# 4 and bundle FSharp.Core with sigdata and optdata. diff --git a/build.fsx b/build.fsx index 88a6401f9..68cbb40b6 100644 --- a/build.fsx +++ b/build.fsx @@ -280,22 +280,38 @@ let commandToolStartInfo workingDirectory environmentVars args = setVar "FSI" fsiPath) /// Run the given buildscript with FAKE.exe -let executeCommandToolWithOutput workingDirectory envArgs args = +let executeWithOutput configStartInfo = let exitCode = ExecProcessWithLambdas - (commandToolStartInfo workingDirectory envArgs args) + configStartInfo TimeSpan.MaxValue false ignore ignore System.Threading.Thread.Sleep 1000 exitCode -// Documentation -let buildDocumentationCommandTool args = - trace (sprintf "Building documentation (CommandTool), this could take some time, please wait...") - let exit = executeCommandToolWithOutput "." [] args +let executeWithRedirect errorF messageF configStartInfo = + let exitCode = + ExecProcessWithLambdas + configStartInfo + TimeSpan.MaxValue true errorF messageF + System.Threading.Thread.Sleep 1000 + exitCode + +let executeHelper executer traceMsg failMessage configStartInfo = + trace traceMsg + let exit = executer configStartInfo if exit <> 0 then - failwith "generating documentation failed" + failwith failMessage () +let execute = executeHelper executeWithOutput + +// Documentation +let buildDocumentationCommandTool args = + execute + "Building documentation (CommandTool), this could take some time, please wait..." + "generating documentation failed" + (commandToolStartInfo "." [] args) + let createArg argName arguments = (arguments : string seq) |> fun files -> String.Join("\" \"", files) @@ -334,22 +350,13 @@ let commandToolLiterateArgument inDir outDir layoutRoots parameters = sprintf "literate --processDirectory %s %s %s %s" inDirArg outDirArg layoutRootsArgs replacementsArgs -/// Run the given buildscript with FAKE.exe -let executeFAKEWithOutput workingDirectory script fsiargs envArgs = - let exitCode = - ExecProcessWithLambdas - (fakeStartInfo script workingDirectory "" fsiargs envArgs) - TimeSpan.MaxValue false ignore ignore - System.Threading.Thread.Sleep 1000 - exitCode - // Documentation let buildDocumentationTarget fsiargs target = - trace (sprintf "Building documentation (%s), this could take some time, please wait..." target) - let exit = executeFAKEWithOutput "docs/tools" "generate.fsx" fsiargs ["target", target] - if exit <> 0 then - failwith "generating reference documentation failed" - () + execute + (sprintf "Building documentation (%s), this could take some time, please wait..." target) + "generating reference documentation failed" + (fakeStartInfo "generate.fsx" "docs/tools" "" fsiargs ["target", target]) + let bootStrapDocumentationFiles () = // This is needed to bootstrap ourself (make sure we have the same environment while building as our users) ... @@ -446,6 +453,54 @@ Target "Release" DoNothing Target "All" DoNothing +#r "System.IO.Compression" +#r "System.IO.Compression.FileSystem" +Target "DownloadPython" (fun _ -> + if not isUnix then + let w = new System.Net.WebClient() + let zipFile = "temp"@@"cpython.zip" + if File.Exists zipFile then File.Delete zipFile + w.DownloadFile("https://www.python.org/ftp/python/3.5.1/python-3.5.1-embed-amd64.zip", zipFile) + let cpython = "temp"@@"CPython" + CleanDir cpython + System.IO.Compression.ZipFile.ExtractToDirectory(zipFile, cpython) + let cpythonStdLib = cpython@@"stdlib" + CleanDir cpythonStdLib + System.IO.Compression.ZipFile.ExtractToDirectory(cpython@@"python35.zip", cpythonStdLib) +) + +Target "CreateTestJson" (fun _ -> + let targetPath = "temp/CommonMark" + CleanDir targetPath + Git.Repository.clone targetPath "https://github.com/jgm/CommonMark.git" "." + + let pythonExe, stdLib = + if not isUnix then + System.IO.Path.GetFullPath ("temp"@@"CPython"@@"python.exe"), + System.IO.Path.GetFullPath ("temp"@@"CPython"@@"stdlib") + else "python", "" + + let resultFile = "temp"@@"commonmark-tests.json" + if File.Exists resultFile then File.Delete resultFile + ( use fileStream = new StreamWriter(File.Open(resultFile, System.IO.FileMode.Create)) + executeHelper + (executeWithRedirect traceError fileStream.WriteLine) + "Creating test json file, this could take some time, please wait..." + "generating documentation failed" + (fun info -> + info.FileName <- pythonExe + info.Arguments <- "test/spec_tests.py --dump-tests" + info.WorkingDirectory <- targetPath + let setVar k v = + info.EnvironmentVariables.[k] <- v + if not isUnix then + setVar "PYTHONPATH" stdLib + setVar "MSBuild" msBuildExe + setVar "GIT" Git.CommandHelper.gitPath + setVar "FSI" fsiPath)) + File.Copy(resultFile, "tests"@@"commonmark_spec.json") +) + "Clean" ==> "AssemblyInfo" ==> "Build" ==> "BuildTests" "Build" ==> "MergeVSPowerTools" ==> "All" "BuildTests" ==> "RunTests" ==> "All" @@ -461,4 +516,6 @@ Target "All" DoNothing ==> "CreateTag" ==> "Release" +"DownloadPython" ==> "CreateTestJson" + RunTargetOrDefault "All" diff --git a/docs/content/development.md b/docs/content/development.md new file mode 100644 index 000000000..d18542fd1 --- /dev/null +++ b/docs/content/development.md @@ -0,0 +1,23 @@ +F# Formatting: Development Topics +================================== + +Improve Common-Mark Test Coverage +---------------- +See https://github.com/tpetricek/FSharp.Formatting/pull/343 + +Update Common-Mark Test Suite +---------------- + + ./build.sh CreateTestJson + git add -A + git commit -m "Update Common-Mark test suite" + +More information +---------------- + +The project is hosted on [GitHub](https://github.com/tpetricek/FSharp.Formatting) where you can +[report issues](https://github.com/tpetricek/FSharp.Formatting/issues), fork the project and submit pull requests. +Thanks to [Gustavo Guerra](https://github.com/ovatsus) for a great build script and +[Steffen Forkmann](https://github.com/forki) for the great build tool [FAKE](https://github.com/fsharp/FAKE). +The library is available under Apache 2.0. For more information see the +[License file](https://github.com/tpetricek/FSharp.Formatting/blob/master/LICENSE.md) in the GitHub repository. diff --git a/paket.dependencies b/paket.dependencies index 14d0f723c..635fd673c 100644 --- a/paket.dependencies +++ b/paket.dependencies @@ -1,6 +1,7 @@ source http://nuget.org/api/v2 redirects: on +nuget FSharp.Data nuget FAKE nuget CommandLineParser nuget FSharp.Core diff --git a/paket.lock b/paket.lock index 1bd93ec80..2eb9bac3e 100644 --- a/paket.lock +++ b/paket.lock @@ -6,6 +6,8 @@ NUGET FAKE (4.11.3) FSharp.Compiler.Service (1.4.2) FSharp.Core (4.0.0.1) + FSharp.Data (2.2.5) + Zlib.Portable (>= 1.10.0) - framework: portable-net40+sl50+wp80+win80 FSharpVSPowerTools.Core (2.2.0) FSharp.Compiler.Service (>= 1.4.2.0) ILRepack (2.0.9) @@ -16,6 +18,7 @@ NUGET RazorEngine (3.7.6) Microsoft.AspNet.Razor (>= 3.0.0) - framework: >= net45 Microsoft.AspNet.Razor (2.0.30506) - framework: net40 + Zlib.Portable (1.11.0) - framework: portable-net40+sl50+wp80+win80 GITHUB remote: matthid/Yaaf.FSharp.Scripting specs: diff --git a/src/Common/StringParsing.fs b/src/Common/StringParsing.fs index baedfc451..0f376562a 100644 --- a/src/Common/StringParsing.fs +++ b/src/Common/StringParsing.fs @@ -34,8 +34,9 @@ module String = /// Returns a string trimmed from the start together with /// the number of skipped whitespace characters let (|TrimStartAndCount|) (text:string) = - let trimmed = text.TrimStart() - text.Length - trimmed.Length, trimmed + let trimmed = text.TrimStart([|' '; '\t'|]) + let len = text.Length - trimmed.Length + len, text.Substring(0, len).Replace("\t", " ").Length, trimmed /// Matches when a string starts with any of the specified sub-strings let (|StartsWithAny|_|) (starts:seq) (text:string) = @@ -48,6 +49,22 @@ module String = let (|StartsWithTrim|_|) (start:string) (text:string) = if text.StartsWith(start) then Some(text.Substring(start.Length).Trim()) else None + /// Matches when a string starts with the specified sub-string (ignoring whitespace at the start) + /// The matched string is trimmed from all whitespace. + let (|StartsWithNTimesTrimIgnoreStartWhitespace|_|) (start:string) (text:string) = + if text.Contains(start) then + let beforeStart = text.Substring(0, text.IndexOf(start)) + if String.IsNullOrWhiteSpace (beforeStart) then + let startAndRest = text.Substring(beforeStart.Length) + let startNum = + Seq.windowed start.Length startAndRest + |> Seq.map (fun chars -> System.String(chars)) + |> Seq.takeWhile ((=) start) + |> Seq.length + Some(startNum, beforeStart.Length, text.Substring(beforeStart.Length + (start.Length * startNum)).Trim()) + else None + else None + /// Matches when a string starts with the given value and ends /// with a given value (and returns the rest of it) let (|StartsAndEndsWith|_|) (starts, ends) (s:string) = @@ -151,6 +168,13 @@ module List = /// using the specified delimiter. Returns a wrapped list and the rest. let inline (|Delimited|_|) str = (|DelimitedWith|_|) str str + let inline (|DelimitedNTimes|_|) str input = + let strs, items = List.partitionWhile (fun i -> i = str) input + match strs with + | h :: _ -> + (|Delimited|_|) (List.init strs.Length (fun _ -> str)) input + | _ -> None + /// Matches a list if it starts with a bracketed list. Nested brackets /// are skipped (by counting opening and closing brackets) and can be /// escaped using the '\' symbol. @@ -185,9 +209,40 @@ module Lines = | matching, rest when matching <> [] -> Some(matching, rest) | _ -> None + /// Matches when there are some lines at the beginning that are + /// either empty (or whitespace) or start with at least 4 spaces (a tab counts as 4 spaces here). + /// Returns all such lines from the beginning until a different line and + /// the number of spaces the first line started with. + let (|TakeCodeBlock|_|) (input:string list) = + let spaceNum = 4 + //match input with + //| h :: _ -> + // let head = (input |> List.head).Replace("\t", " ") |> Seq.toList + // let spaces, _ = List.partitionWhile (fun s -> s = ' ') head + // spaces.Length + //| _ -> 0 + let startsWithSpaces (s:string) = + let normalized = s.Replace("\t", " ") + normalized.Length >= spaceNum && + normalized.Substring(0, spaceNum) = System.String(' ', spaceNum) + match List.partitionWhile (fun s -> + String.IsNullOrWhiteSpace s || startsWithSpaces s) input with + | matching, rest when matching <> [] && spaceNum >= 4 -> + Some(spaceNum, matching, rest) + | _ -> None + /// Removes whitespace lines from the beginning of the list let (|TrimBlankStart|) = List.skipWhile (String.IsNullOrWhiteSpace) + /// Trims all lines of the current paragraph + let (|TrimParagraphLines|) lines = + lines + // first remove all whitespace on the beginning of the line + |> List.map (fun (s:string) -> s.TrimStart()) + // Now remove all additional spaces at the end, but keep two spaces if existent + |> List.map (fun s -> + let endsWithTwoSpaces = s.EndsWith(" ") + s.TrimEnd([|' '|]) + if endsWithTwoSpaces then " " else "") /// Parameterized pattern that assigns the specified value to the /// first component of a tuple. Usage: diff --git a/src/FSharp.Literate/Contexts.fs b/src/FSharp.Literate/Contexts.fs index 8bf54b60d..733abc674 100644 --- a/src/FSharp.Literate/Contexts.fs +++ b/src/FSharp.Literate/Contexts.fs @@ -1,11 +1,12 @@ namespace FSharp.Literate + open FSharp.CodeFormat /// Specifies a context that is passed to functions /// that need to use the F# compiler type CompilerContext = { // An instance of the F# code formatting agent - FormatAgent : CodeFormatAgent + FormatAgent : CodeFormatAgent // F# interactive evaluator Evaluator : IFsiEvaluator option // Command line options for the F# compiler @@ -13,22 +14,20 @@ type CompilerContext = // Defined symbols for the F# compiler DefinedSymbols : string option } - /// Defines the two possible output types from literate script: HTML and LaTeX. [] type OutputKind = Html | Latex - /// Specifies a context that is passed to functions that generate the output type ProcessingContext = { // Path to the template file TemplateFile : string option // Short prefix code added to all HTML 'id' elements - Prefix : string + Prefix : string // Additional replacements to be made in the template file - Replacements : list + Replacements : list // Generate line numbers for F# snippets? - GenerateLineNumbers : bool + GenerateLineNumbers : bool // Include the source file in the generated output as '{source}' IncludeSource : bool // Auto-generate anchors for headers diff --git a/src/FSharp.Markdown/HtmlFormatting.fs b/src/FSharp.Markdown/HtmlFormatting.fs index cb6574f74..663f20e4a 100644 --- a/src/FSharp.Markdown/HtmlFormatting.fs +++ b/src/FSharp.Markdown/HtmlFormatting.fs @@ -60,7 +60,7 @@ type FormattingContext = ParagraphIndent : unit -> unit } let bigBreak (ctx:FormattingContext) () = - ctx.Writer.Write(ctx.Newline + ctx.Newline) + ctx.Writer.Write(ctx.Newline) let smallBreak (ctx:FormattingContext) () = ctx.Writer.Write(ctx.Newline) let noBreak (ctx:FormattingContext) () = () @@ -77,7 +77,7 @@ let rec formatSpan (ctx:FormattingContext) = function | AnchorLink(id) -> ctx.Writer.Write(" ") | EmbedSpans(cmd) -> formatSpans ctx (cmd.Render()) | Literal(str) -> ctx.Writer.Write(str) - | HardLineBreak -> ctx.Writer.Write("
") + | HardLineBreak -> ctx.Writer.WriteLine("
") | IndirectLink(body, _, LookupKey ctx.Links (link, title)) | DirectLink(body, (link, title)) -> ctx.Writer.Write(" String.concat "-" |> fun name -> if String.IsNullOrWhiteSpace name then "header" else name |> ctx.UniqueNameGenerator.GetName - +let withInner ctx f = + use sb = new StringWriter() + let newCtx = { ctx with Writer = sb } + f newCtx + sb.ToString() /// Write a MarkdownParagraph value to a TextWriter let rec formatParagraph (ctx:FormattingContext) paragraph = match paragraph with @@ -192,7 +196,7 @@ let rec formatParagraph (ctx:FormattingContext) paragraph = | CodeBlock(code, codeLanguage, _) -> if ctx.WrapCodeSnippets then ctx.Writer.Write("
") let langCode = sprintf "language-%s" codeLanguage - ctx.Writer.Write(sprintf "
" langCode langCode)
+      ctx.Writer.Write(sprintf "
" langCode)
       ctx.Writer.Write(htmlEncode code)
       ctx.Writer.Write("
") if ctx.WrapCodeSnippets then ctx.Writer.Write("
") @@ -230,15 +234,25 @@ let rec formatParagraph (ctx:FormattingContext) paragraph = ctx.Writer.Write("<" + tag + ">" + ctx.Newline) for body in items do ctx.Writer.Write("
  • ") - body |> List.iterInterleaved - (formatParagraph { ctx with LineBreak = noBreak ctx }) - (fun () -> ctx.Writer.Write(ctx.Newline)) + match body with + // Simple Paragraph + | [ Paragraph [MarkdownSpan.Literal s] ] when not (s.Contains(ctx.Newline)) -> + ctx.Writer.Write s + | _ -> + let inner = + withInner ctx (fun ctx -> + body |> List.iterInterleaved + (formatParagraph { ctx with LineBreak = noBreak ctx }) + (fun () -> ctx.Writer.Write(ctx.Newline))) + let wrappedInner = + if inner.Contains(ctx.Newline) then ctx.Newline + inner + ctx.Newline else inner + ctx.Writer.Write(wrappedInner) ctx.Writer.Write("
  • " + ctx.Newline) ctx.Writer.Write("") | QuotedBlock(body) -> ctx.ParagraphIndent() ctx.Writer.Write("
    " + ctx.Newline) - formatParagraphs { ctx with ParagraphIndent = fun () -> ctx.ParagraphIndent(); ctx.Writer.Write(" ") } body + formatParagraphs { ctx with ParagraphIndent = fun () -> ctx.ParagraphIndent() (*; ctx.Writer.Write(" ")*) } body ctx.ParagraphIndent() ctx.Writer.Write("
    ") | Span spans -> diff --git a/src/FSharp.Markdown/Main.fs b/src/FSharp.Markdown/Main.fs index 20208cd76..2e174bd7a 100644 --- a/src/FSharp.Markdown/Main.fs +++ b/src/FSharp.Markdown/Main.fs @@ -49,12 +49,18 @@ type Markdown = let lines = [ let line = ref "" while (line := reader.ReadLine(); line.Value <> null) do - yield line.Value ] - |> Utils.replaceTabs 4 + yield line.Value + if text.EndsWith(newline) then + yield "" ] + //|> Utils.replaceTabs 4 let links = Dictionary<_, _>() - let (Lines.TrimBlank lines) = lines + //let (Lines.TrimBlank lines) = lines let ctx : ParsingContext = { Newline = newline; Links = links } - let paragraphs = lines |> parseParagraphs ctx |> List.ofSeq + let paragraphs = + lines + |> FSharp.Collections.List.skipWhile String.IsNullOrWhiteSpace + |> parseParagraphs ctx + |> List.ofSeq MarkdownDocument(paragraphs, links) /// Parse the specified text into a MarkdownDocument. diff --git a/src/FSharp.Markdown/MarkdownParser.fs b/src/FSharp.Markdown/MarkdownParser.fs index 352239ce5..439da115f 100644 --- a/src/FSharp.Markdown/MarkdownParser.fs +++ b/src/FSharp.Markdown/MarkdownParser.fs @@ -19,7 +19,7 @@ open FSharp.Collections /// Splits a link formatted as `http://link "title"` into a link part /// and an optional title part (may be wrapped using quote or double-quotes) let getLinkAndTitle (String.TrimBoth input) = - let url, title = + let url, title = if input.Length = 0 then "", None else let c = input.[input.Length - 1] if c = '\'' || c = '"' then @@ -28,11 +28,11 @@ let getLinkAndTitle (String.TrimBoth input) = else input, None url.TrimStart('<').TrimEnd('>'), title -/// Succeeds when the specified character list starts with an escaped +/// Succeeds when the specified character list starts with an escaped /// character - in that case, returns the character and the tail of the list -let inline (|EscapedChar|_|) input = +let inline (|EscapedChar|_|) input = match input with - | '\\'::( ( '*' | '\\' | '`' | '_' | '{' | '}' | '[' | ']' + | '\\'::( ( '*' | '\\' | '`' | '_' | '{' | '}' | '[' | ']' | '(' | ')' | '>' | '#' | '.' | '!' | '+' | '-' | '$') as c) ::rest -> Some(c, rest) | _ -> None @@ -46,7 +46,7 @@ let inline (|EscapedLatexInlineMathChar|_|) input = /// using the specified delimiters. Returns a wrapped list and the rest. /// /// This is similar to `List.Delimited`, but it skips over escaped characters. -let (|DelimitedMarkdown|_|) bracket input = +let (|DelimitedMarkdown|_|) bracket input = let startl, endl = bracket, bracket // Like List.partitionUntilEquals, but skip over escaped characters let rec loop acc = function @@ -56,7 +56,7 @@ let (|DelimitedMarkdown|_|) bracket input = | [] -> None // If it starts with 'startl', let's search for 'endl' if List.startsWith bracket input then - match loop [] (List.skip bracket.Length input) with + match loop [] (List.skip bracket.Length input) with | Some(pre, post) -> Some(pre, List.skip bracket.Length post) | None -> None else None @@ -73,7 +73,7 @@ let (|DelimitedLatexDisplayMath|_|) bracket input = | [] -> None // If it starts with 'startl', let's search for 'endl' if List.startsWith bracket input then - match loop [] (List.skip bracket.Length input) with + match loop [] (List.skip bracket.Length input) with | Some(pre, post) -> Some(pre, List.skip bracket.Length post) | None -> None else None @@ -89,7 +89,7 @@ let (|DelimitedLatexInlineMath|_|) bracket input = | [] -> None // If it starts with 'startl', let's search for 'endl' if List.startsWith bracket input then - match loop [] (List.skip bracket.Length input) with + match loop [] (List.skip bracket.Length input) with | Some(pre, post) -> Some(pre, List.skip bracket.Length post) | None -> None else None @@ -97,14 +97,14 @@ let (|DelimitedLatexInlineMath|_|) bracket input = /// Recognizes an indirect link written using `[body][key]` or just `[key]` /// The key can be preceeded by a space or other single whitespace thing. let (|IndirectLink|_|) = function - | List.BracketDelimited '[' ']' (body, '\r'::'\n'::(List.BracketDelimited '[' ']' (List.AsString link, rest))) -> + | List.BracketDelimited '[' ']' (body, '\r'::'\n'::(List.BracketDelimited '[' ']' (List.AsString link, rest))) -> Some(body, link, "\r\n[" + link + "]", rest) - | List.BracketDelimited '[' ']' (body, ((' ' | '\n') as c)::(List.BracketDelimited '[' ']' (List.AsString link, rest))) -> + | List.BracketDelimited '[' ']' (body, ((' ' | '\n') as c)::(List.BracketDelimited '[' ']' (List.AsString link, rest))) -> Some(body, link, c.ToString() + "[" + link + "]", rest) | List.BracketDelimited '[' ']' (body, List.BracketDelimited '[' ']' (List.AsString link, rest)) -> - Some(body, link, "[" + link + "]", rest) + Some(body, link, "[" + link + "]", rest) | List.BracketDelimited '[' ']' (body, rest) -> - Some(body, "", "", rest) + Some(body, "", "", rest) | _ -> None /// Recognize a direct link written using `[body](http://url "with title")` @@ -133,14 +133,14 @@ let (|AutoLink|_|) input = let (|Emphasised|_|) = function | (('_' | '*') :: tail) as input -> match input with - | DelimitedMarkdown ['_'; '_'; '_'] (body, rest) - | DelimitedMarkdown ['*'; '*'; '*'] (body, rest) -> + | DelimitedMarkdown ['_'; '_'; '_'] (body, rest) + | DelimitedMarkdown ['*'; '*'; '*'] (body, rest) -> Some(body, Emphasis >> List.singleton >> Strong, rest) - | DelimitedMarkdown ['_'; '_'] (body, rest) - | DelimitedMarkdown ['*'; '*'] (body, rest) -> + | DelimitedMarkdown ['_'; '_'] (body, rest) + | DelimitedMarkdown ['*'; '*'] (body, rest) -> Some(body, Strong, rest) - | DelimitedMarkdown ['_'] (body, rest) - | DelimitedMarkdown ['*'] (body, rest) -> + | DelimitedMarkdown ['_'] (body, rest) + | DelimitedMarkdown ['*'] (body, rest) -> Some(body, Emphasis, rest) | _ -> None | _ -> None @@ -150,21 +150,21 @@ let rec parseChars acc input = seq { // Zero or one literals, depending whether there is some accumulated input let accLiterals = Lazy.Create(fun () -> - if List.isEmpty acc then [] + if List.isEmpty acc then [] else [Literal(String(List.rev acc |> Array.ofList))] ) - match input with + match input with // Recognizes explicit line-break at the end of line - | ' '::' '::('\n' | '\r')::rest - | ' '::' '::'\r'::'\n'::rest -> + | ' '::' '::'\r'::'\n'::rest + | ' '::' '::('\n' | '\r')::rest -> yield! accLiterals.Value yield HardLineBreak yield! parseChars [] rest // Encode & as an HTML entity - | '&'::'a'::'m'::'p'::';'::rest + | '&'::'a'::'m'::'p'::';'::rest | '&'::rest -> - yield! parseChars (';'::'p'::'m'::'a'::'&'::acc) rest + yield! parseChars (';'::'p'::'m'::'a'::'&'::acc) rest // Ignore escaped characters that might mean something else | EscapedChar(c, rest) -> @@ -173,8 +173,7 @@ let rec parseChars acc input = seq { // Inline code delimited either using double `` or single ` // (if there are spaces around, then body can contain more backticks) | List.DelimitedWith ['`'; ' '] [' '; '`'] (body, rest) - | List.Delimited ['`'; '`'] (body, rest) - | List.Delimited ['`'] (body, rest) -> + | List.DelimitedNTimes '`' (body, rest) -> yield! accLiterals.Value yield InlineCode(String(Array.ofList body).Trim()) yield! parseChars [] rest @@ -192,7 +191,7 @@ let rec parseChars acc input = seq { yield! parseChars [] rest // Inline link wrapped as - | List.DelimitedWith ['<'] ['>'] (List.AsString link, rest) + | List.DelimitedWith ['<'] ['>'] (List.AsString link, rest) when Seq.forall (Char.IsWhiteSpace >> not) link && (link.Contains("@") || link.Contains("://")) -> yield! accLiterals.Value yield DirectLink([Literal link], (link, None)) @@ -235,19 +234,24 @@ let rec parseChars acc input = seq { yield f(body) yield! parseChars [] rest // Encode '<' char if it is not link or inline HTML - | '<'::rest -> - yield! parseChars (';'::'t'::'l'::'&'::acc) rest - | '>'::rest -> - yield! parseChars (';'::'t'::'g'::'&'::acc) rest - | x::xs -> - yield! parseChars (x::acc) xs + | '<'::rest -> + yield! parseChars (';'::'t'::'l'::'&'::acc) rest + | '>'::rest -> + yield! parseChars (';'::'t'::'g'::'&'::acc) rest + | x::xs -> + yield! parseChars (x::acc) xs | [] -> yield! accLiterals.Value } -/// Parse body of a paragraph into a list of Markdown inline spans -let parseSpans (String.TrimBoth s) = +/// Parse body of a paragraph into a list of Markdown inline spans +let parseSpans (String.TrimBoth s) = parseChars [] (s.ToCharArray() |> List.ofArray) |> List.ofSeq +let rec trimSpaces numSpaces (s:string) = + if numSpaces <= 0 then s + elif s.StartsWith(" ") then trimSpaces (numSpaces - 1) (s.Substring(1)) + elif s.StartsWith("\t") then trimSpaces (numSpaces - 4) (s.Substring(1)) + else s // -------------------------------------------------------------------------------------- // Parsing of Markdown - second part handles paragraph-level formatting (headings, etc.) @@ -260,20 +264,20 @@ let (|Heading|_|) = function | (String.TrimBoth header) :: (String.TrimEnd (String.EqualsRepeated "-")) :: rest -> Some(2, header, rest) | String.StartsWithRepeated "#" (n, header) :: rest -> - let header = + let header = // Drop "##" at the end, but only when it is preceded by some whitespace // (For example "## Hello F#" should be "Hello F#") if header.EndsWith "#" then let noHash = header.TrimEnd [| '#' |] - if noHash.Length > 0 && Char.IsWhiteSpace(noHash.Chars(noHash.Length - 1)) + if noHash.Length > 0 && Char.IsWhiteSpace(noHash.Chars(noHash.Length - 1)) then noHash else header - else header + else header Some(n, header.Trim(), rest) | rest -> None /// Recognizes a horizontal rule written using *, _ or - -let (|HorizontalRule|_|) (line:string) = +let (|HorizontalRule|_|) (line:string) = let rec loop ((h, a, u) as arg) i = if (h >= 3 || a >= 3 || u >= 3) && i = line.Length then Some(line.[0]) elif i = line.Length then None @@ -286,115 +290,156 @@ let (|HorizontalRule|_|) (line:string) = /// Recognizes a code block - lines starting with four spaces (including blank) let (|NestedCodeBlock|_|) = function - | Lines.TakeStartingWithOrBlank " " (Lines.TrimBlank lines, rest) when lines <> [] -> + | Lines.TakeCodeBlock (numspaces, Lines.TrimBlank lines, rest) when lines <> [] -> let code = - [ for l in lines -> - if String.IsNullOrWhiteSpace l then "" - elif l.Length > 4 then l.Substring(4, l.Length - 4) - else l ] - Some((if rest.IsEmpty then code else code @ [""]), rest, "", "") + [ for l in lines -> + if String.IsNullOrEmpty l then "" + else trimSpaces 4 l ] + Some(code @ [""], rest, "", "") | _ -> None -/// Recognizes a fenced code block - starting and ending with ``` +/// Recognizes a fenced code block - starting and ending with at least ``` or ~~~ let (|FencedCodeBlock|_|) = function - | String.StartsWithTrim "```" header :: lines -> - let code, rest = lines |> List.partitionUntil (fun line -> line.Contains "```") + | String.StartsWithNTimesTrimIgnoreStartWhitespace "~" (Let "~" (start,num), indent, header) :: lines + // when num > 2 + | String.StartsWithNTimesTrimIgnoreStartWhitespace "`" (Let "`" (start,num), indent, header) :: lines + when num > 2 -> + let mutable endStr = String.replicate num start + if header.Contains (start) then None // info string cannot contain backspaces + else + let code, rest = lines |> List.partitionUntil (fun line -> + match [line] with + // end cannot contain info string afterwards (see http://spec.commonmark.org/0.23/#example-104) + // end must be indended with less then 4 spaces: http://spec.commonmark.org/0.23/#example-95 + | String.StartsWithNTimesTrimIgnoreStartWhitespace start (n, i, h) :: _ when n >= num && i < 4 && String.IsNullOrWhiteSpace h -> + endStr <- String.replicate n start + true + | _ -> false) + let handleIndent (l:string) = + if l.Length <= indent && String.IsNullOrWhiteSpace l then "" + elif l.Length > indent && String.IsNullOrWhiteSpace (l.Substring(0, indent)) then l.Substring(indent, l.Length - indent) + else l.TrimStart() + let code = + [ for l in code -> handleIndent l ] + // langString is the part after ``` and ignoredString is the rest until the line ends. - let langString, ignoredString = - if String.IsNullOrWhiteSpace header then "", "" else + let langString, ignoredString = + if String.IsNullOrWhiteSpace header then "", "" else let splits = header.Split((null : char array), StringSplitOptions.RemoveEmptyEntries) match splits |> Seq.tryFind (fun _ -> true) with | None -> "", "" | Some langString -> let ignoredString = header.Substring(header.IndexOf(langString) + langString.Length) langString, if String.IsNullOrWhiteSpace ignoredString then "" else ignoredString - // Handle the ending line + // Handle the ending line let code, rest = match rest with - | hd :: tl -> - let idx = hd.IndexOf("```") - if idx > -1 && idx + 3 <= hd.Length then + | hd :: tl -> + let idx = hd.IndexOf(endStr) + if idx > -1 && idx + endStr.Length <= hd.Length then let pre = hd.Substring(0, idx) - let after = hd.Substring(idx + 3) - code @ [pre], (if String.IsNullOrWhiteSpace after then tl else after :: tl) + let after = hd.Substring(idx + endStr.Length) + code @ [""], (if String.IsNullOrWhiteSpace after then tl else after :: tl) else - code, tl - | _ -> + code @ [""], tl + | _ -> code, rest Some (code, rest, langString, ignoredString) | _ -> None /// Matches when the input starts with a number. Returns the /// rest of the input, following the last number. -let (|SkipSomeNumbers|_|) (input:string) = +let (|SkipSomeNumbers|_|) (input:string) = match List.ofSeq input with - | x::xs when Char.IsDigit x -> + | x::xs when Char.IsDigit x -> let _, rest = List.partitionUntil (Char.IsDigit >> not) xs Some(input.Length - rest.Length, rest) | _ -> None /// Recognizes a staring of a list (either 1. or +, *, -). /// Returns the rest of the line, together with the indent. -let (|ListStart|_|) = function - | String.TrimStartAndCount (startIndent, (String.StartsWithAny ["+ "; "* "; "- "] as item)) -> - let trimItem = item.Substring(1).TrimStart(' ') - let endIndent = startIndent + (item.Length - trimItem.Length) - Some(Unordered, startIndent, endIndent, item.Substring(1)) - | String.TrimStartAndCount (startIndent, (SkipSomeNumbers (skipNumCount, '.' :: ' ' :: List.AsString item))) -> - let trimItem = item.TrimStart(' ') - let endIndent = startIndent + 2 + skipNumCount + (item.Length - trimItem.Length) - Some(Ordered, startIndent, endIndent, trimItem) +let (|ListStart|_|) = function + | String.TrimStartAndCount + (startIndent, spaces, + // NOTE: a tab character after +, * or - isn't supported by the reference implementation + // (it will be parsed as paragraph for 0.22) + (String.StartsWithAny ["+ "; "* "; "- " (*; "+\t"; "*\t"; "-\t"*)] as item)) -> + let li = item.Substring(2) + let (String.TrimStartAndCount (startIndent2, spaces2, _)) = li + let endIndent = + startIndent + 2 + + // Handle case of code block + if startIndent2 >= 5 then 1 else startIndent2 + Some(Unordered, startIndent, endIndent, li) + | String.TrimStartAndCount // Remove leading spaces + (startIndent, spaces, + (SkipSomeNumbers // read a number + (skipNumCount, '.' :: ' ' :: List.AsString item))) -> + let (String.TrimStartAndCount (startIndent2, spaces2, _)) = item + let endIndent = + startIndent + 2 + skipNumCount + + // Handle case of code block + if startIndent2 >= 5 then 1 else startIndent2 + Some(Ordered, startIndent, endIndent, item) | _ -> None /// Splits input into lines until whitespace or starting of a list and the rest. -let (|LinesUntilListOrWhite|) = +let (|LinesUntilListOrWhite|) = List.partitionUntil (function | ListStart _ | String.WhiteSpace -> true | _ -> false) /// Splits input into lines until not-indented line or starting of a list and the rest. let (|LinesUntilListOrUnindented|) = - List.partitionUntilLookahead (function - | (ListStart _ | String.Unindented)::_ + List.partitionUntilLookahead (function + | (ListStart _ | String.Unindented)::_ | String.WhiteSpace::String.WhiteSpace::_ -> true | _ -> false) /// Recognizes a list item until the next list item (possibly nested) or end of a list. -/// The parameter specifies whether the previous line was simple (single-line not +/// The parameter specifies whether the previous line was simple (single-line not /// separated by a white line - simple items are not wrapped in

    ) let (|ListItem|_|) prevSimple = function | ListStart(kind, startIndent, endIndent, item):: // Take remaining lines that belong to the same item // (everything until an empty line or start of another list item) LinesUntilListOrWhite - (continued, - // Take more things that belong to the item - + (continued, + // Take more things that belong to the item - // the value 'more' will contain indented paragraphs (LinesUntilListOrUnindented (more, rest) as next)) -> - let simple = - match next, rest with - | String.WhiteSpace::_, (ListStart _)::_ -> false - | (ListStart _)::_, _ -> true - | [], _ -> true - | String.WhiteSpace::String.WhiteSpace::_, _ -> true - | _, String.Unindented::_ -> prevSimple - | _, _ -> false - - let lines = + let simple = + match item with + | String.TrimStartAndCount (_, spaces, _) when spaces >= 4-> + // Code Block + false + | _ -> + match next, rest with + | String.WhiteSpace::_, (ListStart _)::_ -> false + | (ListStart _)::_, _ -> true + | [], _ -> true + | [ String.WhiteSpace ], _ -> true + | String.WhiteSpace::String.WhiteSpace::_, _ -> true + | _, String.Unindented::_ -> prevSimple + | _, _ -> false + + let lines = [ yield item for line in continued do yield line.Trim() for line in more do - let trimmed = line.TrimStart() - if trimmed.Length >= line.Length - endIndent then yield trimmed - else yield line.Substring(endIndent) ] + let trimmed = trimSpaces endIndent line + yield trimmed ] + //let trimmed = line.TrimStart() + //if trimmed.Length >= line.Length - endIndent then yield trimmed + //else yield line.Substring(endIndent) ] Some(startIndent, (simple, kind, lines), rest) | _ -> None -/// Recognizes a list - returns list items with information about +/// Recognizes a list - returns list items with information about /// their indents - these need to be turned into a tree structure later. let rec (|ListItems|_|) prevSimple = function | ListItem prevSimple (indent, ((nextSimple, _, _) as info), rest) -> - match rest with - | (HorizontalRule _)::_ -> + match rest with + | (HorizontalRule _)::_ -> Some([indent, info], rest) | ListItems nextSimple (items, rest) -> Some((indent, info)::items, rest) @@ -425,11 +470,11 @@ let (|PipeTableRow|_|) (size:option) delimiters (line:string) = /// Recognizes separator row of pipe table. /// Returns list of alignments. -let (|PipeSeparatorRow|_|) size = function +let (|PipeSeparatorRow|_|) size = function | PipeTableRow size [|'|'; '+'|] parts -> let alignments = parts |> List.choose ( |TableCellSeparator|_| ) if parts.Length <> alignments.Length then None else (Some alignments) - | _ -> None + | _ -> None /// Recognizes pipe table let (|PipeTableBlock|_|) input = @@ -440,7 +485,7 @@ let (|PipeTableBlock|_|) input = match input with | (PipeSeparatorRow None alignments) :: rest -> let rows, others = getTableRows (Some alignments.Length) [] rest - Some((None, alignments, rows), others) + Some((None, alignments, rows), others) | (PipeTableRow None [|'|'|] headers) :: rest -> match rest with | (PipeSeparatorRow (Some headers.Length) alignments) :: rest -> @@ -457,7 +502,7 @@ let (|PipeTableBlock|_|) input = /// Passed function is used to check whether all parts within grid are valid. /// Retuns tuple (position of grid columns, text between grid columns). let (|EmacsTableLine|_|) (grid:option) (c:char) (check:string -> bool) (line:string) = - let p = if grid.IsSome then grid.Value else Array.FindAll([|0..line.Length - 1|], fun i -> line.[i] = c) + let p = if grid.IsSome then grid.Value else Array.FindAll([|0..line.Length - 1|], fun i -> line.[i] = c) let n = p.Length - 1 if n < 2 || line.Length <= p.[n] || Array.exists (fun i -> line.[i] <> c) p then None else @@ -493,23 +538,24 @@ let (|EmacsTableBlock|_|) input = /// Recognizes a start of a blockquote -let (|BlockquoteStart|_|) (line:string) = - let rec spaces i = +let (|BlockquoteStart|_|) (line:string) = + let rec spaces i = // Too many spaces or beyond the end of line if i = 4 || i = line.Length then None - elif line.[i] = '>' then + elif line.[i] = '>' then // Blockquote - does it have additional space? let start = if (i + 1) = line.Length || line.[i+1] <> ' ' then i + 1 else i + 2 Some(line.Substring(start)) elif line.[i] = ' ' then spaces (i + 1) + //elif line.[i] = '\t' then spaces (i + 4) else None spaces 0 -/// Takes lines that belong to a continuing paragraph until +/// Takes lines that belong to a continuing paragraph until /// a white line or start of other paragraph-item is found -let (|TakeParagraphLines|_|) input = +let (|TakeParagraphLines|_|) input = match List.partitionWhileLookahead (function | Heading _ -> false | FencedCodeBlock _ -> false @@ -527,16 +573,21 @@ let (|HtmlBlock|_|) = function | _ -> None /// Continues taking lines until a whitespace line or start of a blockquote -let (|LinesUntilBlockquoteOrWhite|) = - List.partitionUntil (function - | BlockquoteStart _ | String.WhiteSpace -> true | _ -> false) - -/// Recognizes blockquote - continues taking paragraphs +let (|LinesUntilBlockquoteEnds|) input = + List.partitionUntilLookahead (fun next -> + match next with + | BlockquoteStart _ :: _ + | Heading _ + | String.WhiteSpace :: _ -> true + | _ -> + false) input + +/// Recognizes blockquote - continues taking paragraphs /// starting with '>' until there is something else let rec (|Blockquote|_|) = function - | BlockquoteStart(line)::LinesUntilBlockquoteOrWhite(continued, Lines.TrimBlankStart rest) -> - let moreLines, rest = - match rest with + | BlockquoteStart(line)::LinesUntilBlockquoteEnds(continued, Lines.TrimBlankStart rest) -> + let moreLines, rest = + match rest with | Blockquote(lines, rest) -> lines, rest | _ -> [], rest Some (line::continued @ moreLines, rest) @@ -551,16 +602,16 @@ let (|LatexBlock|_|) (lines:string list) = lines |> function /// Recognize a definition of a link as in `[key]: http://url ...` let (|LinkDefinition|_|) = function - | ( String.StartsWithWrapped ("[", "]:") (wrapped, String.TrimBoth link) - | String.StartsWithWrapped (" [", "]:") (wrapped, String.TrimBoth link) - | String.StartsWithWrapped (" [", "]:") (wrapped, String.TrimBoth link) + | ( String.StartsWithWrapped ("[", "]:") (wrapped, String.TrimBoth link) + | String.StartsWithWrapped (" [", "]:") (wrapped, String.TrimBoth link) + | String.StartsWithWrapped (" [", "]:") (wrapped, String.TrimBoth link) | String.StartsWithWrapped (" [", "]:") (wrapped, String.TrimBoth link) ) :: rest -> Some((wrapped, link), rest) | _ -> None /// Defines a context for the main `parseParagraphs` function -type ParsingContext = - { Links : Dictionary> +type ParsingContext = + { Links : Dictionary> Newline : string } /// Parse a list of lines into a sequence of markdown paragraphs @@ -573,18 +624,18 @@ let rec parseParagraphs (ctx:ParsingContext) lines = seq { | NestedCodeBlock(code, Lines.TrimBlankStart lines, langString, ignoredLine) | FencedCodeBlock(code, Lines.TrimBlankStart lines, langString, ignoredLine) -> yield CodeBlock(code |> String.concat ctx.Newline, langString, ignoredLine) - yield! parseParagraphs ctx lines + yield! parseParagraphs ctx lines | Blockquote(body, Lines.TrimBlankStart rest) -> - yield QuotedBlock(parseParagraphs ctx body |> List.ofSeq) + yield QuotedBlock(parseParagraphs ctx (body @ [""]) |> List.ofSeq) yield! parseParagraphs ctx rest - | EmacsTableBlock((headers, alignments, rows), Lines.TrimBlankStart rest) + | EmacsTableBlock((headers, alignments, rows), Lines.TrimBlankStart rest) | PipeTableBlock((headers, alignments, rows), Lines.TrimBlankStart rest) -> - let headParagraphs = + let headParagraphs = if headers.IsNone then None else Some(headers.Value |> List.map (fun i -> parseParagraphs ctx i |> List.ofSeq)) yield TableBlock(headParagraphs, alignments, rows |> List.map (List.map (fun i -> parseParagraphs ctx i |> List.ofSeq))) - yield! parseParagraphs ctx rest + yield! parseParagraphs ctx rest | HorizontalRule(c) :: (Lines.TrimBlankStart lines) -> yield HorizontalRule(c) yield! parseParagraphs ctx lines @@ -598,10 +649,10 @@ let rec parseParagraphs (ctx:ParsingContext) lines = seq { let tree = Tree.ofIndentedList items // Nest all items that have another kind (i.e. UL vs. OL) - let rec nestUnmatchingItems items = + let rec nestUnmatchingItems items = match items with | Node((_, baseKind, _), _)::_ -> - items + items |> List.nestUnderLastMatching (fun (Node((_, kind, _), _)) -> kind = baseKind) |> List.map (fun (Node(info, children), nested) -> let children = nestUnmatchingItems children @@ -618,22 +669,34 @@ let rec parseParagraphs (ctx:ParsingContext) lines = seq { if nested <> [] then yield formatTree nested ] ] ListBlock(kind, items) - yield formatTree tree + + // Make sure all items of the list have are either simple or not. + let rec unifySimpleProperty (nodes:Tree list) = + let containsNonSimple = + tree |> Seq.exists (function + | Node ((false, _, _), _) -> true + | _ -> false) + if containsNonSimple then + nodes |> List.map (function + | Node ((_, kind, content), nested) -> Node((false, kind, content), unifySimpleProperty nested)) + else nodes + + yield tree |> unifySimpleProperty |> formatTree yield! parseParagraphs ctx rest // Recognize remaining types of paragraphs | Heading(n, body, Lines.TrimBlankStart lines) -> yield Heading(n, parseSpans body) - yield! parseParagraphs ctx lines - | HtmlBlock(code, Lines.TrimBlankStart lines) when + yield! parseParagraphs ctx lines + | HtmlBlock(code, Lines.TrimBlankStart lines) when ( let all = String.concat ctx.Newline code not (all.StartsWith(" let all = String.concat ctx.Newline code yield InlineBlock(all) - yield! parseParagraphs ctx lines - | TakeParagraphLines(lines, Lines.TrimBlankStart rest) -> + yield! parseParagraphs ctx lines + | TakeParagraphLines(Lines.TrimParagraphLines lines, Lines.TrimBlankStart rest) -> yield Paragraph (parseSpans (String.concat ctx.Newline lines)) - yield! parseParagraphs ctx rest + yield! parseParagraphs ctx rest - | Lines.TrimBlankStart [] -> () - | _ -> failwithf "Unexpectedly stopped!\n%A" lines } \ No newline at end of file + | Lines.TrimBlankStart [] -> () + | _ -> failwithf "Unexpectedly stopped!\n%A" lines } diff --git a/tests/Benchmarks/testfiles/mdtest-1.1/Links_reference_style.html b/tests/Benchmarks/testfiles/mdtest-1.1/Links_reference_style.html index 8e70c32f4..6d78b96f3 100644 --- a/tests/Benchmarks/testfiles/mdtest-1.1/Links_reference_style.html +++ b/tests/Benchmarks/testfiles/mdtest-1.1/Links_reference_style.html @@ -1,52 +1,28 @@

    Foo bar.

    -

    Foo bar.

    -

    Foo bar.

    -

    With embedded [brackets].

    -

    Indented once.

    -

    Indented twice.

    -

    Indented thrice.

    -

    Indented [four][] times.

    -
    [four]: /url
     
    -
    -

    this should work

    -

    So should this.

    -

    And this.

    -

    And this.

    -

    And this.

    -

    But not [that] [].

    -

    Nor [that][].

    -

    Nor [that].

    -

    [Something in brackets like this should work]

    -

    [Same with this.]

    -

    In this case, this points to something else.

    -

    Backslashing should suppress [this] and [this].

    -
    -

    Here's one where the link breaks across lines.

    - -

    Here's another where the link +

    Here's another where the link breaks across lines, but with a line-ending space.

    diff --git a/tests/Benchmarks/testfiles/mdtest-1.1/Links_shortcut_references.html b/tests/Benchmarks/testfiles/mdtest-1.1/Links_shortcut_references.html index bf81e939f..8163ade53 100644 --- a/tests/Benchmarks/testfiles/mdtest-1.1/Links_shortcut_references.html +++ b/tests/Benchmarks/testfiles/mdtest-1.1/Links_shortcut_references.html @@ -1,9 +1,6 @@

    This is the simple case.

    -

    This one has a line break.

    - -

    This one has a line +

    This one has a line break with a line-ending space.

    -

    this and the other

    diff --git a/tests/Benchmarks/testfiles/mdtest-1.1/Markdown_Documentation_Syntax.html b/tests/Benchmarks/testfiles/mdtest-1.1/Markdown_Documentation_Syntax.html index 5c01306cc..49cb35ac9 100644 --- a/tests/Benchmarks/testfiles/mdtest-1.1/Markdown_Documentation_Syntax.html +++ b/tests/Benchmarks/testfiles/mdtest-1.1/Markdown_Documentation_Syntax.html @@ -935,8 +935,8 @@

    Backslash Escapes

    [] square brackets () parentheses # hash mark -+ plus sign -- minus sign (hyphen) ++ plus sign +- minus sign (hyphen) . dot ! exclamation mark diff --git a/tests/Benchmarks/testfiles/mdtest-1.1/Tabs.html b/tests/Benchmarks/testfiles/mdtest-1.1/Tabs.html index 3301ba803..aa915b0a2 100644 --- a/tests/Benchmarks/testfiles/mdtest-1.1/Tabs.html +++ b/tests/Benchmarks/testfiles/mdtest-1.1/Tabs.html @@ -1,8 +1,9 @@ +

    + this is a list item +indented with tabs

    +
      -
    • this is a list item -indented with tabs

    • -
    • this is a list item -indented with spaces

    • +
    • this is a list item +indented with spaces

    Code:

    @@ -12,13 +13,13 @@

    And:

    -
        this code block is indented by two tabs
    +
    	this code block is indented by two tabs
     

    And:

    -
    +   this is an example list item
    -    indented with tabs
    +
    +	this is an example list item
    +	indented with tabs
     
     +   this is an example list item
         indented with spaces
    diff --git a/tests/Benchmarks/testfiles/mdtest-1.1/Tidyness.text b/tests/Benchmarks/testfiles/mdtest-1.1/Tidyness.text
    index 5f18b8da2..a3ab0a4f5 100644
    --- a/tests/Benchmarks/testfiles/mdtest-1.1/Tidyness.text
    +++ b/tests/Benchmarks/testfiles/mdtest-1.1/Tidyness.text
    @@ -1,5 +1,5 @@
     > A list within a blockquote:
     > 
    -> *	asterisk 1
    -> *	asterisk 2
    -> *	asterisk 3
    +> * asterisk 1
    +> * asterisk 2
    +> * asterisk 3
    diff --git a/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.html b/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.html
    index 990a57984..6a8edf026 100644
    --- a/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.html	
    +++ b/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.html	
    @@ -1,10 +1,9 @@
     
      -
    • List Item:

      - +
    • +

      List Item:

      code block
       
       with a blank line
       
      -

      within a list item.

    diff --git a/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.text b/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.text index 3fa24c31d..9523c11c5 100644 --- a/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.text +++ b/tests/Benchmarks/testfiles/php-markdown/Code block in a list item.text @@ -1,5 +1,5 @@ -* List Item: +* List Item: code block diff --git a/tests/Benchmarks/testfiles/php-markdown/PHP-Specific Bugs.html b/tests/Benchmarks/testfiles/php-markdown/PHP-Specific Bugs.html index c982417b6..f0694d0be 100644 --- a/tests/Benchmarks/testfiles/php-markdown/PHP-Specific Bugs.html +++ b/tests/Benchmarks/testfiles/php-markdown/PHP-Specific Bugs.html @@ -1,17 +1,11 @@ -

    This tests for a bug where quotes escaped by PHP when using +

    This tests for a bug where quotes escaped by PHP when using preg_replace with the /e modifier must be correctly unescaped (hence the _UnslashQuotes function found only in PHP Markdown).

    -

    Headers below should appear exactly as they are typed (no backslash added or removed).

    -

    Header "quoted\" again \""

    -

    Header "quoted\" again \""

    -

    Header "quoted\" again \""

    -

    Test with tabs for _Detab:

    - -
    Code    'block' with    some    "tabs"  and "quotes"
    +
    Code	'block'	with	some	"tabs"	and	"quotes"
     
    diff --git a/tests/FSharp.Literate.Tests/Tests.fs b/tests/FSharp.Literate.Tests/Tests.fs index b5499c7f5..6f56283b7 100644 --- a/tests/FSharp.Literate.Tests/Tests.fs +++ b/tests/FSharp.Literate.Tests/Tests.fs @@ -217,7 +217,7 @@ let ``Correctly handles Norwegian letters in SQL code block (#249)`` () = Æøå""" let doc = Literate.ParseMarkdownString(content, formatAgent=getFormatAgent()) let html = Literate.WriteHtml(doc) - html |> should contain ">Æøå<" + html |> should contain (sprintf ">Æøå%s<" System.Environment.NewLine) [] let ``Correctly handles code starting with whitespace`` () = @@ -226,7 +226,7 @@ let ``Correctly handles code starting with whitespace`` () = inner""" let doc = Literate.ParseMarkdownString(content, formatAgent=getFormatAgent()) let html = Literate.WriteHtml(doc) - html |> should contain "> inner<" + html |> should contain "> inner" [] let ``Correctly handles code which garbage after commands`` () = @@ -236,16 +236,7 @@ let ``Correctly handles code which garbage after commands`` () = inner""" let doc = Literate.ParseMarkdownString(content, formatAgent=getFormatAgent()) let html = Literate.WriteHtml(doc) - html |> should contain "> inner<" - -[] -let ``Correctly handles code after the commands`` () = - // This will work, but trigger a warning! - let content = """ - [lang=unknown] let this be some code""" - let doc = Literate.ParseMarkdownString(content, formatAgent=getFormatAgent()) - let html = Literate.WriteHtml(doc) - html |> should contain " let this be some code" + html |> should contain "> inner" [] let ``Correctly handles apostrophes in JS code block (#213)`` () = diff --git a/tests/FSharp.Markdown.Tests/CommonMarkSpecTest.fs b/tests/FSharp.Markdown.Tests/CommonMarkSpecTest.fs new file mode 100644 index 000000000..c8a82d092 --- /dev/null +++ b/tests/FSharp.Markdown.Tests/CommonMarkSpecTest.fs @@ -0,0 +1,210 @@ +module FSharp.Markdown.Tests.CommonMarkSpecTest + +open System.IO +open System.Diagnostics +let (++) a b = Path.Combine(a, b) +let testdir = __SOURCE_DIRECTORY__ ++ Path.Combine("..", "..", "tests") + +open FSharp.Data +type CommonMarkSpecJson = JsonProvider<"../../tests/commonmark_spec.json"> + +let sample = CommonMarkSpecJson.GetSamples() +let sections = + sample + |> Seq.groupBy (fun s -> s.Section) + +open FsUnit +open NUnit.Framework +open FSharp.Markdown + +let enabledSections = + [ "Fenced code blocks" + "Indented code blocks"] + +let getTests () = + sample + |> Seq.mapi(fun i s -> + let test = TestCaseData(s.Section, s.Markdown, match s.Html with Some html -> html | None -> "") + if enabledSections |> List.contains s.Section |> not then + test.Ignore("section is not enabled") + elif s.Html.IsNone then + test.Ignore("html was not given in the test json") + else test) + +[] +[] +let ``Commonmark specification`` (section:string) (markdown : string) (html : string) = + printfn "Markdown: '%s'" markdown + (Markdown.TransformHtml(markdown, "\n")) + |> should equal html + +[] +let ``manual markdown test: show a blockquote with a code block`` () = + let markdown = """Blockquotes can contain other Markdown elements, including headers, lists, +and code blocks: + + > ## This is a header. + > + > 1. This is the first list item. + > 2. This is the second list item. + > + > Here's some example code: + > + > return shell_exec("echo $input | $markdown_script"); + +Any decent text editor should make email-style quoting easy.""" + let html = """

    Blockquotes can contain other Markdown elements, including headers, lists, +and code blocks:

    +
    > ## This is a header.
    +> 
    +> 1.   This is the first list item.
    +> 2.   This is the second list item.
    +> 
    +> Here's some example code:
    +> 
    +>     return shell_exec("echo $input | $markdown_script");
    +
    +

    Any decent text editor should make email-style quoting easy.

    +""" + (Markdown.TransformHtml(markdown)) + |> should equal html + + +[] +let ``manual markdown test: use spaces in the first line of a code block (indent more than 4 spaces)`` () = + let markdown = """For example, this: + + + +will turn into:""" + let html = """

    For example, this:

    +
        <div class="footer">
    +        &copy; 2004 Foo Corporation
    +    </div>
    +
    +

    will turn into:

    +""" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: use tabs for defining a list`` () = + let markdown = "+ this is a list item +\tindented with tabs + ++ this is a list item + indented with spaces +" + let html = """
      +
    • +

      this is a list item +indented with tabs

      +
    • +
    • +

      this is a list item +indented with spaces

      +
    • +
    +""" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: test if we support continuation lines`` () = + let markdown = "+ this is a list item +with a continuation line + ++ this is a list item + indented with spaces +" + let html = """
      +
    • +

      this is a list item +with a continuation line

      +
    • +
    • +

      this is a list item +indented with spaces

      +
    • +
    +""" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: test if we can handle paragraph ending with two spaces`` () = + let markdown = "this is a paragraph ending with two spaces\t +with a continuation line +" + let html = "

    this is a paragraph ending with two spaces\t
    +with a continuation line

    +" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: test that we don't trim tab character at the end`` () = + let markdown = "this is a paragraph ending with tab \t +with a continuation line +" + let html = "

    this is a paragraph ending with tab \t +with a continuation line

    +" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: test code block (with tabs) in list`` () = + let markdown = "- \t Code Block +" + let html = "
      +
    • +
        Code Block
      +
      +
    • +
    +" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: test code block (with spaces) in list`` () = + let markdown = "- Code Block +" + let html = "
      +
    • +
        Code Block
      +
      +
    • +
    +" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: blockquote with continuation`` () = + let markdown = "> blockquote +with continuation +" + let html = "
    +

    blockquote +with continuation

    +
    +" + (Markdown.TransformHtml(markdown)) + |> should equal html + +[] +let ``manual markdown test: blockquote without continuation`` () = + let markdown = "> blockquote +# without continuation +" + let html = "
    +

    blockquote

    +
    +

    without continuation

    +" + (Markdown.TransformHtml(markdown)) + |> should equal html \ No newline at end of file diff --git a/tests/FSharp.Markdown.Tests/Externals.fs b/tests/FSharp.Markdown.Tests/Externals.fs index efa58a6a3..b8c391d94 100644 --- a/tests/FSharp.Markdown.Tests/Externals.fs +++ b/tests/FSharp.Markdown.Tests/Externals.fs @@ -48,28 +48,9 @@ let failingTests = ] let rec genTestCases (dir : string) = - let generate (source : string) (target : string) (verify : string) = - try - if File.Exists(verify) then - let text = File.ReadAllText(source) - (use wr = new StreamWriter(target) - Markdown.TransformHtml(text, wr, "\r\n")) - let contents = File.ReadAllLines(verify) - File.WriteAllLines(verify, contents) - let targetHtml = removeWhitespace(File.ReadAllText(target)) - let verifyHtml = removeWhitespace(File.ReadAllText(verify)) - if not <| Set.contains (Path.GetFileName(source)) failingTests then - [ TestCaseData(source, target, verifyHtml, targetHtml) ] - else - [] - else - [] - with e -> - printfn " - %s (failed)\n %A" (target.Substring(dir.Length)) e - [] seq { for file in Directory.GetFiles(dir, "*.text") do - yield! generate file (Path.ChangeExtension(file, "2.html")) (Path.ChangeExtension(file, "html")) + yield TestCaseData(dir, file, (Path.ChangeExtension(file, "2.html")), (Path.ChangeExtension(file, "html"))) for d in Directory.GetDirectories(dir) do yield! genTestCases d } @@ -79,13 +60,37 @@ let testdir = __SOURCE_DIRECTORY__ ++ Path.Combine("..","..","tests","Benchmarks let getTest() = genTestCases testdir +let executeTest (dir : string) (source : string) (target : string) (verify : string) = + try + if File.Exists(verify) then + let text = File.ReadAllText(source) + (use wr = new StreamWriter(target) + Markdown.TransformHtml(text, wr, "\r\n")) + let contents = File.ReadAllLines(verify) + File.WriteAllLines(verify, contents) + let targetHtml = removeWhitespace(File.ReadAllText(target)) + let verifyHtml = removeWhitespace(File.ReadAllText(verify)) + if not <| Set.contains (Path.GetFileName(source)) failingTests then + Some (source, target, verifyHtml, targetHtml) + else + None + else + None + with e -> + printfn " - %s (failed)\n %A" (target.Substring(dir.Length)) e + None + [] [] let ``Run external test`` (actualName : string) (expectedName : string) (actual : string) (expected : string) = + match executeTest actualName expectedName actual expected with + | Some (actualName, expectedName, actual, expected) -> if actual = expected then File.Delete(expectedName) - Assert.That(actual, Is.EqualTo(expected), - "Mismatch between '{0}' and the transformed '{1}'.", - actualName, expectedName) + Assert.That( + actual, Is.EqualTo(expected), + "Mismatch between '{0}' and the transformed '{1}'.", + actualName, expectedName) + | None -> () diff --git a/tests/FSharp.Markdown.Tests/FSharp.Markdown.Tests.fsproj b/tests/FSharp.Markdown.Tests/FSharp.Markdown.Tests.fsproj index df42c4b09..cdebb63c3 100644 --- a/tests/FSharp.Markdown.Tests/FSharp.Markdown.Tests.fsproj +++ b/tests/FSharp.Markdown.Tests/FSharp.Markdown.Tests.fsproj @@ -72,6 +72,7 @@ + Always @@ -100,6 +101,29 @@ True + + + + + ..\..\packages\FSharp.Data\lib\net40\FSharp.Data.dll + True + True + + + True + + + + + + + ..\..\packages\FSharp.Data\lib\portable-net40+sl5+wp8+win8\FSharp.Data.dll + True + True + + + + ..\..\packages\NUnit\lib\nunit.framework.dll @@ -107,4 +131,15 @@ True + + + + + ..\..\packages\Zlib.Portable\lib\portable-net4+sl5+wp8+win8+wpa81+MonoTouch+MonoAndroid\Zlib.Portable.dll + True + True + + + + \ No newline at end of file diff --git a/tests/FSharp.Markdown.Tests/Markdown.fs b/tests/FSharp.Markdown.Tests/Markdown.fs index 6124dcf26..7a8143901 100644 --- a/tests/FSharp.Markdown.Tests/Markdown.fs +++ b/tests/FSharp.Markdown.Tests/Markdown.fs @@ -175,64 +175,63 @@ let ``Transform images correctly``() = [] let ``Transform blockquotes correctly``() = let doc = "Here is a quote\r\n\r\n> Sample blockquote\r\n"; - let expected = "

    Here is a quote

    \r\n\r\n
    \r\n

    Sample blockquote

    \r\n
    \r\n" |> properNewLines; + let expected = "

    Here is a quote

    \r\n
    \r\n

    Sample blockquote

    \r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform numbered lists correctly``() = let doc = "A numbered list:\r\n\n1. a\n2. b\n3. c\r\n"; - let expected = "

    A numbered list:

    \r\n\r\n
      \r\n
    1. a
    2. \r\n
    3. b
    4. \r\n
    5. c
    6. \r\n
    \r\n" |> properNewLines; + let expected = "

    A numbered list:

    \r\n
      \r\n
    1. a
    2. \r\n
    3. b
    4. \r\n
    5. c
    6. \r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform bulleted lists correctly``() = let doc = "A bulleted list:\r\n\r\n- a\r\n- b\r\n- c\r\n"; - let expected = "

    A bulleted list:

    \r\n\r\n
      \r\n
    • a
    • \r\n
    • b
    • \r\n
    • c
    • \r\n
    \r\n" |> properNewLines; + let expected = "

    A bulleted list:

    \r\n
      \r\n
    • a
    • \r\n
    • b
    • \r\n
    • c
    • \r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform header 1 correctly``() = let doc = "#Header 1\nHeader 1\r\n========"; - let expected = "

    Header 1

    \r\n\r\n

    Header 1

    \r\n" |> properNewLines; + let expected = "

    Header 1

    \r\n

    Header 1

    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform header 2 correctly``() = let doc = "##Header 2\nHeader 2\r\n--------"; - let expected = "

    Header 2

    \r\n\r\n

    Header 2

    \r\n" |> properNewLines; + let expected = "

    Header 2

    \r\n

    Header 2

    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform code blocks in list correctly``() = let doc = "- code sample:\r\n\r\n\r\n let x = 1\r\n" - let expected = "
      \r\n
    • code sample:
    • \r\n
    \r\n\r\n
    let x = 1
    \r\n" |> properNewLines; + let expected = "
      \r\n
    • code sample:
    • \r\n
    \r\n
    let x = 1\r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected - [] let ``Transform code blocks correctly``() = let doc = "code sample:\r\n\r\n \r\n page title\r\n \r\n"; - let expected = "

    code sample:

    \r\n\r\n
    <head>\r\n<title>page title</title>\r\n</head>
    \r\n" |> properNewLines; + let expected = "

    code sample:

    \r\n
    <head>\r\n<title>page title</title>\r\n</head>\r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform github flavored code blocks correctly``() = let doc = "code sample:\r\n\r\n```\r\n\r\npage title\r\n\r\n```\r\n"; - let expected = "

    code sample:

    \r\n\r\n
    <head>\r\n<title>page title</title>\r\n</head>\r\n
    \r\n" |> properNewLines; + let expected = "

    code sample:

    \r\n
    <head>\r\n<title>page title</title>\r\n</head>\r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected [] let ``Transform github flavored language code blocks correctly``() = let doc = "code sample:\r\n\r\n```markup\r\n\r\npage title\r\n\r\n```\r\n"; - let expected = "

    code sample:

    \r\n\r\n
    <head>\r\n<title>page title</title>\r\n</head>\r\n
    \r\n" |> properNewLines; + let expected = "

    code sample:

    \r\n
    <head>\r\n<title>page title</title>\r\n</head>\r\n
    \r\n" |> properNewLines Markdown.TransformHtml doc |> shouldEqual expected @@ -280,7 +279,7 @@ let ``Transform escaped characters correctly``() = [] let ``Transform horizontal rules correctly``() = let doc = "* * *\r\n\r\n***\r\n\r\n*****\r\n\r\n- - -\r\n\r\n---------------------------------------\r\n\r\n"; - let expected = "
    \r\n\r\n
    \r\n\r\n
    \r\n\r\n
    \r\n\r\n
    \r\n" |> properNewLines; + let expected = "
    \r\n
    \r\n
    \r\n
    \r\n
    \r\n" |> properNewLines Markdown.Parse(doc).Paragraphs |> shouldEqual [ HorizontalRule '*'; HorizontalRule '*'; HorizontalRule '*'; HorizontalRule '-'; HorizontalRule '-' ] Markdown.TransformHtml doc diff --git a/tests/FSharp.Markdown.Tests/paket.references b/tests/FSharp.Markdown.Tests/paket.references index c50de703a..112f82367 100644 --- a/tests/FSharp.Markdown.Tests/paket.references +++ b/tests/FSharp.Markdown.Tests/paket.references @@ -1 +1,2 @@ NUnit +FSharp.Data \ No newline at end of file diff --git a/tests/commonmark_spec.json b/tests/commonmark_spec.json new file mode 100644 index 000000000..4ee27b52a --- /dev/null +++ b/tests/commonmark_spec.json @@ -0,0 +1,4834 @@ +[ + { + "markdown": "\tfoo\tbaz\t\tbim\n", + "start_line": 265, + "section": "Tabs", + "html": "
    foo\tbaz\t\tbim\n
    \n", + "example": 1, + "end_line": 270 + }, + { + "markdown": " \tfoo\tbaz\t\tbim\n", + "start_line": 272, + "section": "Tabs", + "html": "
    foo\tbaz\t\tbim\n
    \n", + "example": 2, + "end_line": 277 + }, + { + "markdown": " a\ta\n ὐ\ta\n", + "start_line": 279, + "section": "Tabs", + "html": "
    a\ta\nὐ\ta\n
    \n", + "example": 3, + "end_line": 286 + }, + { + "markdown": " - foo\n\n\tbar\n", + "start_line": 288, + "section": "Tabs", + "html": "
      \n
    • \n

      foo

      \n

      bar

      \n
    • \n
    \n", + "example": 4, + "end_line": 299 + }, + { + "markdown": ">\tfoo\tbar\n", + "start_line": 301, + "section": "Tabs", + "html": "
    \n

    foo\tbar

    \n
    \n", + "example": 5, + "end_line": 307 + }, + { + "markdown": " foo\n\tbar\n", + "start_line": 309, + "section": "Tabs", + "html": "
    foo\nbar\n
    \n", + "example": 6, + "end_line": 316 + }, + { + "markdown": "- `one\n- two`\n", + "start_line": 339, + "section": "Precedence", + "html": "
      \n
    • `one
    • \n
    • two`
    • \n
    \n", + "example": 7, + "end_line": 347 + }, + { + "markdown": "***\n---\n___\n", + "start_line": 377, + "section": "Thematic breaks", + "html": "
    \n
    \n
    \n", + "example": 8, + "end_line": 385 + }, + { + "markdown": "+++\n", + "start_line": 389, + "section": "Thematic breaks", + "html": "

    +++

    \n", + "example": 9, + "end_line": 393 + }, + { + "markdown": "===\n", + "start_line": 395, + "section": "Thematic breaks", + "html": "

    ===

    \n", + "example": 10, + "end_line": 399 + }, + { + "markdown": "--\n**\n__\n", + "start_line": 403, + "section": "Thematic breaks", + "html": "

    --\n**\n__

    \n", + "example": 11, + "end_line": 411 + }, + { + "markdown": " ***\n ***\n ***\n", + "start_line": 415, + "section": "Thematic breaks", + "html": "
    \n
    \n
    \n", + "example": 12, + "end_line": 423 + }, + { + "markdown": " ***\n", + "start_line": 427, + "section": "Thematic breaks", + "html": "
    ***\n
    \n", + "example": 13, + "end_line": 432 + }, + { + "markdown": "Foo\n ***\n", + "start_line": 434, + "section": "Thematic breaks", + "html": "

    Foo\n***

    \n", + "example": 14, + "end_line": 440 + }, + { + "markdown": "_____________________________________\n", + "start_line": 444, + "section": "Thematic breaks", + "html": "
    \n", + "example": 15, + "end_line": 448 + }, + { + "markdown": " - - -\n", + "start_line": 452, + "section": "Thematic breaks", + "html": "
    \n", + "example": 16, + "end_line": 456 + }, + { + "markdown": " ** * ** * ** * **\n", + "start_line": 458, + "section": "Thematic breaks", + "html": "
    \n", + "example": 17, + "end_line": 462 + }, + { + "markdown": "- - - -\n", + "start_line": 464, + "section": "Thematic breaks", + "html": "
    \n", + "example": 18, + "end_line": 468 + }, + { + "markdown": "- - - - \n", + "start_line": 472, + "section": "Thematic breaks", + "html": "
    \n", + "example": 19, + "end_line": 476 + }, + { + "markdown": "_ _ _ _ a\n\na------\n\n---a---\n", + "start_line": 480, + "section": "Thematic breaks", + "html": "

    _ _ _ _ a

    \n

    a------

    \n

    ---a---

    \n", + "example": 20, + "end_line": 490 + }, + { + "markdown": " *-*\n", + "start_line": 495, + "section": "Thematic breaks", + "html": "

    -

    \n", + "example": 21, + "end_line": 499 + }, + { + "markdown": "- foo\n***\n- bar\n", + "start_line": 503, + "section": "Thematic breaks", + "html": "
      \n
    • foo
    • \n
    \n
    \n
      \n
    • bar
    • \n
    \n", + "example": 22, + "end_line": 515 + }, + { + "markdown": "Foo\n***\nbar\n", + "start_line": 519, + "section": "Thematic breaks", + "html": "

    Foo

    \n
    \n

    bar

    \n", + "example": 23, + "end_line": 527 + }, + { + "markdown": "Foo\n---\nbar\n", + "start_line": 535, + "section": "Thematic breaks", + "html": "

    Foo

    \n

    bar

    \n", + "example": 24, + "end_line": 542 + }, + { + "markdown": "* Foo\n* * *\n* Bar\n", + "start_line": 547, + "section": "Thematic breaks", + "html": "
      \n
    • Foo
    • \n
    \n
    \n
      \n
    • Bar
    • \n
    \n", + "example": 25, + "end_line": 559 + }, + { + "markdown": "- Foo\n- * * *\n", + "start_line": 563, + "section": "Thematic breaks", + "html": "
      \n
    • Foo
    • \n
    • \n
      \n
    • \n
    \n", + "example": 26, + "end_line": 573 + }, + { + "markdown": "# foo\n## foo\n### foo\n#### foo\n##### foo\n###### foo\n", + "start_line": 591, + "section": "ATX headings", + "html": "

    foo

    \n

    foo

    \n

    foo

    \n

    foo

    \n
    foo
    \n
    foo
    \n", + "example": 27, + "end_line": 605 + }, + { + "markdown": "####### foo\n", + "start_line": 609, + "section": "ATX headings", + "html": "

    ####### foo

    \n", + "example": 28, + "end_line": 613 + }, + { + "markdown": "#5 bolt\n\n#hashtag\n", + "start_line": 623, + "section": "ATX headings", + "html": "

    #5 bolt

    \n

    #hashtag

    \n", + "example": 29, + "end_line": 630 + }, + { + "markdown": "#\tfoo\n", + "start_line": 634, + "section": "ATX headings", + "html": "

    #\tfoo

    \n", + "example": 30, + "end_line": 638 + }, + { + "markdown": "\\## foo\n", + "start_line": 642, + "section": "ATX headings", + "html": "

    ## foo

    \n", + "example": 31, + "end_line": 646 + }, + { + "markdown": "# foo *bar* \\*baz\\*\n", + "start_line": 650, + "section": "ATX headings", + "html": "

    foo bar *baz*

    \n", + "example": 32, + "end_line": 654 + }, + { + "markdown": "# foo \n", + "start_line": 658, + "section": "ATX headings", + "html": "

    foo

    \n", + "example": 33, + "end_line": 662 + }, + { + "markdown": " ### foo\n ## foo\n # foo\n", + "start_line": 666, + "section": "ATX headings", + "html": "

    foo

    \n

    foo

    \n

    foo

    \n", + "example": 34, + "end_line": 674 + }, + { + "markdown": " # foo\n", + "start_line": 678, + "section": "ATX headings", + "html": "
    # foo\n
    \n", + "example": 35, + "end_line": 683 + }, + { + "markdown": "foo\n # bar\n", + "start_line": 685, + "section": "ATX headings", + "html": "

    foo\n# bar

    \n", + "example": 36, + "end_line": 691 + }, + { + "markdown": "## foo ##\n ### bar ###\n", + "start_line": 695, + "section": "ATX headings", + "html": "

    foo

    \n

    bar

    \n", + "example": 37, + "end_line": 701 + }, + { + "markdown": "# foo ##################################\n##### foo ##\n", + "start_line": 705, + "section": "ATX headings", + "html": "

    foo

    \n
    foo
    \n", + "example": 38, + "end_line": 711 + }, + { + "markdown": "### foo ### \n", + "start_line": 715, + "section": "ATX headings", + "html": "

    foo

    \n", + "example": 39, + "end_line": 719 + }, + { + "markdown": "### foo ### b\n", + "start_line": 725, + "section": "ATX headings", + "html": "

    foo ### b

    \n", + "example": 40, + "end_line": 729 + }, + { + "markdown": "# foo#\n", + "start_line": 733, + "section": "ATX headings", + "html": "

    foo#

    \n", + "example": 41, + "end_line": 737 + }, + { + "markdown": "### foo \\###\n## foo #\\##\n# foo \\#\n", + "start_line": 742, + "section": "ATX headings", + "html": "

    foo ###

    \n

    foo ###

    \n

    foo #

    \n", + "example": 42, + "end_line": 750 + }, + { + "markdown": "****\n## foo\n****\n", + "start_line": 755, + "section": "ATX headings", + "html": "
    \n

    foo

    \n
    \n", + "example": 43, + "end_line": 763 + }, + { + "markdown": "Foo bar\n# baz\nBar foo\n", + "start_line": 765, + "section": "ATX headings", + "html": "

    Foo bar

    \n

    baz

    \n

    Bar foo

    \n", + "example": 44, + "end_line": 773 + }, + { + "markdown": "## \n#\n### ###\n", + "start_line": 777, + "section": "ATX headings", + "html": "

    \n

    \n

    \n", + "example": 45, + "end_line": 785 + }, + { + "markdown": "Foo *bar*\n=========\n\nFoo *bar*\n---------\n", + "start_line": 818, + "section": "Setext headings", + "html": "

    Foo bar

    \n

    Foo bar

    \n", + "example": 46, + "end_line": 827 + }, + { + "markdown": "Foo\n-------------------------\n\nFoo\n=\n", + "start_line": 831, + "section": "Setext headings", + "html": "

    Foo

    \n

    Foo

    \n", + "example": 47, + "end_line": 840 + }, + { + "markdown": " Foo\n---\n\n Foo\n-----\n\n Foo\n ===\n", + "start_line": 845, + "section": "Setext headings", + "html": "

    Foo

    \n

    Foo

    \n

    Foo

    \n", + "example": 48, + "end_line": 858 + }, + { + "markdown": " Foo\n ---\n\n Foo\n---\n", + "start_line": 862, + "section": "Setext headings", + "html": "
    Foo\n---\n\nFoo\n
    \n
    \n", + "example": 49, + "end_line": 875 + }, + { + "markdown": "Foo\n ---- \n", + "start_line": 880, + "section": "Setext headings", + "html": "

    Foo

    \n", + "example": 50, + "end_line": 885 + }, + { + "markdown": "Foo\n ---\n", + "start_line": 889, + "section": "Setext headings", + "html": "

    Foo\n---

    \n", + "example": 51, + "end_line": 895 + }, + { + "markdown": "Foo\n= =\n\nFoo\n--- -\n", + "start_line": 899, + "section": "Setext headings", + "html": "

    Foo\n= =

    \n

    Foo

    \n
    \n", + "example": 52, + "end_line": 910 + }, + { + "markdown": "Foo \n-----\n", + "start_line": 914, + "section": "Setext headings", + "html": "

    Foo

    \n", + "example": 53, + "end_line": 919 + }, + { + "markdown": "Foo\\\n----\n", + "start_line": 923, + "section": "Setext headings", + "html": "

    Foo\\

    \n", + "example": 54, + "end_line": 928 + }, + { + "markdown": "`Foo\n----\n`\n\n\n", + "start_line": 933, + "section": "Setext headings", + "html": "

    `Foo

    \n

    `

    \n

    <a title="a lot

    \n

    of dashes"/>

    \n", + "example": 55, + "end_line": 946 + }, + { + "markdown": "> Foo\n---\n", + "start_line": 951, + "section": "Setext headings", + "html": "
    \n

    Foo

    \n
    \n
    \n", + "example": 56, + "end_line": 959 + }, + { + "markdown": "- Foo\n---\n", + "start_line": 961, + "section": "Setext headings", + "html": "
      \n
    • Foo
    • \n
    \n
    \n", + "example": 57, + "end_line": 969 + }, + { + "markdown": "Foo\nBar\n---\n\nFoo\nBar\n===\n", + "start_line": 973, + "section": "Setext headings", + "html": "

    Foo\nBar

    \n
    \n

    Foo\nBar\n===

    \n", + "example": 58, + "end_line": 988 + }, + { + "markdown": "---\nFoo\n---\nBar\n---\nBaz\n", + "start_line": 992, + "section": "Setext headings", + "html": "
    \n

    Foo

    \n

    Bar

    \n

    Baz

    \n", + "example": 59, + "end_line": 1004 + }, + { + "markdown": "\n====\n", + "start_line": 1008, + "section": "Setext headings", + "html": "

    ====

    \n", + "example": 60, + "end_line": 1013 + }, + { + "markdown": "---\n---\n", + "start_line": 1019, + "section": "Setext headings", + "html": "
    \n
    \n", + "example": 61, + "end_line": 1025 + }, + { + "markdown": "- foo\n-----\n", + "start_line": 1027, + "section": "Setext headings", + "html": "
      \n
    • foo
    • \n
    \n
    \n", + "example": 62, + "end_line": 1035 + }, + { + "markdown": " foo\n---\n", + "start_line": 1037, + "section": "Setext headings", + "html": "
    foo\n
    \n
    \n", + "example": 63, + "end_line": 1044 + }, + { + "markdown": "> foo\n-----\n", + "start_line": 1046, + "section": "Setext headings", + "html": "
    \n

    foo

    \n
    \n
    \n", + "example": 64, + "end_line": 1054 + }, + { + "markdown": "\\> foo\n------\n", + "start_line": 1059, + "section": "Setext headings", + "html": "

    > foo

    \n", + "example": 65, + "end_line": 1064 + }, + { + "markdown": " a simple\n indented code block\n", + "start_line": 1081, + "section": "Indented code blocks", + "html": "
    a simple\n  indented code block\n
    \n", + "example": 66, + "end_line": 1088 + }, + { + "markdown": " - foo\n\n bar\n", + "start_line": 1094, + "section": "Indented code blocks", + "html": "
      \n
    • \n

      foo

      \n

      bar

      \n
    • \n
    \n", + "example": 67, + "end_line": 1105 + }, + { + "markdown": "1. foo\n\n - bar\n", + "start_line": 1107, + "section": "Indented code blocks", + "html": "
      \n
    1. \n

      foo

      \n
        \n
      • bar
      • \n
      \n
    2. \n
    \n", + "example": 68, + "end_line": 1120 + }, + { + "markdown": "
    \n *hi*\n\n - one\n", + "start_line": 1126, + "section": "Indented code blocks", + "html": "
    <a/>\n*hi*\n\n- one\n
    \n", + "example": 69, + "end_line": 1137 + }, + { + "markdown": " chunk1\n\n chunk2\n \n \n \n chunk3\n", + "start_line": 1141, + "section": "Indented code blocks", + "html": "
    chunk1\n\nchunk2\n\n\n\nchunk3\n
    \n", + "example": 70, + "end_line": 1158 + }, + { + "markdown": " chunk1\n \n chunk2\n", + "start_line": 1163, + "section": "Indented code blocks", + "html": "
    chunk1\n  \n  chunk2\n
    \n", + "example": 71, + "end_line": 1172 + }, + { + "markdown": "Foo\n bar\n\n", + "start_line": 1177, + "section": "Indented code blocks", + "html": "

    Foo\nbar

    \n", + "example": 72, + "end_line": 1184 + }, + { + "markdown": " foo\nbar\n", + "start_line": 1190, + "section": "Indented code blocks", + "html": "
    foo\n
    \n

    bar

    \n", + "example": 73, + "end_line": 1197 + }, + { + "markdown": "# Heading\n foo\nHeading\n------\n foo\n----\n", + "start_line": 1202, + "section": "Indented code blocks", + "html": "

    Heading

    \n
    foo\n
    \n

    Heading

    \n
    foo\n
    \n
    \n", + "example": 74, + "end_line": 1217 + }, + { + "markdown": " foo\n bar\n", + "start_line": 1221, + "section": "Indented code blocks", + "html": "
        foo\nbar\n
    \n", + "example": 75, + "end_line": 1228 + }, + { + "markdown": "\n \n foo\n \n\n", + "start_line": 1233, + "section": "Indented code blocks", + "html": "
    foo\n
    \n", + "example": 76, + "end_line": 1242 + }, + { + "markdown": " foo \n", + "start_line": 1246, + "section": "Indented code blocks", + "html": "
    foo  \n
    \n", + "example": 77, + "end_line": 1251 + }, + { + "markdown": "```\n<\n >\n```\n", + "start_line": 1300, + "section": "Fenced code blocks", + "html": "
    <\n >\n
    \n", + "example": 78, + "end_line": 1309 + }, + { + "markdown": "~~~\n<\n >\n~~~\n", + "start_line": 1313, + "section": "Fenced code blocks", + "html": "
    <\n >\n
    \n", + "example": 79, + "end_line": 1322 + }, + { + "markdown": "```\naaa\n~~~\n```\n", + "start_line": 1327, + "section": "Fenced code blocks", + "html": "
    aaa\n~~~\n
    \n", + "example": 80, + "end_line": 1336 + }, + { + "markdown": "~~~\naaa\n```\n~~~\n", + "start_line": 1338, + "section": "Fenced code blocks", + "html": "
    aaa\n```\n
    \n", + "example": 81, + "end_line": 1347 + }, + { + "markdown": "````\naaa\n```\n``````\n", + "start_line": 1351, + "section": "Fenced code blocks", + "html": "
    aaa\n```\n
    \n", + "example": 82, + "end_line": 1360 + }, + { + "markdown": "~~~~\naaa\n~~~\n~~~~\n", + "start_line": 1362, + "section": "Fenced code blocks", + "html": "
    aaa\n~~~\n
    \n", + "example": 83, + "end_line": 1371 + }, + { + "markdown": "```\n", + "start_line": 1376, + "section": "Fenced code blocks", + "html": "
    \n", + "example": 84, + "end_line": 1380 + }, + { + "markdown": "`````\n\n```\naaa\n", + "start_line": 1382, + "section": "Fenced code blocks", + "html": "
    \n```\naaa\n
    \n", + "example": 85, + "end_line": 1392 + }, + { + "markdown": "> ```\n> aaa\n\nbbb\n", + "start_line": 1394, + "section": "Fenced code blocks", + "html": "
    \n
    aaa\n
    \n
    \n

    bbb

    \n", + "example": 86, + "end_line": 1405 + }, + { + "markdown": "```\n\n \n```\n", + "start_line": 1409, + "section": "Fenced code blocks", + "html": "
    \n  \n
    \n", + "example": 87, + "end_line": 1418 + }, + { + "markdown": "```\n```\n", + "start_line": 1422, + "section": "Fenced code blocks", + "html": "
    \n", + "example": 88, + "end_line": 1427 + }, + { + "markdown": " ```\n aaa\naaa\n```\n", + "start_line": 1433, + "section": "Fenced code blocks", + "html": "
    aaa\naaa\n
    \n", + "example": 89, + "end_line": 1442 + }, + { + "markdown": " ```\naaa\n aaa\naaa\n ```\n", + "start_line": 1444, + "section": "Fenced code blocks", + "html": "
    aaa\naaa\naaa\n
    \n", + "example": 90, + "end_line": 1455 + }, + { + "markdown": " ```\n aaa\n aaa\n aaa\n ```\n", + "start_line": 1457, + "section": "Fenced code blocks", + "html": "
    aaa\n aaa\naaa\n
    \n", + "example": 91, + "end_line": 1468 + }, + { + "markdown": " ```\n aaa\n ```\n", + "start_line": 1472, + "section": "Fenced code blocks", + "html": "
    ```\naaa\n```\n
    \n", + "example": 92, + "end_line": 1481 + }, + { + "markdown": "```\naaa\n ```\n", + "start_line": 1486, + "section": "Fenced code blocks", + "html": "
    aaa\n
    \n", + "example": 93, + "end_line": 1493 + }, + { + "markdown": " ```\naaa\n ```\n", + "start_line": 1495, + "section": "Fenced code blocks", + "html": "
    aaa\n
    \n", + "example": 94, + "end_line": 1502 + }, + { + "markdown": "```\naaa\n ```\n", + "start_line": 1506, + "section": "Fenced code blocks", + "html": "
    aaa\n    ```\n
    \n", + "example": 95, + "end_line": 1514 + }, + { + "markdown": "``` ```\naaa\n", + "start_line": 1519, + "section": "Fenced code blocks", + "html": "

    \naaa

    \n", + "example": 96, + "end_line": 1525 + }, + { + "markdown": "~~~~~~\naaa\n~~~ ~~\n", + "start_line": 1527, + "section": "Fenced code blocks", + "html": "
    aaa\n~~~ ~~\n
    \n", + "example": 97, + "end_line": 1535 + }, + { + "markdown": "foo\n```\nbar\n```\nbaz\n", + "start_line": 1540, + "section": "Fenced code blocks", + "html": "

    foo

    \n
    bar\n
    \n

    baz

    \n", + "example": 98, + "end_line": 1551 + }, + { + "markdown": "foo\n---\n~~~\nbar\n~~~\n# baz\n", + "start_line": 1556, + "section": "Fenced code blocks", + "html": "

    foo

    \n
    bar\n
    \n

    baz

    \n", + "example": 99, + "end_line": 1568 + }, + { + "markdown": "```ruby\ndef foo(x)\n return 3\nend\n```\n", + "start_line": 1575, + "section": "Fenced code blocks", + "html": "
    def foo(x)\n  return 3\nend\n
    \n", + "example": 100, + "end_line": 1586 + }, + { + "markdown": "~~~~ ruby startline=3 $%@#$\ndef foo(x)\n return 3\nend\n~~~~~~~\n", + "start_line": 1588, + "section": "Fenced code blocks", + "html": "
    def foo(x)\n  return 3\nend\n
    \n", + "example": 101, + "end_line": 1599 + }, + { + "markdown": "````;\n````\n", + "start_line": 1601, + "section": "Fenced code blocks", + "html": "
    \n", + "example": 102, + "end_line": 1606 + }, + { + "markdown": "``` aa ```\nfoo\n", + "start_line": 1610, + "section": "Fenced code blocks", + "html": "

    aa\nfoo

    \n", + "example": 103, + "end_line": 1616 + }, + { + "markdown": "```\n``` aaa\n```\n", + "start_line": 1620, + "section": "Fenced code blocks", + "html": "
    ``` aaa\n
    \n", + "example": 104, + "end_line": 1627 + }, + { + "markdown": "\n \n \n \n
    \n hi\n
    \n\nokay.\n", + "start_line": 1693, + "section": "HTML blocks", + "html": "\n \n \n \n
    \n hi\n
    \n

    okay.

    \n", + "example": 105, + "end_line": 1712 + }, + { + "markdown": "
    \n*foo*\n", + "example": 107, + "end_line": 1732 + }, + { + "markdown": "
    \n\n*Markdown*\n\n
    \n", + "start_line": 1736, + "section": "HTML blocks", + "html": "
    \n

    Markdown

    \n
    \n", + "example": 108, + "end_line": 1746 + }, + { + "markdown": "
    \n
    \n", + "start_line": 1751, + "section": "HTML blocks", + "html": "
    \n
    \n", + "example": 109, + "end_line": 1759 + }, + { + "markdown": "
    \n
    \n", + "start_line": 1761, + "section": "HTML blocks", + "html": "
    \n
    \n", + "example": 110, + "end_line": 1769 + }, + { + "markdown": "
    \n*foo*\n\n*bar*\n", + "start_line": 1772, + "section": "HTML blocks", + "html": "
    \n*foo*\n

    bar

    \n", + "example": 111, + "end_line": 1781 + }, + { + "markdown": "
    \n", + "start_line": 1817, + "section": "HTML blocks", + "html": "\n", + "example": 115, + "end_line": 1821 + }, + { + "markdown": "
    \nfoo\n
    \n", + "start_line": 1823, + "section": "HTML blocks", + "html": "
    \nfoo\n
    \n", + "example": 116, + "end_line": 1831 + }, + { + "markdown": "
    \n``` c\nint x = 33;\n```\n", + "start_line": 1839, + "section": "HTML blocks", + "html": "
    \n``` c\nint x = 33;\n```\n", + "example": 117, + "end_line": 1849 + }, + { + "markdown": "\n*bar*\n\n", + "start_line": 1855, + "section": "HTML blocks", + "html": "\n*bar*\n\n", + "example": 118, + "end_line": 1863 + }, + { + "markdown": "\n*bar*\n\n", + "start_line": 1867, + "section": "HTML blocks", + "html": "\n*bar*\n\n", + "example": 119, + "end_line": 1875 + }, + { + "markdown": "\n*bar*\n\n", + "start_line": 1877, + "section": "HTML blocks", + "html": "\n*bar*\n\n", + "example": 120, + "end_line": 1885 + }, + { + "markdown": "\n*bar*\n", + "start_line": 1887, + "section": "HTML blocks", + "html": "\n*bar*\n", + "example": 121, + "end_line": 1893 + }, + { + "markdown": "\n*foo*\n\n", + "start_line": 1901, + "section": "HTML blocks", + "html": "\n*foo*\n\n", + "example": 122, + "end_line": 1909 + }, + { + "markdown": "\n\n*foo*\n\n\n", + "start_line": 1915, + "section": "HTML blocks", + "html": "\n

    foo

    \n
    \n", + "example": 123, + "end_line": 1925 + }, + { + "markdown": "*foo*\n", + "start_line": 1932, + "section": "HTML blocks", + "html": "

    foo

    \n", + "example": 124, + "end_line": 1936 + }, + { + "markdown": "
    \nimport Text.HTML.TagSoup\n\nmain :: IO ()\nmain = print $ parseTags tags\n
    \n", + "start_line": 1947, + "section": "HTML blocks", + "html": "
    \nimport Text.HTML.TagSoup\n\nmain :: IO ()\nmain = print $ parseTags tags\n
    \n", + "example": 125, + "end_line": 1961 + }, + { + "markdown": "\n", + "start_line": 1965, + "section": "HTML blocks", + "html": "\n", + "example": 126, + "end_line": 1977 + }, + { + "markdown": "\nh1 {color:red;}\n\np {color:blue;}\n\n", + "start_line": 1981, + "section": "HTML blocks", + "html": "\nh1 {color:red;}\n\np {color:blue;}\n\n", + "example": 127, + "end_line": 1995 + }, + { + "markdown": "\n\nfoo\n", + "start_line": 2001, + "section": "HTML blocks", + "html": "\n\nfoo\n", + "example": 128, + "end_line": 2011 + }, + { + "markdown": ">
    \n> foo\n\nbar\n", + "start_line": 2013, + "section": "HTML blocks", + "html": "
    \n
    \nfoo\n
    \n

    bar

    \n", + "example": 129, + "end_line": 2024 + }, + { + "markdown": "-
    \n- foo\n", + "start_line": 2026, + "section": "HTML blocks", + "html": "
      \n
    • \n
      \n
    • \n
    • foo
    • \n
    \n", + "example": 130, + "end_line": 2036 + }, + { + "markdown": "\n*foo*\n", + "start_line": 2040, + "section": "HTML blocks", + "html": "\n

    foo

    \n", + "example": 131, + "end_line": 2046 + }, + { + "markdown": "*bar*\n*baz*\n", + "start_line": 2048, + "section": "HTML blocks", + "html": "*bar*\n

    baz

    \n", + "example": 132, + "end_line": 2054 + }, + { + "markdown": "1. *bar*\n", + "start_line": 2059, + "section": "HTML blocks", + "html": "1. *bar*\n", + "example": 133, + "end_line": 2067 + }, + { + "markdown": "\n", + "start_line": 2071, + "section": "HTML blocks", + "html": "\n", + "example": 134, + "end_line": 2081 + }, + { + "markdown": "';\n\n?>\n", + "start_line": 2086, + "section": "HTML blocks", + "html": "';\n\n?>\n", + "example": 135, + "end_line": 2098 + }, + { + "markdown": "\n", + "start_line": 2102, + "section": "HTML blocks", + "html": "\n", + "example": 136, + "end_line": 2106 + }, + { + "markdown": "\n", + "start_line": 2110, + "section": "HTML blocks", + "html": "\n", + "example": 137, + "end_line": 2136 + }, + { + "markdown": " \n\n \n", + "start_line": 2140, + "section": "HTML blocks", + "html": " \n
    <!-- foo -->\n
    \n", + "example": 138, + "end_line": 2148 + }, + { + "markdown": "
    \n\n
    \n", + "start_line": 2150, + "section": "HTML blocks", + "html": "
    \n
    <div>\n
    \n", + "example": 139, + "end_line": 2158 + }, + { + "markdown": "Foo\n
    \nbar\n
    \n", + "start_line": 2163, + "section": "HTML blocks", + "html": "

    Foo

    \n
    \nbar\n
    \n", + "example": 140, + "end_line": 2173 + }, + { + "markdown": "
    \nbar\n
    \n*foo*\n", + "start_line": 2178, + "section": "HTML blocks", + "html": "
    \nbar\n
    \n*foo*\n", + "example": 141, + "end_line": 2188 + }, + { + "markdown": "Foo\n\nbaz\n", + "start_line": 2192, + "section": "HTML blocks", + "html": "

    Foo\n\nbaz

    \n", + "example": 142, + "end_line": 2200 + }, + { + "markdown": "
    \n\n*Emphasized* text.\n\n
    \n", + "start_line": 2232, + "section": "HTML blocks", + "html": "
    \n

    Emphasized text.

    \n
    \n", + "example": 143, + "end_line": 2242 + }, + { + "markdown": "
    \n*Emphasized* text.\n
    \n", + "start_line": 2244, + "section": "HTML blocks", + "html": "
    \n*Emphasized* text.\n
    \n", + "example": 144, + "end_line": 2252 + }, + { + "markdown": "\n\n\n\n\n\n\n\n
    \nHi\n
    \n", + "start_line": 2265, + "section": "HTML blocks", + "html": "\n\n\n\n
    \nHi\n
    \n", + "example": 145, + "end_line": 2285 + }, + { + "markdown": "\n\n \n\n \n\n \n\n
    \n Hi\n
    \n", + "start_line": 2291, + "section": "HTML blocks", + "html": "\n \n
    <td>\n  Hi\n</td>\n
    \n \n
    \n", + "example": 146, + "end_line": 2312 + }, + { + "markdown": "[foo]: /url \"title\"\n\n[foo]\n", + "start_line": 2338, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 147, + "end_line": 2344 + }, + { + "markdown": " [foo]: \n /url \n 'the title' \n\n[foo]\n", + "start_line": 2346, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 148, + "end_line": 2354 + }, + { + "markdown": "[Foo*bar\\]]:my_(url) 'title (with parens)'\n\n[Foo*bar\\]]\n", + "start_line": 2356, + "section": "Link reference definitions", + "html": "

    Foo*bar]

    \n", + "example": 149, + "end_line": 2362 + }, + { + "markdown": "[Foo bar]:\n\n'title'\n\n[Foo bar]\n", + "start_line": 2364, + "section": "Link reference definitions", + "html": "

    Foo bar

    \n", + "example": 150, + "end_line": 2372 + }, + { + "markdown": "[foo]: /url '\ntitle\nline1\nline2\n'\n\n[foo]\n", + "start_line": 2376, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 151, + "end_line": 2390 + }, + { + "markdown": "[foo]: /url 'title\n\nwith blank line'\n\n[foo]\n", + "start_line": 2394, + "section": "Link reference definitions", + "html": "

    [foo]: /url 'title

    \n

    with blank line'

    \n

    [foo]

    \n", + "example": 152, + "end_line": 2404 + }, + { + "markdown": "[foo]:\n/url\n\n[foo]\n", + "start_line": 2408, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 153, + "end_line": 2415 + }, + { + "markdown": "[foo]:\n\n[foo]\n", + "start_line": 2419, + "section": "Link reference definitions", + "html": "

    [foo]:

    \n

    [foo]

    \n", + "example": 154, + "end_line": 2426 + }, + { + "markdown": "[foo]: /url\\bar\\*baz \"foo\\\"bar\\baz\"\n\n[foo]\n", + "start_line": 2431, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 155, + "end_line": 2437 + }, + { + "markdown": "[foo]\n\n[foo]: url\n", + "start_line": 2441, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 156, + "end_line": 2447 + }, + { + "markdown": "[foo]\n\n[foo]: first\n[foo]: second\n", + "start_line": 2452, + "section": "Link reference definitions", + "html": "

    foo

    \n", + "example": 157, + "end_line": 2459 + }, + { + "markdown": "[FOO]: /url\n\n[Foo]\n", + "start_line": 2464, + "section": "Link reference definitions", + "html": "

    Foo

    \n", + "example": 158, + "end_line": 2470 + }, + { + "markdown": "[ΑΓΩ]: /φου\n\n[αγω]\n", + "start_line": 2472, + "section": "Link reference definitions", + "html": "

    αγω

    \n", + "example": 159, + "end_line": 2478 + }, + { + "markdown": "[foo]: /url\n", + "start_line": 2483, + "section": "Link reference definitions", + "html": "", + "example": 160, + "end_line": 2486 + }, + { + "markdown": "[\nfoo\n]: /url\nbar\n", + "start_line": 2490, + "section": "Link reference definitions", + "html": "

    bar

    \n", + "example": 161, + "end_line": 2497 + }, + { + "markdown": "[foo]: /url \"title\" ok\n", + "start_line": 2502, + "section": "Link reference definitions", + "html": "

    [foo]: /url "title" ok

    \n", + "example": 162, + "end_line": 2506 + }, + { + "markdown": "[foo]: /url\n\"title\" ok\n", + "start_line": 2510, + "section": "Link reference definitions", + "html": "

    "title" ok

    \n", + "example": 163, + "end_line": 2515 + }, + { + "markdown": " [foo]: /url \"title\"\n\n[foo]\n", + "start_line": 2520, + "section": "Link reference definitions", + "html": "
    [foo]: /url "title"\n
    \n

    [foo]

    \n", + "example": 164, + "end_line": 2528 + }, + { + "markdown": "```\n[foo]: /url\n```\n\n[foo]\n", + "start_line": 2533, + "section": "Link reference definitions", + "html": "
    [foo]: /url\n
    \n

    [foo]

    \n", + "example": 165, + "end_line": 2543 + }, + { + "markdown": "Foo\n[bar]: /baz\n\n[bar]\n", + "start_line": 2547, + "section": "Link reference definitions", + "html": "

    Foo\n[bar]: /baz

    \n

    [bar]

    \n", + "example": 166, + "end_line": 2556 + }, + { + "markdown": "# [Foo]\n[foo]: /url\n> bar\n", + "start_line": 2561, + "section": "Link reference definitions", + "html": "

    Foo

    \n
    \n

    bar

    \n
    \n", + "example": 167, + "end_line": 2570 + }, + { + "markdown": "[foo]: /foo-url \"foo\"\n[bar]: /bar-url\n \"bar\"\n[baz]: /baz-url\n\n[foo],\n[bar],\n[baz]\n", + "start_line": 2575, + "section": "Link reference definitions", + "html": "

    foo,\nbar,\nbaz

    \n", + "example": 168, + "end_line": 2588 + }, + { + "markdown": "[foo]\n\n> [foo]: /url\n", + "start_line": 2595, + "section": "Link reference definitions", + "html": "

    foo

    \n
    \n
    \n", + "example": 169, + "end_line": 2603 + }, + { + "markdown": "aaa\n\nbbb\n", + "start_line": 2617, + "section": "Paragraphs", + "html": "

    aaa

    \n

    bbb

    \n", + "example": 170, + "end_line": 2624 + }, + { + "markdown": "aaa\nbbb\n\nccc\nddd\n", + "start_line": 2628, + "section": "Paragraphs", + "html": "

    aaa\nbbb

    \n

    ccc\nddd

    \n", + "example": 171, + "end_line": 2639 + }, + { + "markdown": "aaa\n\n\nbbb\n", + "start_line": 2643, + "section": "Paragraphs", + "html": "

    aaa

    \n

    bbb

    \n", + "example": 172, + "end_line": 2651 + }, + { + "markdown": " aaa\n bbb\n", + "start_line": 2655, + "section": "Paragraphs", + "html": "

    aaa\nbbb

    \n", + "example": 173, + "end_line": 2661 + }, + { + "markdown": "aaa\n bbb\n ccc\n", + "start_line": 2666, + "section": "Paragraphs", + "html": "

    aaa\nbbb\nccc

    \n", + "example": 174, + "end_line": 2674 + }, + { + "markdown": " aaa\nbbb\n", + "start_line": 2679, + "section": "Paragraphs", + "html": "

    aaa\nbbb

    \n", + "example": 175, + "end_line": 2685 + }, + { + "markdown": " aaa\nbbb\n", + "start_line": 2687, + "section": "Paragraphs", + "html": "
    aaa\n
    \n

    bbb

    \n", + "example": 176, + "end_line": 2694 + }, + { + "markdown": "aaa \nbbb \n", + "start_line": 2700, + "section": "Paragraphs", + "html": "

    aaa
    \nbbb

    \n", + "example": 177, + "end_line": 2706 + }, + { + "markdown": " \n\naaa\n \n\n# aaa\n\n \n", + "start_line": 2716, + "section": "Blank lines", + "html": "

    aaa

    \n

    aaa

    \n", + "example": 178, + "end_line": 2728 + }, + { + "markdown": "> # Foo\n> bar\n> baz\n", + "start_line": 2781, + "section": "Block quotes", + "html": "
    \n

    Foo

    \n

    bar\nbaz

    \n
    \n", + "example": 179, + "end_line": 2791 + }, + { + "markdown": "># Foo\n>bar\n> baz\n", + "start_line": 2795, + "section": "Block quotes", + "html": "
    \n

    Foo

    \n

    bar\nbaz

    \n
    \n", + "example": 180, + "end_line": 2805 + }, + { + "markdown": " > # Foo\n > bar\n > baz\n", + "start_line": 2809, + "section": "Block quotes", + "html": "
    \n

    Foo

    \n

    bar\nbaz

    \n
    \n", + "example": 181, + "end_line": 2819 + }, + { + "markdown": " > # Foo\n > bar\n > baz\n", + "start_line": 2823, + "section": "Block quotes", + "html": "
    > # Foo\n> bar\n> baz\n
    \n", + "example": 182, + "end_line": 2832 + }, + { + "markdown": "> # Foo\n> bar\nbaz\n", + "start_line": 2837, + "section": "Block quotes", + "html": "
    \n

    Foo

    \n

    bar\nbaz

    \n
    \n", + "example": 183, + "end_line": 2847 + }, + { + "markdown": "> bar\nbaz\n> foo\n", + "start_line": 2852, + "section": "Block quotes", + "html": "
    \n

    bar\nbaz\nfoo

    \n
    \n", + "example": 184, + "end_line": 2862 + }, + { + "markdown": "> foo\n---\n", + "start_line": 2875, + "section": "Block quotes", + "html": "
    \n

    foo

    \n
    \n
    \n", + "example": 185, + "end_line": 2883 + }, + { + "markdown": "> - foo\n- bar\n", + "start_line": 2894, + "section": "Block quotes", + "html": "
    \n
      \n
    • foo
    • \n
    \n
    \n
      \n
    • bar
    • \n
    \n", + "example": 186, + "end_line": 2906 + }, + { + "markdown": "> foo\n bar\n", + "start_line": 2911, + "section": "Block quotes", + "html": "
    \n
    foo\n
    \n
    \n
    bar\n
    \n", + "example": 187, + "end_line": 2921 + }, + { + "markdown": "> ```\nfoo\n```\n", + "start_line": 2923, + "section": "Block quotes", + "html": "
    \n
    \n
    \n

    foo

    \n
    \n", + "example": 188, + "end_line": 2933 + }, + { + "markdown": "> foo\n - bar\n", + "start_line": 2938, + "section": "Block quotes", + "html": "
    \n

    foo\n- bar

    \n
    \n", + "example": 189, + "end_line": 2946 + }, + { + "markdown": ">\n", + "start_line": 2961, + "section": "Block quotes", + "html": "
    \n
    \n", + "example": 190, + "end_line": 2966 + }, + { + "markdown": ">\n> \n> \n", + "start_line": 2968, + "section": "Block quotes", + "html": "
    \n
    \n", + "example": 191, + "end_line": 2975 + }, + { + "markdown": ">\n> foo\n> \n", + "start_line": 2979, + "section": "Block quotes", + "html": "
    \n

    foo

    \n
    \n", + "example": 192, + "end_line": 2987 + }, + { + "markdown": "> foo\n\n> bar\n", + "start_line": 2991, + "section": "Block quotes", + "html": "
    \n

    foo

    \n
    \n
    \n

    bar

    \n
    \n", + "example": 193, + "end_line": 3002 + }, + { + "markdown": "> foo\n> bar\n", + "start_line": 3012, + "section": "Block quotes", + "html": "
    \n

    foo\nbar

    \n
    \n", + "example": 194, + "end_line": 3020 + }, + { + "markdown": "> foo\n>\n> bar\n", + "start_line": 3024, + "section": "Block quotes", + "html": "
    \n

    foo

    \n

    bar

    \n
    \n", + "example": 195, + "end_line": 3033 + }, + { + "markdown": "foo\n> bar\n", + "start_line": 3037, + "section": "Block quotes", + "html": "

    foo

    \n
    \n

    bar

    \n
    \n", + "example": 196, + "end_line": 3045 + }, + { + "markdown": "> aaa\n***\n> bbb\n", + "start_line": 3050, + "section": "Block quotes", + "html": "
    \n

    aaa

    \n
    \n
    \n
    \n

    bbb

    \n
    \n", + "example": 197, + "end_line": 3062 + }, + { + "markdown": "> bar\nbaz\n", + "start_line": 3067, + "section": "Block quotes", + "html": "
    \n

    bar\nbaz

    \n
    \n", + "example": 198, + "end_line": 3075 + }, + { + "markdown": "> bar\n\nbaz\n", + "start_line": 3077, + "section": "Block quotes", + "html": "
    \n

    bar

    \n
    \n

    baz

    \n", + "example": 199, + "end_line": 3086 + }, + { + "markdown": "> bar\n>\nbaz\n", + "start_line": 3088, + "section": "Block quotes", + "html": "
    \n

    bar

    \n
    \n

    baz

    \n", + "example": 200, + "end_line": 3097 + }, + { + "markdown": "> > > foo\nbar\n", + "start_line": 3103, + "section": "Block quotes", + "html": "
    \n
    \n
    \n

    foo\nbar

    \n
    \n
    \n
    \n", + "example": 201, + "end_line": 3115 + }, + { + "markdown": ">>> foo\n> bar\n>>baz\n", + "start_line": 3117, + "section": "Block quotes", + "html": "
    \n
    \n
    \n

    foo\nbar\nbaz

    \n
    \n
    \n
    \n", + "example": 202, + "end_line": 3131 + }, + { + "markdown": "> code\n\n> not code\n", + "start_line": 3138, + "section": "Block quotes", + "html": "
    \n
    code\n
    \n
    \n
    \n

    not code

    \n
    \n", + "example": 203, + "end_line": 3150 + }, + { + "markdown": "A paragraph\nwith two lines.\n\n indented code\n\n> A block quote.\n", + "start_line": 3182, + "section": "List items", + "html": "

    A paragraph\nwith two lines.

    \n
    indented code\n
    \n
    \n

    A block quote.

    \n
    \n", + "example": 204, + "end_line": 3197 + }, + { + "markdown": "1. A paragraph\n with two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3203, + "section": "List items", + "html": "
      \n
    1. \n

      A paragraph\nwith two lines.

      \n
      indented code\n
      \n
      \n

      A block quote.

      \n
      \n
    2. \n
    \n", + "example": 205, + "end_line": 3222 + }, + { + "markdown": "- one\n\n two\n", + "start_line": 3235, + "section": "List items", + "html": "
      \n
    • one
    • \n
    \n

    two

    \n", + "example": 206, + "end_line": 3244 + }, + { + "markdown": "- one\n\n two\n", + "start_line": 3246, + "section": "List items", + "html": "
      \n
    • \n

      one

      \n

      two

      \n
    • \n
    \n", + "example": 207, + "end_line": 3257 + }, + { + "markdown": " - one\n\n two\n", + "start_line": 3259, + "section": "List items", + "html": "
      \n
    • one
    • \n
    \n
     two\n
    \n", + "example": 208, + "end_line": 3269 + }, + { + "markdown": " - one\n\n two\n", + "start_line": 3271, + "section": "List items", + "html": "
      \n
    • \n

      one

      \n

      two

      \n
    • \n
    \n", + "example": 209, + "end_line": 3282 + }, + { + "markdown": " > > 1. one\n>>\n>> two\n", + "start_line": 3292, + "section": "List items", + "html": "
    \n
    \n
      \n
    1. \n

      one

      \n

      two

      \n
    2. \n
    \n
    \n
    \n", + "example": 210, + "end_line": 3307 + }, + { + "markdown": ">>- one\n>>\n > > two\n", + "start_line": 3318, + "section": "List items", + "html": "
    \n
    \n
      \n
    • one
    • \n
    \n

    two

    \n
    \n
    \n", + "example": 211, + "end_line": 3331 + }, + { + "markdown": "-one\n\n2.two\n", + "start_line": 3336, + "section": "List items", + "html": "

    -one

    \n

    2.two

    \n", + "example": 212, + "end_line": 3343 + }, + { + "markdown": "- foo\n\n bar\n\n- foo\n\n\n bar\n\n- ```\n foo\n\n\n bar\n ```\n\n- baz\n\n + ```\n foo\n\n\n bar\n ```\n", + "start_line": 3349, + "section": "List items", + "html": "
      \n
    • \n

      foo

      \n

      bar

      \n
    • \n
    • \n

      foo

      \n
    • \n
    \n

    bar

    \n
      \n
    • \n
      foo\n\n\nbar\n
      \n
    • \n
    • \n

      baz

      \n
        \n
      • \n
        foo\n\n\nbar\n
        \n
      • \n
      \n
    • \n
    \n", + "example": 213, + "end_line": 3406 + }, + { + "markdown": "1. foo\n\n ```\n bar\n ```\n\n baz\n\n > bam\n", + "start_line": 3410, + "section": "List items", + "html": "
      \n
    1. \n

      foo

      \n
      bar\n
      \n

      baz

      \n
      \n

      bam

      \n
      \n
    2. \n
    \n", + "example": 214, + "end_line": 3432 + }, + { + "markdown": "- Foo\n\n bar\n\n baz\n", + "start_line": 3439, + "section": "List items", + "html": "
      \n
    • \n

      Foo

      \n
      bar\n\nbaz\n
      \n
    • \n
    \n", + "example": 215, + "end_line": 3455 + }, + { + "markdown": "- Foo\n\n bar\n\n\n baz\n", + "start_line": 3457, + "section": "List items", + "html": "
      \n
    • \n

      Foo

      \n
      bar\n
      \n
    • \n
    \n
      baz\n
    \n", + "example": 216, + "end_line": 3474 + }, + { + "markdown": "123456789. ok\n", + "start_line": 3478, + "section": "List items", + "html": "
      \n
    1. ok
    2. \n
    \n", + "example": 217, + "end_line": 3484 + }, + { + "markdown": "1234567890. not ok\n", + "start_line": 3486, + "section": "List items", + "html": "

    1234567890. not ok

    \n", + "example": 218, + "end_line": 3490 + }, + { + "markdown": "0. ok\n", + "start_line": 3494, + "section": "List items", + "html": "
      \n
    1. ok
    2. \n
    \n", + "example": 219, + "end_line": 3500 + }, + { + "markdown": "003. ok\n", + "start_line": 3502, + "section": "List items", + "html": "
      \n
    1. ok
    2. \n
    \n", + "example": 220, + "end_line": 3508 + }, + { + "markdown": "-1. not ok\n", + "start_line": 3512, + "section": "List items", + "html": "

    -1. not ok

    \n", + "example": 221, + "end_line": 3516 + }, + { + "markdown": "- foo\n\n bar\n", + "start_line": 3535, + "section": "List items", + "html": "
      \n
    • \n

      foo

      \n
      bar\n
      \n
    • \n
    \n", + "example": 222, + "end_line": 3547 + }, + { + "markdown": " 10. foo\n\n bar\n", + "start_line": 3551, + "section": "List items", + "html": "
      \n
    1. \n

      foo

      \n
      bar\n
      \n
    2. \n
    \n", + "example": 223, + "end_line": 3563 + }, + { + "markdown": " indented code\n\nparagraph\n\n more code\n", + "start_line": 3569, + "section": "List items", + "html": "
    indented code\n
    \n

    paragraph

    \n
    more code\n
    \n", + "example": 224, + "end_line": 3581 + }, + { + "markdown": "1. indented code\n\n paragraph\n\n more code\n", + "start_line": 3583, + "section": "List items", + "html": "
      \n
    1. \n
      indented code\n
      \n

      paragraph

      \n
      more code\n
      \n
    2. \n
    \n", + "example": 225, + "end_line": 3599 + }, + { + "markdown": "1. indented code\n\n paragraph\n\n more code\n", + "start_line": 3604, + "section": "List items", + "html": "
      \n
    1. \n
       indented code\n
      \n

      paragraph

      \n
      more code\n
      \n
    2. \n
    \n", + "example": 226, + "end_line": 3620 + }, + { + "markdown": " foo\n\nbar\n", + "start_line": 3630, + "section": "List items", + "html": "

    foo

    \n

    bar

    \n", + "example": 227, + "end_line": 3637 + }, + { + "markdown": "- foo\n\n bar\n", + "start_line": 3639, + "section": "List items", + "html": "
      \n
    • foo
    • \n
    \n

    bar

    \n", + "example": 228, + "end_line": 3648 + }, + { + "markdown": "- foo\n\n bar\n", + "start_line": 3655, + "section": "List items", + "html": "
      \n
    • \n

      foo

      \n

      bar

      \n
    • \n
    \n", + "example": 229, + "end_line": 3666 + }, + { + "markdown": "-\n foo\n-\n ```\n bar\n ```\n-\n baz\n", + "start_line": 3682, + "section": "List items", + "html": "
      \n
    • foo
    • \n
    • \n
      bar\n
      \n
    • \n
    • \n
      baz\n
      \n
    • \n
    \n", + "example": 230, + "end_line": 3703 + }, + { + "markdown": "-\n\n foo\n", + "start_line": 3709, + "section": "List items", + "html": "
      \n
    • \n
    \n

    foo

    \n", + "example": 231, + "end_line": 3718 + }, + { + "markdown": "- foo\n-\n- bar\n", + "start_line": 3722, + "section": "List items", + "html": "
      \n
    • foo
    • \n
    • \n
    • bar
    • \n
    \n", + "example": 232, + "end_line": 3732 + }, + { + "markdown": "- foo\n- \n- bar\n", + "start_line": 3736, + "section": "List items", + "html": "
      \n
    • foo
    • \n
    • \n
    • bar
    • \n
    \n", + "example": 233, + "end_line": 3746 + }, + { + "markdown": "1. foo\n2.\n3. bar\n", + "start_line": 3750, + "section": "List items", + "html": "
      \n
    1. foo
    2. \n
    3. \n
    4. bar
    5. \n
    \n", + "example": 234, + "end_line": 3760 + }, + { + "markdown": "*\n", + "start_line": 3764, + "section": "List items", + "html": "
      \n
    • \n
    \n", + "example": 235, + "end_line": 3770 + }, + { + "markdown": " 1. A paragraph\n with two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3781, + "section": "List items", + "html": "
      \n
    1. \n

      A paragraph\nwith two lines.

      \n
      indented code\n
      \n
      \n

      A block quote.

      \n
      \n
    2. \n
    \n", + "example": 236, + "end_line": 3800 + }, + { + "markdown": " 1. A paragraph\n with two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3804, + "section": "List items", + "html": "
      \n
    1. \n

      A paragraph\nwith two lines.

      \n
      indented code\n
      \n
      \n

      A block quote.

      \n
      \n
    2. \n
    \n", + "example": 237, + "end_line": 3823 + }, + { + "markdown": " 1. A paragraph\n with two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3827, + "section": "List items", + "html": "
      \n
    1. \n

      A paragraph\nwith two lines.

      \n
      indented code\n
      \n
      \n

      A block quote.

      \n
      \n
    2. \n
    \n", + "example": 238, + "end_line": 3846 + }, + { + "markdown": " 1. A paragraph\n with two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3850, + "section": "List items", + "html": "
    1.  A paragraph\n    with two lines.\n\n        indented code\n\n    > A block quote.\n
    \n", + "example": 239, + "end_line": 3865 + }, + { + "markdown": " 1. A paragraph\nwith two lines.\n\n indented code\n\n > A block quote.\n", + "start_line": 3879, + "section": "List items", + "html": "
      \n
    1. \n

      A paragraph\nwith two lines.

      \n
      indented code\n
      \n
      \n

      A block quote.

      \n
      \n
    2. \n
    \n", + "example": 240, + "end_line": 3898 + }, + { + "markdown": " 1. A paragraph\n with two lines.\n", + "start_line": 3902, + "section": "List items", + "html": "
      \n
    1. A paragraph\nwith two lines.
    2. \n
    \n", + "example": 241, + "end_line": 3910 + }, + { + "markdown": "> 1. > Blockquote\ncontinued here.\n", + "start_line": 3914, + "section": "List items", + "html": "
    \n
      \n
    1. \n
      \n

      Blockquote\ncontinued here.

      \n
      \n
    2. \n
    \n
    \n", + "example": 242, + "end_line": 3928 + }, + { + "markdown": "> 1. > Blockquote\n> continued here.\n", + "start_line": 3930, + "section": "List items", + "html": "
    \n
      \n
    1. \n
      \n

      Blockquote\ncontinued here.

      \n
      \n
    2. \n
    \n
    \n", + "example": 243, + "end_line": 3944 + }, + { + "markdown": "- foo\n - bar\n - baz\n", + "start_line": 3956, + "section": "List items", + "html": "
      \n
    • foo\n
        \n
      • bar\n
          \n
        • baz
        • \n
        \n
      • \n
      \n
    • \n
    \n", + "example": 244, + "end_line": 3972 + }, + { + "markdown": "- foo\n - bar\n - baz\n", + "start_line": 3976, + "section": "List items", + "html": "
      \n
    • foo
    • \n
    • bar
    • \n
    • baz
    • \n
    \n", + "example": 245, + "end_line": 3986 + }, + { + "markdown": "10) foo\n - bar\n", + "start_line": 3990, + "section": "List items", + "html": "
      \n
    1. foo\n
        \n
      • bar
      • \n
      \n
    2. \n
    \n", + "example": 246, + "end_line": 4001 + }, + { + "markdown": "10) foo\n - bar\n", + "start_line": 4005, + "section": "List items", + "html": "
      \n
    1. foo
    2. \n
    \n
      \n
    • bar
    • \n
    \n", + "example": 247, + "end_line": 4015 + }, + { + "markdown": "- - foo\n", + "start_line": 4019, + "section": "List items", + "html": "
      \n
    • \n
        \n
      • foo
      • \n
      \n
    • \n
    \n", + "example": 248, + "end_line": 4029 + }, + { + "markdown": "1. - 2. foo\n", + "start_line": 4031, + "section": "List items", + "html": "
      \n
    1. \n
        \n
      • \n
          \n
        1. foo
        2. \n
        \n
      • \n
      \n
    2. \n
    \n", + "example": 249, + "end_line": 4045 + }, + { + "markdown": "- # Foo\n- Bar\n ---\n baz\n", + "start_line": 4049, + "section": "List items", + "html": "
      \n
    • \n

      Foo

      \n
    • \n
    • \n

      Bar

      \nbaz
    • \n
    \n", + "example": 250, + "end_line": 4063 + }, + { + "markdown": "- foo\n- bar\n+ baz\n", + "start_line": 4285, + "section": "Lists", + "html": "
      \n
    • foo
    • \n
    • bar
    • \n
    \n
      \n
    • baz
    • \n
    \n", + "example": 251, + "end_line": 4297 + }, + { + "markdown": "1. foo\n2. bar\n3) baz\n", + "start_line": 4299, + "section": "Lists", + "html": "
      \n
    1. foo
    2. \n
    3. bar
    4. \n
    \n
      \n
    1. baz
    2. \n
    \n", + "example": 252, + "end_line": 4311 + }, + { + "markdown": "Foo\n- bar\n- baz\n", + "start_line": 4317, + "section": "Lists", + "html": "

    Foo

    \n
      \n
    • bar
    • \n
    • baz
    • \n
    \n", + "example": 253, + "end_line": 4327 + }, + { + "markdown": "The number of windows in my house is\n14. The number of doors is 6.\n", + "start_line": 4332, + "section": "Lists", + "html": "

    The number of windows in my house is

    \n
      \n
    1. The number of doors is 6.
    2. \n
    \n", + "example": 254, + "end_line": 4340 + }, + { + "markdown": "- foo\n\n- bar\n\n\n- baz\n", + "start_line": 4397, + "section": "Lists", + "html": "
      \n
    • \n

      foo

      \n
    • \n
    • \n

      bar

      \n
    • \n
    \n
      \n
    • baz
    • \n
    \n", + "example": 255, + "end_line": 4416 + }, + { + "markdown": "- foo\n\n\n bar\n- baz\n", + "start_line": 4422, + "section": "Lists", + "html": "
      \n
    • foo
    • \n
    \n

    bar

    \n
      \n
    • baz
    • \n
    \n", + "example": 256, + "end_line": 4436 + }, + { + "markdown": "- foo\n - bar\n - baz\n\n\n bim\n", + "start_line": 4440, + "section": "Lists", + "html": "
      \n
    • foo\n
        \n
      • bar\n
          \n
        • baz
        • \n
        \n
      • \n
      \n
    • \n
    \n
      bim\n
    \n", + "example": 257, + "end_line": 4461 + }, + { + "markdown": "- foo\n- bar\n\n\n- baz\n- bim\n", + "start_line": 4468, + "section": "Lists", + "html": "
      \n
    • foo
    • \n
    • bar
    • \n
    \n
      \n
    • baz
    • \n
    • bim
    • \n
    \n", + "example": 258, + "end_line": 4484 + }, + { + "markdown": "- foo\n\n notcode\n\n- foo\n\n\n code\n", + "start_line": 4486, + "section": "Lists", + "html": "
      \n
    • \n

      foo

      \n

      notcode

      \n
    • \n
    • \n

      foo

      \n
    • \n
    \n
    code\n
    \n", + "example": 259, + "end_line": 4507 + }, + { + "markdown": "- a\n - b\n - c\n - d\n - e\n - f\n - g\n - h\n- i\n", + "start_line": 4514, + "section": "Lists", + "html": "
      \n
    • a
    • \n
    • b
    • \n
    • c
    • \n
    • d
    • \n
    • e
    • \n
    • f
    • \n
    • g
    • \n
    • h
    • \n
    • i
    • \n
    \n", + "example": 260, + "end_line": 4536 + }, + { + "markdown": "1. a\n\n 2. b\n\n 3. c\n", + "start_line": 4538, + "section": "Lists", + "html": "
      \n
    1. \n

      a

      \n
    2. \n
    3. \n

      b

      \n
    4. \n
    5. \n

      c

      \n
    6. \n
    \n", + "example": 261, + "end_line": 4556 + }, + { + "markdown": "- a\n- b\n\n- c\n", + "start_line": 4561, + "section": "Lists", + "html": "
      \n
    • \n

      a

      \n
    • \n
    • \n

      b

      \n
    • \n
    • \n

      c

      \n
    • \n
    \n", + "example": 262, + "end_line": 4578 + }, + { + "markdown": "* a\n*\n\n* c\n", + "start_line": 4582, + "section": "Lists", + "html": "
      \n
    • \n

      a

      \n
    • \n
    • \n
    • \n

      c

      \n
    • \n
    \n", + "example": 263, + "end_line": 4597 + }, + { + "markdown": "- a\n- b\n\n c\n- d\n", + "start_line": 4603, + "section": "Lists", + "html": "
      \n
    • \n

      a

      \n
    • \n
    • \n

      b

      \n

      c

      \n
    • \n
    • \n

      d

      \n
    • \n
    \n", + "example": 264, + "end_line": 4622 + }, + { + "markdown": "- a\n- b\n\n [ref]: /url\n- d\n", + "start_line": 4624, + "section": "Lists", + "html": "
      \n
    • \n

      a

      \n
    • \n
    • \n

      b

      \n
    • \n
    • \n

      d

      \n
    • \n
    \n", + "example": 265, + "end_line": 4642 + }, + { + "markdown": "- a\n- ```\n b\n\n\n ```\n- c\n", + "start_line": 4646, + "section": "Lists", + "html": "
      \n
    • a
    • \n
    • \n
      b\n\n\n
      \n
    • \n
    • c
    • \n
    \n", + "example": 266, + "end_line": 4665 + }, + { + "markdown": "- a\n - b\n\n c\n- d\n", + "start_line": 4671, + "section": "Lists", + "html": "
      \n
    • a\n
        \n
      • \n

        b

        \n

        c

        \n
      • \n
      \n
    • \n
    • d
    • \n
    \n", + "example": 267, + "end_line": 4689 + }, + { + "markdown": "* a\n > b\n >\n* c\n", + "start_line": 4694, + "section": "Lists", + "html": "
      \n
    • a\n
      \n

      b

      \n
      \n
    • \n
    • c
    • \n
    \n", + "example": 268, + "end_line": 4708 + }, + { + "markdown": "- a\n > b\n ```\n c\n ```\n- d\n", + "start_line": 4713, + "section": "Lists", + "html": "
      \n
    • a\n
      \n

      b

      \n
      \n
      c\n
      \n
    • \n
    • d
    • \n
    \n", + "example": 269, + "end_line": 4731 + }, + { + "markdown": "- a\n", + "start_line": 4735, + "section": "Lists", + "html": "
      \n
    • a
    • \n
    \n", + "example": 270, + "end_line": 4741 + }, + { + "markdown": "- a\n - b\n", + "start_line": 4743, + "section": "Lists", + "html": "
      \n
    • a\n
        \n
      • b
      • \n
      \n
    • \n
    \n", + "example": 271, + "end_line": 4754 + }, + { + "markdown": "1. ```\n foo\n ```\n\n bar\n", + "start_line": 4759, + "section": "Lists", + "html": "
      \n
    1. \n
      foo\n
      \n

      bar

      \n
    2. \n
    \n", + "example": 272, + "end_line": 4773 + }, + { + "markdown": "* foo\n * bar\n\n baz\n", + "start_line": 4777, + "section": "Lists", + "html": "
      \n
    • \n

      foo

      \n
        \n
      • bar
      • \n
      \n

      baz

      \n
    • \n
    \n", + "example": 273, + "end_line": 4792 + }, + { + "markdown": "- a\n - b\n - c\n\n- d\n - e\n - f\n", + "start_line": 4794, + "section": "Lists", + "html": "
      \n
    • \n

      a

      \n
        \n
      • b
      • \n
      • c
      • \n
      \n
    • \n
    • \n

      d

      \n
        \n
      • e
      • \n
      • f
      • \n
      \n
    • \n
    \n", + "example": 274, + "end_line": 4819 + }, + { + "markdown": "`hi`lo`\n", + "start_line": 4827, + "section": "Inlines", + "html": "

    hilo`

    \n", + "example": 275, + "end_line": 4831 + }, + { + "markdown": "\\!\\\"\\#\\$\\%\\&\\'\\(\\)\\*\\+\\,\\-\\.\\/\\:\\;\\<\\=\\>\\?\\@\\[\\\\\\]\\^\\_\\`\\{\\|\\}\\~\n", + "start_line": 4840, + "section": "Backslash escapes", + "html": "

    !"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~

    \n", + "example": 276, + "end_line": 4844 + }, + { + "markdown": "\\\t\\A\\a\\ \\3\\φ\\«\n", + "start_line": 4849, + "section": "Backslash escapes", + "html": "

    \\\t\\A\\a\\ \\3\\φ\\«

    \n", + "example": 277, + "end_line": 4853 + }, + { + "markdown": "\\*not emphasized*\n\\
    not a tag\n\\[not a link](/foo)\n\\`not code`\n1\\. not a list\n\\* not a list\n\\# not a heading\n\\[foo]: /url \"not a reference\"\n", + "start_line": 4858, + "section": "Backslash escapes", + "html": "

    *not emphasized*\n<br/> not a tag\n[not a link](/foo)\n`not code`\n1. not a list\n* not a list\n# not a heading\n[foo]: /url "not a reference"

    \n", + "example": 278, + "end_line": 4876 + }, + { + "markdown": "\\\\*emphasis*\n", + "start_line": 4880, + "section": "Backslash escapes", + "html": "

    \\emphasis

    \n", + "example": 279, + "end_line": 4884 + }, + { + "markdown": "foo\\\nbar\n", + "start_line": 4888, + "section": "Backslash escapes", + "html": "

    foo
    \nbar

    \n", + "example": 280, + "end_line": 4894 + }, + { + "markdown": "`` \\[\\` ``\n", + "start_line": 4899, + "section": "Backslash escapes", + "html": "

    \\[\\`

    \n", + "example": 281, + "end_line": 4903 + }, + { + "markdown": " \\[\\]\n", + "start_line": 4905, + "section": "Backslash escapes", + "html": "
    \\[\\]\n
    \n", + "example": 282, + "end_line": 4910 + }, + { + "markdown": "~~~\n\\[\\]\n~~~\n", + "start_line": 4912, + "section": "Backslash escapes", + "html": "
    \\[\\]\n
    \n", + "example": 283, + "end_line": 4919 + }, + { + "markdown": "\n", + "start_line": 4921, + "section": "Backslash escapes", + "html": "

    http://example.com?find=\\*

    \n", + "example": 284, + "end_line": 4925 + }, + { + "markdown": "\n", + "start_line": 4927, + "section": "Backslash escapes", + "html": "\n", + "example": 285, + "end_line": 4931 + }, + { + "markdown": "[foo](/bar\\* \"ti\\*tle\")\n", + "start_line": 4936, + "section": "Backslash escapes", + "html": "

    foo

    \n", + "example": 286, + "end_line": 4940 + }, + { + "markdown": "[foo]\n\n[foo]: /bar\\* \"ti\\*tle\"\n", + "start_line": 4942, + "section": "Backslash escapes", + "html": "

    foo

    \n", + "example": 287, + "end_line": 4948 + }, + { + "markdown": "``` foo\\+bar\nfoo\n```\n", + "start_line": 4950, + "section": "Backslash escapes", + "html": "
    foo\n
    \n", + "example": 288, + "end_line": 4957 + }, + { + "markdown": "  & © Æ Ď\n¾ ℋ ⅆ\n∲ ≧̸\n", + "start_line": 4976, + "section": "Entity and numeric character references", + "html": "

      & © Æ Ď\n¾ ℋ ⅆ\n∲ ≧̸

    \n", + "example": 289, + "end_line": 4984 + }, + { + "markdown": "# Ӓ Ϡ � �\n", + "start_line": 4994, + "section": "Entity and numeric character references", + "html": "

    # Ӓ Ϡ � �

    \n", + "example": 290, + "end_line": 4998 + }, + { + "markdown": "" ആ ಫ\n", + "start_line": 5006, + "section": "Entity and numeric character references", + "html": "

    " ആ ಫ

    \n", + "example": 291, + "end_line": 5010 + }, + { + "markdown": "  &x; &#; &#x;\n&ThisIsWayTooLongToBeAnEntityIsntIt; &hi?;\n", + "start_line": 5014, + "section": "Entity and numeric character references", + "html": "

    &nbsp &x; &#; &#x;\n&ThisIsWayTooLongToBeAnEntityIsntIt; &hi?;

    \n", + "example": 292, + "end_line": 5020 + }, + { + "markdown": "©\n", + "start_line": 5026, + "section": "Entity and numeric character references", + "html": "

    &copy

    \n", + "example": 293, + "end_line": 5030 + }, + { + "markdown": "&MadeUpEntity;\n", + "start_line": 5035, + "section": "Entity and numeric character references", + "html": "

    &MadeUpEntity;

    \n", + "example": 294, + "end_line": 5039 + }, + { + "markdown": "\n", + "start_line": 5045, + "section": "Entity and numeric character references", + "html": "\n", + "example": 295, + "end_line": 5049 + }, + { + "markdown": "[foo](/föö \"föö\")\n", + "start_line": 5051, + "section": "Entity and numeric character references", + "html": "

    foo

    \n", + "example": 296, + "end_line": 5055 + }, + { + "markdown": "[foo]\n\n[foo]: /föö \"föö\"\n", + "start_line": 5057, + "section": "Entity and numeric character references", + "html": "

    foo

    \n", + "example": 297, + "end_line": 5063 + }, + { + "markdown": "``` föö\nfoo\n```\n", + "start_line": 5065, + "section": "Entity and numeric character references", + "html": "
    foo\n
    \n", + "example": 298, + "end_line": 5072 + }, + { + "markdown": "`föö`\n", + "start_line": 5077, + "section": "Entity and numeric character references", + "html": "

    f&ouml;&ouml;

    \n", + "example": 299, + "end_line": 5081 + }, + { + "markdown": " föfö\n", + "start_line": 5083, + "section": "Entity and numeric character references", + "html": "
    f&ouml;f&ouml;\n
    \n", + "example": 300, + "end_line": 5088 + }, + { + "markdown": "\n", + "start_line": 5090, + "section": "Entity and numeric character references", + "html": "\n", + "example": 301, + "end_line": 5094 + }, + { + "markdown": "`foo`\n", + "start_line": 5110, + "section": "Code spans", + "html": "

    foo

    \n", + "example": 302, + "end_line": 5114 + }, + { + "markdown": "`` foo ` bar ``\n", + "start_line": 5119, + "section": "Code spans", + "html": "

    foo ` bar

    \n", + "example": 303, + "end_line": 5123 + }, + { + "markdown": "` `` `\n", + "start_line": 5128, + "section": "Code spans", + "html": "

    ``

    \n", + "example": 304, + "end_line": 5132 + }, + { + "markdown": "``\nfoo\n``\n", + "start_line": 5136, + "section": "Code spans", + "html": "

    foo

    \n", + "example": 305, + "end_line": 5142 + }, + { + "markdown": "`foo bar\n baz`\n", + "start_line": 5147, + "section": "Code spans", + "html": "

    foo bar baz

    \n", + "example": 306, + "end_line": 5152 + }, + { + "markdown": "`foo `` bar`\n", + "start_line": 5167, + "section": "Code spans", + "html": "

    foo `` bar

    \n", + "example": 307, + "end_line": 5171 + }, + { + "markdown": "`foo\\`bar`\n", + "start_line": 5176, + "section": "Code spans", + "html": "

    foo\\bar`

    \n", + "example": 308, + "end_line": 5180 + }, + { + "markdown": "*foo`*`\n", + "start_line": 5191, + "section": "Code spans", + "html": "

    *foo*

    \n", + "example": 309, + "end_line": 5195 + }, + { + "markdown": "[not a `link](/foo`)\n", + "start_line": 5199, + "section": "Code spans", + "html": "

    [not a link](/foo)

    \n", + "example": 310, + "end_line": 5203 + }, + { + "markdown": "`
    `\n", + "start_line": 5208, + "section": "Code spans", + "html": "

    <a href="">`

    \n", + "example": 311, + "end_line": 5212 + }, + { + "markdown": "
    `\n", + "start_line": 5216, + "section": "Code spans", + "html": "

    `

    \n", + "example": 312, + "end_line": 5220 + }, + { + "markdown": "``\n", + "start_line": 5224, + "section": "Code spans", + "html": "

    <http://foo.bar.baz>`

    \n", + "example": 313, + "end_line": 5228 + }, + { + "markdown": "`\n", + "start_line": 5232, + "section": "Code spans", + "html": "

    http://foo.bar.`baz`

    \n", + "example": 314, + "end_line": 5236 + }, + { + "markdown": "```foo``\n", + "start_line": 5241, + "section": "Code spans", + "html": "

    ```foo``

    \n", + "example": 315, + "end_line": 5245 + }, + { + "markdown": "`foo\n", + "start_line": 5247, + "section": "Code spans", + "html": "

    `foo

    \n", + "example": 316, + "end_line": 5251 + }, + { + "markdown": "*foo bar*\n", + "start_line": 5456, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 317, + "end_line": 5460 + }, + { + "markdown": "a * foo bar*\n", + "start_line": 5465, + "section": "Emphasis and strong emphasis", + "html": "

    a * foo bar*

    \n", + "example": 318, + "end_line": 5469 + }, + { + "markdown": "a*\"foo\"*\n", + "start_line": 5475, + "section": "Emphasis and strong emphasis", + "html": "

    a*"foo"*

    \n", + "example": 319, + "end_line": 5479 + }, + { + "markdown": "* a *\n", + "start_line": 5483, + "section": "Emphasis and strong emphasis", + "html": "

    * a *

    \n", + "example": 320, + "end_line": 5487 + }, + { + "markdown": "foo*bar*\n", + "start_line": 5491, + "section": "Emphasis and strong emphasis", + "html": "

    foobar

    \n", + "example": 321, + "end_line": 5495 + }, + { + "markdown": "5*6*78\n", + "start_line": 5497, + "section": "Emphasis and strong emphasis", + "html": "

    5678

    \n", + "example": 322, + "end_line": 5501 + }, + { + "markdown": "_foo bar_\n", + "start_line": 5505, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 323, + "end_line": 5509 + }, + { + "markdown": "_ foo bar_\n", + "start_line": 5514, + "section": "Emphasis and strong emphasis", + "html": "

    _ foo bar_

    \n", + "example": 324, + "end_line": 5518 + }, + { + "markdown": "a_\"foo\"_\n", + "start_line": 5523, + "section": "Emphasis and strong emphasis", + "html": "

    a_"foo"_

    \n", + "example": 325, + "end_line": 5527 + }, + { + "markdown": "foo_bar_\n", + "start_line": 5531, + "section": "Emphasis and strong emphasis", + "html": "

    foo_bar_

    \n", + "example": 326, + "end_line": 5535 + }, + { + "markdown": "5_6_78\n", + "start_line": 5537, + "section": "Emphasis and strong emphasis", + "html": "

    5_6_78

    \n", + "example": 327, + "end_line": 5541 + }, + { + "markdown": "пристаням_стремятся_\n", + "start_line": 5543, + "section": "Emphasis and strong emphasis", + "html": "

    пристаням_стремятся_

    \n", + "example": 328, + "end_line": 5547 + }, + { + "markdown": "aa_\"bb\"_cc\n", + "start_line": 5552, + "section": "Emphasis and strong emphasis", + "html": "

    aa_"bb"_cc

    \n", + "example": 329, + "end_line": 5556 + }, + { + "markdown": "foo-_(bar)_\n", + "start_line": 5562, + "section": "Emphasis and strong emphasis", + "html": "

    foo-(bar)

    \n", + "example": 330, + "end_line": 5566 + }, + { + "markdown": "_foo*\n", + "start_line": 5573, + "section": "Emphasis and strong emphasis", + "html": "

    _foo*

    \n", + "example": 331, + "end_line": 5577 + }, + { + "markdown": "*foo bar *\n", + "start_line": 5582, + "section": "Emphasis and strong emphasis", + "html": "

    *foo bar *

    \n", + "example": 332, + "end_line": 5586 + }, + { + "markdown": "*foo bar\n*\n", + "start_line": 5590, + "section": "Emphasis and strong emphasis", + "html": "

    *foo bar

    \n
      \n
    • \n
    \n", + "example": 333, + "end_line": 5598 + }, + { + "markdown": "*(*foo)\n", + "start_line": 5604, + "section": "Emphasis and strong emphasis", + "html": "

    *(*foo)

    \n", + "example": 334, + "end_line": 5608 + }, + { + "markdown": "*(*foo*)*\n", + "start_line": 5613, + "section": "Emphasis and strong emphasis", + "html": "

    (foo)

    \n", + "example": 335, + "end_line": 5617 + }, + { + "markdown": "*foo*bar\n", + "start_line": 5621, + "section": "Emphasis and strong emphasis", + "html": "

    foobar

    \n", + "example": 336, + "end_line": 5625 + }, + { + "markdown": "_foo bar _\n", + "start_line": 5633, + "section": "Emphasis and strong emphasis", + "html": "

    _foo bar _

    \n", + "example": 337, + "end_line": 5637 + }, + { + "markdown": "_(_foo)\n", + "start_line": 5642, + "section": "Emphasis and strong emphasis", + "html": "

    _(_foo)

    \n", + "example": 338, + "end_line": 5646 + }, + { + "markdown": "_(_foo_)_\n", + "start_line": 5650, + "section": "Emphasis and strong emphasis", + "html": "

    (foo)

    \n", + "example": 339, + "end_line": 5654 + }, + { + "markdown": "_foo_bar\n", + "start_line": 5658, + "section": "Emphasis and strong emphasis", + "html": "

    _foo_bar

    \n", + "example": 340, + "end_line": 5662 + }, + { + "markdown": "_пристаням_стремятся\n", + "start_line": 5664, + "section": "Emphasis and strong emphasis", + "html": "

    _пристаням_стремятся

    \n", + "example": 341, + "end_line": 5668 + }, + { + "markdown": "_foo_bar_baz_\n", + "start_line": 5670, + "section": "Emphasis and strong emphasis", + "html": "

    foo_bar_baz

    \n", + "example": 342, + "end_line": 5674 + }, + { + "markdown": "_(bar)_.\n", + "start_line": 5680, + "section": "Emphasis and strong emphasis", + "html": "

    (bar).

    \n", + "example": 343, + "end_line": 5684 + }, + { + "markdown": "**foo bar**\n", + "start_line": 5688, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 344, + "end_line": 5692 + }, + { + "markdown": "** foo bar**\n", + "start_line": 5697, + "section": "Emphasis and strong emphasis", + "html": "

    ** foo bar**

    \n", + "example": 345, + "end_line": 5701 + }, + { + "markdown": "a**\"foo\"**\n", + "start_line": 5707, + "section": "Emphasis and strong emphasis", + "html": "

    a**"foo"**

    \n", + "example": 346, + "end_line": 5711 + }, + { + "markdown": "foo**bar**\n", + "start_line": 5715, + "section": "Emphasis and strong emphasis", + "html": "

    foobar

    \n", + "example": 347, + "end_line": 5719 + }, + { + "markdown": "__foo bar__\n", + "start_line": 5723, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 348, + "end_line": 5727 + }, + { + "markdown": "__ foo bar__\n", + "start_line": 5732, + "section": "Emphasis and strong emphasis", + "html": "

    __ foo bar__

    \n", + "example": 349, + "end_line": 5736 + }, + { + "markdown": "__\nfoo bar__\n", + "start_line": 5739, + "section": "Emphasis and strong emphasis", + "html": "

    __\nfoo bar__

    \n", + "example": 350, + "end_line": 5745 + }, + { + "markdown": "a__\"foo\"__\n", + "start_line": 5750, + "section": "Emphasis and strong emphasis", + "html": "

    a__"foo"__

    \n", + "example": 351, + "end_line": 5754 + }, + { + "markdown": "foo__bar__\n", + "start_line": 5758, + "section": "Emphasis and strong emphasis", + "html": "

    foo__bar__

    \n", + "example": 352, + "end_line": 5762 + }, + { + "markdown": "5__6__78\n", + "start_line": 5764, + "section": "Emphasis and strong emphasis", + "html": "

    5__6__78

    \n", + "example": 353, + "end_line": 5768 + }, + { + "markdown": "пристаням__стремятся__\n", + "start_line": 5770, + "section": "Emphasis and strong emphasis", + "html": "

    пристаням__стремятся__

    \n", + "example": 354, + "end_line": 5774 + }, + { + "markdown": "__foo, __bar__, baz__\n", + "start_line": 5776, + "section": "Emphasis and strong emphasis", + "html": "

    foo, bar, baz

    \n", + "example": 355, + "end_line": 5780 + }, + { + "markdown": "foo-__(bar)__\n", + "start_line": 5786, + "section": "Emphasis and strong emphasis", + "html": "

    foo-(bar)

    \n", + "example": 356, + "end_line": 5790 + }, + { + "markdown": "**foo bar **\n", + "start_line": 5798, + "section": "Emphasis and strong emphasis", + "html": "

    **foo bar **

    \n", + "example": 357, + "end_line": 5802 + }, + { + "markdown": "**(**foo)\n", + "start_line": 5810, + "section": "Emphasis and strong emphasis", + "html": "

    **(**foo)

    \n", + "example": 358, + "end_line": 5814 + }, + { + "markdown": "*(**foo**)*\n", + "start_line": 5819, + "section": "Emphasis and strong emphasis", + "html": "

    (foo)

    \n", + "example": 359, + "end_line": 5823 + }, + { + "markdown": "**Gomphocarpus (*Gomphocarpus physocarpus*, syn.\n*Asclepias physocarpa*)**\n", + "start_line": 5825, + "section": "Emphasis and strong emphasis", + "html": "

    Gomphocarpus (Gomphocarpus physocarpus, syn.\nAsclepias physocarpa)

    \n", + "example": 360, + "end_line": 5831 + }, + { + "markdown": "**foo \"*bar*\" foo**\n", + "start_line": 5833, + "section": "Emphasis and strong emphasis", + "html": "

    foo "bar" foo

    \n", + "example": 361, + "end_line": 5837 + }, + { + "markdown": "**foo**bar\n", + "start_line": 5841, + "section": "Emphasis and strong emphasis", + "html": "

    foobar

    \n", + "example": 362, + "end_line": 5845 + }, + { + "markdown": "__foo bar __\n", + "start_line": 5852, + "section": "Emphasis and strong emphasis", + "html": "

    __foo bar __

    \n", + "example": 363, + "end_line": 5856 + }, + { + "markdown": "__(__foo)\n", + "start_line": 5861, + "section": "Emphasis and strong emphasis", + "html": "

    __(__foo)

    \n", + "example": 364, + "end_line": 5865 + }, + { + "markdown": "_(__foo__)_\n", + "start_line": 5870, + "section": "Emphasis and strong emphasis", + "html": "

    (foo)

    \n", + "example": 365, + "end_line": 5874 + }, + { + "markdown": "__foo__bar\n", + "start_line": 5878, + "section": "Emphasis and strong emphasis", + "html": "

    __foo__bar

    \n", + "example": 366, + "end_line": 5882 + }, + { + "markdown": "__пристаням__стремятся\n", + "start_line": 5884, + "section": "Emphasis and strong emphasis", + "html": "

    __пристаням__стремятся

    \n", + "example": 367, + "end_line": 5888 + }, + { + "markdown": "__foo__bar__baz__\n", + "start_line": 5890, + "section": "Emphasis and strong emphasis", + "html": "

    foo__bar__baz

    \n", + "example": 368, + "end_line": 5894 + }, + { + "markdown": "__(bar)__.\n", + "start_line": 5900, + "section": "Emphasis and strong emphasis", + "html": "

    (bar).

    \n", + "example": 369, + "end_line": 5904 + }, + { + "markdown": "*foo [bar](/url)*\n", + "start_line": 5911, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 370, + "end_line": 5915 + }, + { + "markdown": "*foo\nbar*\n", + "start_line": 5917, + "section": "Emphasis and strong emphasis", + "html": "

    foo\nbar

    \n", + "example": 371, + "end_line": 5923 + }, + { + "markdown": "_foo __bar__ baz_\n", + "start_line": 5928, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 372, + "end_line": 5932 + }, + { + "markdown": "_foo _bar_ baz_\n", + "start_line": 5934, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 373, + "end_line": 5938 + }, + { + "markdown": "__foo_ bar_\n", + "start_line": 5940, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 374, + "end_line": 5944 + }, + { + "markdown": "*foo *bar**\n", + "start_line": 5946, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 375, + "end_line": 5950 + }, + { + "markdown": "*foo **bar** baz*\n", + "start_line": 5952, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 376, + "end_line": 5956 + }, + { + "markdown": "*foo**bar**baz*\n", + "start_line": 5960, + "section": "Emphasis and strong emphasis", + "html": "

    foobarbaz

    \n", + "example": 377, + "end_line": 5964 + }, + { + "markdown": "***foo** bar*\n", + "start_line": 5969, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 378, + "end_line": 5973 + }, + { + "markdown": "*foo **bar***\n", + "start_line": 5975, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 379, + "end_line": 5979 + }, + { + "markdown": "*foo**bar***\n", + "start_line": 5985, + "section": "Emphasis and strong emphasis", + "html": "

    foobar**

    \n", + "example": 380, + "end_line": 5989 + }, + { + "markdown": "*foo **bar *baz* bim** bop*\n", + "start_line": 5994, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz bim bop

    \n", + "example": 381, + "end_line": 5998 + }, + { + "markdown": "*foo [*bar*](/url)*\n", + "start_line": 6000, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 382, + "end_line": 6004 + }, + { + "markdown": "** is not an empty emphasis\n", + "start_line": 6008, + "section": "Emphasis and strong emphasis", + "html": "

    ** is not an empty emphasis

    \n", + "example": 383, + "end_line": 6012 + }, + { + "markdown": "**** is not an empty strong emphasis\n", + "start_line": 6014, + "section": "Emphasis and strong emphasis", + "html": "

    **** is not an empty strong emphasis

    \n", + "example": 384, + "end_line": 6018 + }, + { + "markdown": "**foo [bar](/url)**\n", + "start_line": 6026, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 385, + "end_line": 6030 + }, + { + "markdown": "**foo\nbar**\n", + "start_line": 6032, + "section": "Emphasis and strong emphasis", + "html": "

    foo\nbar

    \n", + "example": 386, + "end_line": 6038 + }, + { + "markdown": "__foo _bar_ baz__\n", + "start_line": 6043, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 387, + "end_line": 6047 + }, + { + "markdown": "__foo __bar__ baz__\n", + "start_line": 6049, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 388, + "end_line": 6053 + }, + { + "markdown": "____foo__ bar__\n", + "start_line": 6055, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 389, + "end_line": 6059 + }, + { + "markdown": "**foo **bar****\n", + "start_line": 6061, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 390, + "end_line": 6065 + }, + { + "markdown": "**foo *bar* baz**\n", + "start_line": 6067, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz

    \n", + "example": 391, + "end_line": 6071 + }, + { + "markdown": "**foo*bar*baz**\n", + "start_line": 6075, + "section": "Emphasis and strong emphasis", + "html": "

    foobarbaz**

    \n", + "example": 392, + "end_line": 6079 + }, + { + "markdown": "***foo* bar**\n", + "start_line": 6084, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 393, + "end_line": 6088 + }, + { + "markdown": "**foo *bar***\n", + "start_line": 6090, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 394, + "end_line": 6094 + }, + { + "markdown": "**foo *bar **baz**\nbim* bop**\n", + "start_line": 6098, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar baz\nbim bop

    \n", + "example": 395, + "end_line": 6104 + }, + { + "markdown": "**foo [*bar*](/url)**\n", + "start_line": 6106, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar

    \n", + "example": 396, + "end_line": 6110 + }, + { + "markdown": "__ is not an empty emphasis\n", + "start_line": 6114, + "section": "Emphasis and strong emphasis", + "html": "

    __ is not an empty emphasis

    \n", + "example": 397, + "end_line": 6118 + }, + { + "markdown": "____ is not an empty strong emphasis\n", + "start_line": 6120, + "section": "Emphasis and strong emphasis", + "html": "

    ____ is not an empty strong emphasis

    \n", + "example": 398, + "end_line": 6124 + }, + { + "markdown": "foo ***\n", + "start_line": 6129, + "section": "Emphasis and strong emphasis", + "html": "

    foo ***

    \n", + "example": 399, + "end_line": 6133 + }, + { + "markdown": "foo *\\**\n", + "start_line": 6135, + "section": "Emphasis and strong emphasis", + "html": "

    foo *

    \n", + "example": 400, + "end_line": 6139 + }, + { + "markdown": "foo *_*\n", + "start_line": 6141, + "section": "Emphasis and strong emphasis", + "html": "

    foo _

    \n", + "example": 401, + "end_line": 6145 + }, + { + "markdown": "foo *****\n", + "start_line": 6147, + "section": "Emphasis and strong emphasis", + "html": "

    foo *****

    \n", + "example": 402, + "end_line": 6151 + }, + { + "markdown": "foo **\\***\n", + "start_line": 6153, + "section": "Emphasis and strong emphasis", + "html": "

    foo *

    \n", + "example": 403, + "end_line": 6157 + }, + { + "markdown": "foo **_**\n", + "start_line": 6159, + "section": "Emphasis and strong emphasis", + "html": "

    foo _

    \n", + "example": 404, + "end_line": 6163 + }, + { + "markdown": "**foo*\n", + "start_line": 6169, + "section": "Emphasis and strong emphasis", + "html": "

    *foo

    \n", + "example": 405, + "end_line": 6173 + }, + { + "markdown": "*foo**\n", + "start_line": 6175, + "section": "Emphasis and strong emphasis", + "html": "

    foo*

    \n", + "example": 406, + "end_line": 6179 + }, + { + "markdown": "***foo**\n", + "start_line": 6181, + "section": "Emphasis and strong emphasis", + "html": "

    *foo

    \n", + "example": 407, + "end_line": 6185 + }, + { + "markdown": "****foo*\n", + "start_line": 6187, + "section": "Emphasis and strong emphasis", + "html": "

    ***foo

    \n", + "example": 408, + "end_line": 6191 + }, + { + "markdown": "**foo***\n", + "start_line": 6193, + "section": "Emphasis and strong emphasis", + "html": "

    foo*

    \n", + "example": 409, + "end_line": 6197 + }, + { + "markdown": "*foo****\n", + "start_line": 6199, + "section": "Emphasis and strong emphasis", + "html": "

    foo***

    \n", + "example": 410, + "end_line": 6203 + }, + { + "markdown": "foo ___\n", + "start_line": 6208, + "section": "Emphasis and strong emphasis", + "html": "

    foo ___

    \n", + "example": 411, + "end_line": 6212 + }, + { + "markdown": "foo _\\__\n", + "start_line": 6214, + "section": "Emphasis and strong emphasis", + "html": "

    foo _

    \n", + "example": 412, + "end_line": 6218 + }, + { + "markdown": "foo _*_\n", + "start_line": 6220, + "section": "Emphasis and strong emphasis", + "html": "

    foo *

    \n", + "example": 413, + "end_line": 6224 + }, + { + "markdown": "foo _____\n", + "start_line": 6226, + "section": "Emphasis and strong emphasis", + "html": "

    foo _____

    \n", + "example": 414, + "end_line": 6230 + }, + { + "markdown": "foo __\\___\n", + "start_line": 6232, + "section": "Emphasis and strong emphasis", + "html": "

    foo _

    \n", + "example": 415, + "end_line": 6236 + }, + { + "markdown": "foo __*__\n", + "start_line": 6238, + "section": "Emphasis and strong emphasis", + "html": "

    foo *

    \n", + "example": 416, + "end_line": 6242 + }, + { + "markdown": "__foo_\n", + "start_line": 6244, + "section": "Emphasis and strong emphasis", + "html": "

    _foo

    \n", + "example": 417, + "end_line": 6248 + }, + { + "markdown": "_foo__\n", + "start_line": 6254, + "section": "Emphasis and strong emphasis", + "html": "

    foo_

    \n", + "example": 418, + "end_line": 6258 + }, + { + "markdown": "___foo__\n", + "start_line": 6260, + "section": "Emphasis and strong emphasis", + "html": "

    _foo

    \n", + "example": 419, + "end_line": 6264 + }, + { + "markdown": "____foo_\n", + "start_line": 6266, + "section": "Emphasis and strong emphasis", + "html": "

    ___foo

    \n", + "example": 420, + "end_line": 6270 + }, + { + "markdown": "__foo___\n", + "start_line": 6272, + "section": "Emphasis and strong emphasis", + "html": "

    foo_

    \n", + "example": 421, + "end_line": 6276 + }, + { + "markdown": "_foo____\n", + "start_line": 6278, + "section": "Emphasis and strong emphasis", + "html": "

    foo___

    \n", + "example": 422, + "end_line": 6282 + }, + { + "markdown": "**foo**\n", + "start_line": 6287, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 423, + "end_line": 6291 + }, + { + "markdown": "*_foo_*\n", + "start_line": 6293, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 424, + "end_line": 6297 + }, + { + "markdown": "__foo__\n", + "start_line": 6299, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 425, + "end_line": 6303 + }, + { + "markdown": "_*foo*_\n", + "start_line": 6305, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 426, + "end_line": 6309 + }, + { + "markdown": "****foo****\n", + "start_line": 6314, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 427, + "end_line": 6318 + }, + { + "markdown": "____foo____\n", + "start_line": 6320, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 428, + "end_line": 6324 + }, + { + "markdown": "******foo******\n", + "start_line": 6330, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 429, + "end_line": 6334 + }, + { + "markdown": "***foo***\n", + "start_line": 6338, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 430, + "end_line": 6342 + }, + { + "markdown": "_____foo_____\n", + "start_line": 6344, + "section": "Emphasis and strong emphasis", + "html": "

    foo

    \n", + "example": 431, + "end_line": 6348 + }, + { + "markdown": "*foo _bar* baz_\n", + "start_line": 6352, + "section": "Emphasis and strong emphasis", + "html": "

    foo _bar baz_

    \n", + "example": 432, + "end_line": 6356 + }, + { + "markdown": "**foo*bar**\n", + "start_line": 6358, + "section": "Emphasis and strong emphasis", + "html": "

    foobar*

    \n", + "example": 433, + "end_line": 6362 + }, + { + "markdown": "*foo __bar *baz bim__ bam*\n", + "start_line": 6364, + "section": "Emphasis and strong emphasis", + "html": "

    foo bar *baz bim bam

    \n", + "example": 434, + "end_line": 6368 + }, + { + "markdown": "**foo **bar baz**\n", + "start_line": 6372, + "section": "Emphasis and strong emphasis", + "html": "

    **foo bar baz

    \n", + "example": 435, + "end_line": 6376 + }, + { + "markdown": "*foo *bar baz*\n", + "start_line": 6378, + "section": "Emphasis and strong emphasis", + "html": "

    *foo bar baz

    \n", + "example": 436, + "end_line": 6382 + }, + { + "markdown": "*[bar*](/url)\n", + "start_line": 6386, + "section": "Emphasis and strong emphasis", + "html": "

    *bar*

    \n", + "example": 437, + "end_line": 6390 + }, + { + "markdown": "_foo [bar_](/url)\n", + "start_line": 6392, + "section": "Emphasis and strong emphasis", + "html": "

    _foo bar_

    \n", + "example": 438, + "end_line": 6396 + }, + { + "markdown": "*\n", + "start_line": 6398, + "section": "Emphasis and strong emphasis", + "html": "

    *

    \n", + "example": 439, + "end_line": 6402 + }, + { + "markdown": "**\n", + "start_line": 6404, + "section": "Emphasis and strong emphasis", + "html": "

    **

    \n", + "example": 440, + "end_line": 6408 + }, + { + "markdown": "__\n", + "start_line": 6410, + "section": "Emphasis and strong emphasis", + "html": "

    __

    \n", + "example": 441, + "end_line": 6414 + }, + { + "markdown": "*a `*`*\n", + "start_line": 6416, + "section": "Emphasis and strong emphasis", + "html": "

    a *

    \n", + "example": 442, + "end_line": 6420 + }, + { + "markdown": "_a `_`_\n", + "start_line": 6422, + "section": "Emphasis and strong emphasis", + "html": "

    a _

    \n", + "example": 443, + "end_line": 6426 + }, + { + "markdown": "**a\n", + "start_line": 6428, + "section": "Emphasis and strong emphasis", + "html": "

    **ahttp://foo.bar/?q=**

    \n", + "example": 444, + "end_line": 6432 + }, + { + "markdown": "__a\n", + "start_line": 6434, + "section": "Emphasis and strong emphasis", + "html": "

    __ahttp://foo.bar/?q=__

    \n", + "example": 445, + "end_line": 6438 + }, + { + "markdown": "[link](/uri \"title\")\n", + "start_line": 6513, + "section": "Links", + "html": "

    link

    \n", + "example": 446, + "end_line": 6517 + }, + { + "markdown": "[link](/uri)\n", + "start_line": 6521, + "section": "Links", + "html": "

    link

    \n", + "example": 447, + "end_line": 6525 + }, + { + "markdown": "[link]()\n", + "start_line": 6529, + "section": "Links", + "html": "

    link

    \n", + "example": 448, + "end_line": 6533 + }, + { + "markdown": "[link](<>)\n", + "start_line": 6535, + "section": "Links", + "html": "

    link

    \n", + "example": 449, + "end_line": 6539 + }, + { + "markdown": "[link](/my uri)\n", + "start_line": 6544, + "section": "Links", + "html": "

    [link](/my uri)

    \n", + "example": 450, + "end_line": 6548 + }, + { + "markdown": "[link](
    )\n", + "start_line": 6550, + "section": "Links", + "html": "

    link

    \n", + "example": 451, + "end_line": 6554 + }, + { + "markdown": "[link](foo\nbar)\n", + "start_line": 6558, + "section": "Links", + "html": "

    [link](foo\nbar)

    \n", + "example": 452, + "end_line": 6564 + }, + { + "markdown": "[link]()\n", + "start_line": 6566, + "section": "Links", + "html": "

    [link]()

    \n", + "example": 453, + "end_line": 6572 + }, + { + "markdown": "[link]((foo)and(bar))\n", + "start_line": 6576, + "section": "Links", + "html": "

    link

    \n", + "example": 454, + "end_line": 6580 + }, + { + "markdown": "[link](foo(and(bar)))\n", + "start_line": 6585, + "section": "Links", + "html": "

    [link](foo(and(bar)))

    \n", + "example": 455, + "end_line": 6589 + }, + { + "markdown": "[link](foo(and\\(bar\\)))\n", + "start_line": 6591, + "section": "Links", + "html": "

    link

    \n", + "example": 456, + "end_line": 6595 + }, + { + "markdown": "[link]()\n", + "start_line": 6597, + "section": "Links", + "html": "

    link

    \n", + "example": 457, + "end_line": 6601 + }, + { + "markdown": "[link](foo\\)\\:)\n", + "start_line": 6606, + "section": "Links", + "html": "

    link

    \n", + "example": 458, + "end_line": 6610 + }, + { + "markdown": "[link](#fragment)\n\n[link](http://example.com#fragment)\n\n[link](http://example.com?foo=3#frag)\n", + "start_line": 6614, + "section": "Links", + "html": "

    link

    \n

    link

    \n

    link

    \n", + "example": 459, + "end_line": 6624 + }, + { + "markdown": "[link](foo\\bar)\n", + "start_line": 6629, + "section": "Links", + "html": "

    link

    \n", + "example": 460, + "end_line": 6633 + }, + { + "markdown": "[link](foo%20bä)\n", + "start_line": 6644, + "section": "Links", + "html": "

    link

    \n", + "example": 461, + "end_line": 6648 + }, + { + "markdown": "[link](\"title\")\n", + "start_line": 6654, + "section": "Links", + "html": "

    link

    \n", + "example": 462, + "end_line": 6658 + }, + { + "markdown": "[link](/url \"title\")\n[link](/url 'title')\n[link](/url (title))\n", + "start_line": 6662, + "section": "Links", + "html": "

    link\nlink\nlink

    \n", + "example": 463, + "end_line": 6670 + }, + { + "markdown": "[link](/url \"title \\\""\")\n", + "start_line": 6675, + "section": "Links", + "html": "

    link

    \n", + "example": 464, + "end_line": 6679 + }, + { + "markdown": "[link](/url \"title \"and\" title\")\n", + "start_line": 6683, + "section": "Links", + "html": "

    [link](/url "title "and" title")

    \n", + "example": 465, + "end_line": 6687 + }, + { + "markdown": "[link](/url 'title \"and\" title')\n", + "start_line": 6691, + "section": "Links", + "html": "

    link

    \n", + "example": 466, + "end_line": 6695 + }, + { + "markdown": "[link]( /uri\n \"title\" )\n", + "start_line": 6714, + "section": "Links", + "html": "

    link

    \n", + "example": 467, + "end_line": 6719 + }, + { + "markdown": "[link] (/uri)\n", + "start_line": 6724, + "section": "Links", + "html": "

    [link] (/uri)

    \n", + "example": 468, + "end_line": 6728 + }, + { + "markdown": "[link [foo [bar]]](/uri)\n", + "start_line": 6733, + "section": "Links", + "html": "

    link [foo [bar]]

    \n", + "example": 469, + "end_line": 6737 + }, + { + "markdown": "[link] bar](/uri)\n", + "start_line": 6739, + "section": "Links", + "html": "

    [link] bar](/uri)

    \n", + "example": 470, + "end_line": 6743 + }, + { + "markdown": "[link [bar](/uri)\n", + "start_line": 6745, + "section": "Links", + "html": "

    [link bar

    \n", + "example": 471, + "end_line": 6749 + }, + { + "markdown": "[link \\[bar](/uri)\n", + "start_line": 6751, + "section": "Links", + "html": "

    link [bar

    \n", + "example": 472, + "end_line": 6755 + }, + { + "markdown": "[link *foo **bar** `#`*](/uri)\n", + "start_line": 6759, + "section": "Links", + "html": "

    link foo bar #

    \n", + "example": 473, + "end_line": 6763 + }, + { + "markdown": "[![moon](moon.jpg)](/uri)\n", + "start_line": 6765, + "section": "Links", + "html": "

    \"moon\"

    \n", + "example": 474, + "end_line": 6769 + }, + { + "markdown": "[foo [bar](/uri)](/uri)\n", + "start_line": 6773, + "section": "Links", + "html": "

    [foo bar](/uri)

    \n", + "example": 475, + "end_line": 6777 + }, + { + "markdown": "[foo *[bar [baz](/uri)](/uri)*](/uri)\n", + "start_line": 6779, + "section": "Links", + "html": "

    [foo [bar baz](/uri)](/uri)

    \n", + "example": 476, + "end_line": 6783 + }, + { + "markdown": "![[[foo](uri1)](uri2)](uri3)\n", + "start_line": 6785, + "section": "Links", + "html": "

    \"[foo](uri2)\"

    \n", + "example": 477, + "end_line": 6789 + }, + { + "markdown": "*[foo*](/uri)\n", + "start_line": 6794, + "section": "Links", + "html": "

    *foo*

    \n", + "example": 478, + "end_line": 6798 + }, + { + "markdown": "[foo *bar](baz*)\n", + "start_line": 6800, + "section": "Links", + "html": "

    foo *bar

    \n", + "example": 479, + "end_line": 6804 + }, + { + "markdown": "*foo [bar* baz]\n", + "start_line": 6809, + "section": "Links", + "html": "

    foo [bar baz]

    \n", + "example": 480, + "end_line": 6813 + }, + { + "markdown": "[foo \n", + "start_line": 6818, + "section": "Links", + "html": "

    [foo

    \n", + "example": 481, + "end_line": 6822 + }, + { + "markdown": "[foo`](/uri)`\n", + "start_line": 6824, + "section": "Links", + "html": "

    [foo](/uri)

    \n", + "example": 482, + "end_line": 6828 + }, + { + "markdown": "[foo\n", + "start_line": 6830, + "section": "Links", + "html": "

    [foohttp://example.com/?search=](uri)

    \n", + "example": 483, + "end_line": 6834 + }, + { + "markdown": "[foo][bar]\n\n[bar]: /url \"title\"\n", + "start_line": 6864, + "section": "Links", + "html": "

    foo

    \n", + "example": 484, + "end_line": 6870 + }, + { + "markdown": "[link [foo [bar]]][ref]\n\n[ref]: /uri\n", + "start_line": 6878, + "section": "Links", + "html": "

    link [foo [bar]]

    \n", + "example": 485, + "end_line": 6884 + }, + { + "markdown": "[link \\[bar][ref]\n\n[ref]: /uri\n", + "start_line": 6886, + "section": "Links", + "html": "

    link [bar

    \n", + "example": 486, + "end_line": 6892 + }, + { + "markdown": "[link *foo **bar** `#`*][ref]\n\n[ref]: /uri\n", + "start_line": 6896, + "section": "Links", + "html": "

    link foo bar #

    \n", + "example": 487, + "end_line": 6902 + }, + { + "markdown": "[![moon](moon.jpg)][ref]\n\n[ref]: /uri\n", + "start_line": 6904, + "section": "Links", + "html": "

    \"moon\"

    \n", + "example": 488, + "end_line": 6910 + }, + { + "markdown": "[foo [bar](/uri)][ref]\n\n[ref]: /uri\n", + "start_line": 6914, + "section": "Links", + "html": "

    [foo bar]ref

    \n", + "example": 489, + "end_line": 6920 + }, + { + "markdown": "[foo *bar [baz][ref]*][ref]\n\n[ref]: /uri\n", + "start_line": 6922, + "section": "Links", + "html": "

    [foo bar baz]ref

    \n", + "example": 490, + "end_line": 6928 + }, + { + "markdown": "*[foo*][ref]\n\n[ref]: /uri\n", + "start_line": 6936, + "section": "Links", + "html": "

    *foo*

    \n", + "example": 491, + "end_line": 6942 + }, + { + "markdown": "[foo *bar][ref]\n\n[ref]: /uri\n", + "start_line": 6944, + "section": "Links", + "html": "

    foo *bar

    \n", + "example": 492, + "end_line": 6950 + }, + { + "markdown": "[foo \n\n[ref]: /uri\n", + "start_line": 6955, + "section": "Links", + "html": "

    [foo

    \n", + "example": 493, + "end_line": 6961 + }, + { + "markdown": "[foo`][ref]`\n\n[ref]: /uri\n", + "start_line": 6963, + "section": "Links", + "html": "

    [foo][ref]

    \n", + "example": 494, + "end_line": 6969 + }, + { + "markdown": "[foo\n\n[ref]: /uri\n", + "start_line": 6971, + "section": "Links", + "html": "

    [foohttp://example.com/?search=][ref]

    \n", + "example": 495, + "end_line": 6977 + }, + { + "markdown": "[foo][BaR]\n\n[bar]: /url \"title\"\n", + "start_line": 6981, + "section": "Links", + "html": "

    foo

    \n", + "example": 496, + "end_line": 6987 + }, + { + "markdown": "[Толпой][Толпой] is a Russian word.\n\n[ТОЛПОЙ]: /url\n", + "start_line": 6991, + "section": "Links", + "html": "

    Толпой is a Russian word.

    \n", + "example": 497, + "end_line": 6997 + }, + { + "markdown": "[Foo\n bar]: /url\n\n[Baz][Foo bar]\n", + "start_line": 7002, + "section": "Links", + "html": "

    Baz

    \n", + "example": 498, + "end_line": 7009 + }, + { + "markdown": "[foo] [bar]\n\n[bar]: /url \"title\"\n", + "start_line": 7014, + "section": "Links", + "html": "

    [foo] bar

    \n", + "example": 499, + "end_line": 7020 + }, + { + "markdown": "[foo]\n[bar]\n\n[bar]: /url \"title\"\n", + "start_line": 7022, + "section": "Links", + "html": "

    [foo]\nbar

    \n", + "example": 500, + "end_line": 7030 + }, + { + "markdown": "[foo]: /url1\n\n[foo]: /url2\n\n[bar][foo]\n", + "start_line": 7062, + "section": "Links", + "html": "

    bar

    \n", + "example": 501, + "end_line": 7070 + }, + { + "markdown": "[bar][foo\\!]\n\n[foo!]: /url\n", + "start_line": 7076, + "section": "Links", + "html": "

    [bar][foo!]

    \n", + "example": 502, + "end_line": 7082 + }, + { + "markdown": "[foo][ref[]\n\n[ref[]: /uri\n", + "start_line": 7087, + "section": "Links", + "html": "

    [foo][ref[]

    \n

    [ref[]: /uri

    \n", + "example": 503, + "end_line": 7094 + }, + { + "markdown": "[foo][ref[bar]]\n\n[ref[bar]]: /uri\n", + "start_line": 7096, + "section": "Links", + "html": "

    [foo][ref[bar]]

    \n

    [ref[bar]]: /uri

    \n", + "example": 504, + "end_line": 7103 + }, + { + "markdown": "[[[foo]]]\n\n[[[foo]]]: /url\n", + "start_line": 7105, + "section": "Links", + "html": "

    [[[foo]]]

    \n

    [[[foo]]]: /url

    \n", + "example": 505, + "end_line": 7112 + }, + { + "markdown": "[foo][ref\\[]\n\n[ref\\[]: /uri\n", + "start_line": 7114, + "section": "Links", + "html": "

    foo

    \n", + "example": 506, + "end_line": 7120 + }, + { + "markdown": "[bar\\\\]: /uri\n\n[bar\\\\]\n", + "start_line": 7124, + "section": "Links", + "html": "

    bar\\

    \n", + "example": 507, + "end_line": 7130 + }, + { + "markdown": "[]\n\n[]: /uri\n", + "start_line": 7134, + "section": "Links", + "html": "

    []

    \n

    []: /uri

    \n", + "example": 508, + "end_line": 7141 + }, + { + "markdown": "[\n ]\n\n[\n ]: /uri\n", + "start_line": 7143, + "section": "Links", + "html": "

    [\n]

    \n

    [\n]: /uri

    \n", + "example": 509, + "end_line": 7154 + }, + { + "markdown": "[foo][]\n\n[foo]: /url \"title\"\n", + "start_line": 7165, + "section": "Links", + "html": "

    foo

    \n", + "example": 510, + "end_line": 7171 + }, + { + "markdown": "[*foo* bar][]\n\n[*foo* bar]: /url \"title\"\n", + "start_line": 7173, + "section": "Links", + "html": "

    foo bar

    \n", + "example": 511, + "end_line": 7179 + }, + { + "markdown": "[Foo][]\n\n[foo]: /url \"title\"\n", + "start_line": 7183, + "section": "Links", + "html": "

    Foo

    \n", + "example": 512, + "end_line": 7189 + }, + { + "markdown": "[foo] \n[]\n\n[foo]: /url \"title\"\n", + "start_line": 7195, + "section": "Links", + "html": "

    foo\n[]

    \n", + "example": 513, + "end_line": 7203 + }, + { + "markdown": "[foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7214, + "section": "Links", + "html": "

    foo

    \n", + "example": 514, + "end_line": 7220 + }, + { + "markdown": "[*foo* bar]\n\n[*foo* bar]: /url \"title\"\n", + "start_line": 7222, + "section": "Links", + "html": "

    foo bar

    \n", + "example": 515, + "end_line": 7228 + }, + { + "markdown": "[[*foo* bar]]\n\n[*foo* bar]: /url \"title\"\n", + "start_line": 7230, + "section": "Links", + "html": "

    [foo bar]

    \n", + "example": 516, + "end_line": 7236 + }, + { + "markdown": "[[bar [foo]\n\n[foo]: /url\n", + "start_line": 7238, + "section": "Links", + "html": "

    [[bar foo

    \n", + "example": 517, + "end_line": 7244 + }, + { + "markdown": "[Foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7248, + "section": "Links", + "html": "

    Foo

    \n", + "example": 518, + "end_line": 7254 + }, + { + "markdown": "[foo] bar\n\n[foo]: /url\n", + "start_line": 7258, + "section": "Links", + "html": "

    foo bar

    \n", + "example": 519, + "end_line": 7264 + }, + { + "markdown": "\\[foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7269, + "section": "Links", + "html": "

    [foo]

    \n", + "example": 520, + "end_line": 7275 + }, + { + "markdown": "[foo*]: /url\n\n*[foo*]\n", + "start_line": 7280, + "section": "Links", + "html": "

    *foo*

    \n", + "example": 521, + "end_line": 7286 + }, + { + "markdown": "[foo][bar]\n\n[foo]: /url1\n[bar]: /url2\n", + "start_line": 7290, + "section": "Links", + "html": "

    foo

    \n", + "example": 522, + "end_line": 7297 + }, + { + "markdown": "[foo][bar][baz]\n\n[baz]: /url\n", + "start_line": 7302, + "section": "Links", + "html": "

    [foo]bar

    \n", + "example": 523, + "end_line": 7308 + }, + { + "markdown": "[foo][bar][baz]\n\n[baz]: /url1\n[bar]: /url2\n", + "start_line": 7313, + "section": "Links", + "html": "

    foobaz

    \n", + "example": 524, + "end_line": 7320 + }, + { + "markdown": "[foo][bar][baz]\n\n[baz]: /url1\n[foo]: /url2\n", + "start_line": 7325, + "section": "Links", + "html": "

    [foo]bar

    \n", + "example": 525, + "end_line": 7332 + }, + { + "markdown": "![foo](/url \"title\")\n", + "start_line": 7347, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 526, + "end_line": 7351 + }, + { + "markdown": "![foo *bar*]\n\n[foo *bar*]: train.jpg \"train & tracks\"\n", + "start_line": 7353, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 527, + "end_line": 7359 + }, + { + "markdown": "![foo ![bar](/url)](/url2)\n", + "start_line": 7361, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 528, + "end_line": 7365 + }, + { + "markdown": "![foo [bar](/url)](/url2)\n", + "start_line": 7367, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 529, + "end_line": 7371 + }, + { + "markdown": "![foo *bar*][]\n\n[foo *bar*]: train.jpg \"train & tracks\"\n", + "start_line": 7380, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 530, + "end_line": 7386 + }, + { + "markdown": "![foo *bar*][foobar]\n\n[FOOBAR]: train.jpg \"train & tracks\"\n", + "start_line": 7388, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 531, + "end_line": 7394 + }, + { + "markdown": "![foo](train.jpg)\n", + "start_line": 7396, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 532, + "end_line": 7400 + }, + { + "markdown": "My ![foo bar](/path/to/train.jpg \"title\" )\n", + "start_line": 7402, + "section": "Images", + "html": "

    My \"foo

    \n", + "example": 533, + "end_line": 7406 + }, + { + "markdown": "![foo]()\n", + "start_line": 7408, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 534, + "end_line": 7412 + }, + { + "markdown": "![](/url)\n", + "start_line": 7414, + "section": "Images", + "html": "

    \"\"

    \n", + "example": 535, + "end_line": 7418 + }, + { + "markdown": "![foo][bar]\n\n[bar]: /url\n", + "start_line": 7422, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 536, + "end_line": 7428 + }, + { + "markdown": "![foo][bar]\n\n[BAR]: /url\n", + "start_line": 7430, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 537, + "end_line": 7436 + }, + { + "markdown": "![foo][]\n\n[foo]: /url \"title\"\n", + "start_line": 7440, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 538, + "end_line": 7446 + }, + { + "markdown": "![*foo* bar][]\n\n[*foo* bar]: /url \"title\"\n", + "start_line": 7448, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 539, + "end_line": 7454 + }, + { + "markdown": "![Foo][]\n\n[foo]: /url \"title\"\n", + "start_line": 7458, + "section": "Images", + "html": "

    \"Foo\"

    \n", + "example": 540, + "end_line": 7464 + }, + { + "markdown": "![foo] \n[]\n\n[foo]: /url \"title\"\n", + "start_line": 7469, + "section": "Images", + "html": "

    \"foo\"\n[]

    \n", + "example": 541, + "end_line": 7477 + }, + { + "markdown": "![foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7481, + "section": "Images", + "html": "

    \"foo\"

    \n", + "example": 542, + "end_line": 7487 + }, + { + "markdown": "![*foo* bar]\n\n[*foo* bar]: /url \"title\"\n", + "start_line": 7489, + "section": "Images", + "html": "

    \"foo

    \n", + "example": 543, + "end_line": 7495 + }, + { + "markdown": "![[foo]]\n\n[[foo]]: /url \"title\"\n", + "start_line": 7499, + "section": "Images", + "html": "

    ![[foo]]

    \n

    [[foo]]: /url "title"

    \n", + "example": 544, + "end_line": 7506 + }, + { + "markdown": "![Foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7510, + "section": "Images", + "html": "

    \"Foo\"

    \n", + "example": 545, + "end_line": 7516 + }, + { + "markdown": "\\!\\[foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7521, + "section": "Images", + "html": "

    ![foo]

    \n", + "example": 546, + "end_line": 7527 + }, + { + "markdown": "\\![foo]\n\n[foo]: /url \"title\"\n", + "start_line": 7532, + "section": "Images", + "html": "

    !foo

    \n", + "example": 547, + "end_line": 7538 + }, + { + "markdown": "\n", + "start_line": 7585, + "section": "Autolinks", + "html": "

    http://foo.bar.baz

    \n", + "example": 548, + "end_line": 7589 + }, + { + "markdown": "\n", + "start_line": 7591, + "section": "Autolinks", + "html": "

    http://foo.bar.baz/test?q=hello&id=22&boolean

    \n", + "example": 549, + "end_line": 7595 + }, + { + "markdown": "\n", + "start_line": 7597, + "section": "Autolinks", + "html": "

    irc://foo.bar:2233/baz

    \n", + "example": 550, + "end_line": 7601 + }, + { + "markdown": "\n", + "start_line": 7605, + "section": "Autolinks", + "html": "

    MAILTO:FOO@BAR.BAZ

    \n", + "example": 551, + "end_line": 7609 + }, + { + "markdown": "\n", + "start_line": 7613, + "section": "Autolinks", + "html": "

    <http://foo.bar/baz bim>

    \n", + "example": 552, + "end_line": 7617 + }, + { + "markdown": "\n", + "start_line": 7621, + "section": "Autolinks", + "html": "

    http://example.com/\\[\\

    \n", + "example": 553, + "end_line": 7625 + }, + { + "markdown": "\n", + "start_line": 7642, + "section": "Autolinks", + "html": "

    foo@bar.example.com

    \n", + "example": 554, + "end_line": 7646 + }, + { + "markdown": "\n", + "start_line": 7648, + "section": "Autolinks", + "html": "

    foo+special@Bar.baz-bar0.com

    \n", + "example": 555, + "end_line": 7652 + }, + { + "markdown": "\n", + "start_line": 7656, + "section": "Autolinks", + "html": "

    <foo+@bar.example.com>

    \n", + "example": 556, + "end_line": 7660 + }, + { + "markdown": "<>\n", + "start_line": 7664, + "section": "Autolinks", + "html": "

    <>

    \n", + "example": 557, + "end_line": 7668 + }, + { + "markdown": "\n", + "start_line": 7670, + "section": "Autolinks", + "html": "

    <heck://bing.bong>

    \n", + "example": 558, + "end_line": 7674 + }, + { + "markdown": "< http://foo.bar >\n", + "start_line": 7676, + "section": "Autolinks", + "html": "

    < http://foo.bar >

    \n", + "example": 559, + "end_line": 7680 + }, + { + "markdown": "\n", + "start_line": 7682, + "section": "Autolinks", + "html": "

    <foo.bar.baz>

    \n", + "example": 560, + "end_line": 7686 + }, + { + "markdown": "\n", + "start_line": 7688, + "section": "Autolinks", + "html": "

    <localhost:5001/foo>

    \n", + "example": 561, + "end_line": 7692 + }, + { + "markdown": "http://example.com\n", + "start_line": 7694, + "section": "Autolinks", + "html": "

    http://example.com

    \n", + "example": 562, + "end_line": 7698 + }, + { + "markdown": "foo@bar.example.com\n", + "start_line": 7700, + "section": "Autolinks", + "html": "

    foo@bar.example.com

    \n", + "example": 563, + "end_line": 7704 + }, + { + "markdown": "\n", + "start_line": 7781, + "section": "Raw HTML", + "html": "

    \n", + "example": 564, + "end_line": 7785 + }, + { + "markdown": "\n", + "start_line": 7789, + "section": "Raw HTML", + "html": "

    \n", + "example": 565, + "end_line": 7793 + }, + { + "markdown": "\n", + "start_line": 7797, + "section": "Raw HTML", + "html": "

    \n", + "example": 566, + "end_line": 7803 + }, + { + "markdown": "\n", + "start_line": 7807, + "section": "Raw HTML", + "html": "

    \n", + "example": 567, + "end_line": 7813 + }, + { + "markdown": "Foo \n", + "start_line": 7817, + "section": "Raw HTML", + "html": "

    Foo

    \n", + "example": 568, + "end_line": 7821 + }, + { + "markdown": "<33> <__>\n", + "start_line": 7825, + "section": "Raw HTML", + "html": "

    <33> <__>

    \n", + "example": 569, + "end_line": 7829 + }, + { + "markdown": "
    \n", + "start_line": 7833, + "section": "Raw HTML", + "html": "

    <a h*#ref="hi">

    \n", + "example": 570, + "end_line": 7837 + }, + { + "markdown": "
    \n", + "start_line": 7841, + "section": "Raw HTML", + "html": "

    <a href="hi'> <a href=hi'>

    \n", + "example": 571, + "end_line": 7845 + }, + { + "markdown": "< a><\nfoo>\n", + "start_line": 7849, + "section": "Raw HTML", + "html": "

    < a><\nfoo><bar/ >

    \n", + "example": 572, + "end_line": 7855 + }, + { + "markdown": "
    \n", + "start_line": 7859, + "section": "Raw HTML", + "html": "

    <a href='bar'title=title>

    \n", + "example": 573, + "end_line": 7863 + }, + { + "markdown": "
    \n", + "start_line": 7867, + "section": "Raw HTML", + "html": "

    \n", + "example": 574, + "end_line": 7871 + }, + { + "markdown": "\n", + "start_line": 7875, + "section": "Raw HTML", + "html": "

    </a href="foo">

    \n", + "example": 575, + "end_line": 7879 + }, + { + "markdown": "foo \n", + "start_line": 7883, + "section": "Raw HTML", + "html": "

    foo

    \n", + "example": 576, + "end_line": 7889 + }, + { + "markdown": "foo \n", + "start_line": 7891, + "section": "Raw HTML", + "html": "

    foo <!-- not a comment -- two hyphens -->

    \n", + "example": 577, + "end_line": 7895 + }, + { + "markdown": "foo foo -->\n\nfoo \n", + "start_line": 7899, + "section": "Raw HTML", + "html": "

    foo <!--> foo -->

    \n

    foo <!-- foo--->

    \n", + "example": 578, + "end_line": 7906 + }, + { + "markdown": "foo \n", + "start_line": 7910, + "section": "Raw HTML", + "html": "

    foo

    \n", + "example": 579, + "end_line": 7914 + }, + { + "markdown": "foo \n", + "start_line": 7918, + "section": "Raw HTML", + "html": "

    foo

    \n", + "example": 580, + "end_line": 7922 + }, + { + "markdown": "foo &<]]>\n", + "start_line": 7926, + "section": "Raw HTML", + "html": "

    foo &<]]>

    \n", + "example": 581, + "end_line": 7930 + }, + { + "markdown": "foo \n", + "start_line": 7935, + "section": "Raw HTML", + "html": "

    foo

    \n", + "example": 582, + "end_line": 7939 + }, + { + "markdown": "foo \n", + "start_line": 7943, + "section": "Raw HTML", + "html": "

    foo

    \n", + "example": 583, + "end_line": 7947 + }, + { + "markdown": "\n", + "start_line": 7949, + "section": "Raw HTML", + "html": "

    <a href=""">

    \n", + "example": 584, + "end_line": 7953 + }, + { + "markdown": "foo \nbaz\n", + "start_line": 7962, + "section": "Hard line breaks", + "html": "

    foo
    \nbaz

    \n", + "example": 585, + "end_line": 7968 + }, + { + "markdown": "foo\\\nbaz\n", + "start_line": 7973, + "section": "Hard line breaks", + "html": "

    foo
    \nbaz

    \n", + "example": 586, + "end_line": 7979 + }, + { + "markdown": "foo \nbaz\n", + "start_line": 7983, + "section": "Hard line breaks", + "html": "

    foo
    \nbaz

    \n", + "example": 587, + "end_line": 7989 + }, + { + "markdown": "foo \n bar\n", + "start_line": 7993, + "section": "Hard line breaks", + "html": "

    foo
    \nbar

    \n", + "example": 588, + "end_line": 7999 + }, + { + "markdown": "foo\\\n bar\n", + "start_line": 8001, + "section": "Hard line breaks", + "html": "

    foo
    \nbar

    \n", + "example": 589, + "end_line": 8007 + }, + { + "markdown": "*foo \nbar*\n", + "start_line": 8012, + "section": "Hard line breaks", + "html": "

    foo
    \nbar

    \n", + "example": 590, + "end_line": 8018 + }, + { + "markdown": "*foo\\\nbar*\n", + "start_line": 8020, + "section": "Hard line breaks", + "html": "

    foo
    \nbar

    \n", + "example": 591, + "end_line": 8026 + }, + { + "markdown": "`code \nspan`\n", + "start_line": 8030, + "section": "Hard line breaks", + "html": "

    code span

    \n", + "example": 592, + "end_line": 8035 + }, + { + "markdown": "`code\\\nspan`\n", + "start_line": 8037, + "section": "Hard line breaks", + "html": "

    code\\ span

    \n", + "example": 593, + "end_line": 8042 + }, + { + "markdown": "
    \n", + "start_line": 8046, + "section": "Hard line breaks", + "html": "

    \n", + "example": 594, + "end_line": 8052 + }, + { + "markdown": "\n", + "start_line": 8054, + "section": "Hard line breaks", + "html": "

    \n", + "example": 595, + "end_line": 8060 + }, + { + "markdown": "foo\\\n", + "start_line": 8066, + "section": "Hard line breaks", + "html": "

    foo\\

    \n", + "example": 596, + "end_line": 8070 + }, + { + "markdown": "foo \n", + "start_line": 8072, + "section": "Hard line breaks", + "html": "

    foo

    \n", + "example": 597, + "end_line": 8076 + }, + { + "markdown": "### foo\\\n", + "start_line": 8078, + "section": "Hard line breaks", + "html": "

    foo\\

    \n", + "example": 598, + "end_line": 8082 + }, + { + "markdown": "### foo \n", + "start_line": 8084, + "section": "Hard line breaks", + "html": "

    foo

    \n", + "example": 599, + "end_line": 8088 + }, + { + "markdown": "foo\nbaz\n", + "start_line": 8098, + "section": "Soft line breaks", + "html": "

    foo\nbaz

    \n", + "example": 600, + "end_line": 8104 + }, + { + "markdown": "foo \n baz\n", + "start_line": 8109, + "section": "Soft line breaks", + "html": "

    foo\nbaz

    \n", + "example": 601, + "end_line": 8115 + }, + { + "markdown": "hello $.;'there\n", + "start_line": 8128, + "section": "Textual content", + "html": "

    hello $.;'there

    \n", + "example": 602, + "end_line": 8132 + }, + { + "markdown": "Foo χρῆν\n", + "start_line": 8134, + "section": "Textual content", + "html": "

    Foo χρῆν

    \n", + "example": 603, + "end_line": 8138 + }, + { + "markdown": "Multiple spaces\n", + "start_line": 8142, + "section": "Textual content", + "html": "

    Multiple spaces

    \n", + "example": 604, + "end_line": 8146 + } +]