aboutsummaryrefslogtreecommitdiff
path: root/mardown/ast_paragraph.go
diff options
context:
space:
mode:
authorAnhgelus Morhtuuzh <william@herges.fr>2025-10-02 13:21:37 +0200
committerAnhgelus Morhtuuzh <william@herges.fr>2025-10-02 13:21:37 +0200
commit72eed1cfa1f5067a7ca581c53bb40e9e0fb047cc (patch)
tree5a4e8b69c4e2705222baf1e1c8e0ffcfadfb3c98 /mardown/ast_paragraph.go
parentcdb0a541554aa4a16fc71b6425225e8c603c83b8 (diff)
fix(markdown): bad list parsing
Diffstat (limited to 'mardown/ast_paragraph.go')
-rw-r--r--mardown/ast_paragraph.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/mardown/ast_paragraph.go b/mardown/ast_paragraph.go
index 44b5dd9..23d526e 100644
--- a/mardown/ast_paragraph.go
+++ b/mardown/ast_paragraph.go
@@ -40,9 +40,10 @@ func paragraph(lxs *lexers, oneLine bool) (*astParagraph, error) {
n := 0
lxs.current-- // because we do not use it before the next
for lxs.Next() && n < maxBreak {
+ //println("p", strings.ReplaceAll(lxs.Current().Value, "\n", "/n"))
switch lxs.Current().Type {
case lexerBreak:
- n = len(lxs.Current().Value)
+ n += len(lxs.Current().Value)
case lexerQuote, lexerList:
if n > 0 {
lxs.Before() // because we did not use it