This is an automated email from the ASF dual-hosted git repository.
linkinstar pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git
The following commit(s) were added to refs/heads/dev by this push:
new d23ac6e9 fix: Markdown parsing without incrementing ordered list
numbers
d23ac6e9 is described below
commit d23ac6e9236167afe1901fb4448e7053a02c7392
Author: sy-records <[email protected]>
AuthorDate: Thu Nov 14 15:45:31 2024 +0800
fix: Markdown parsing without incrementing ordered list numbers
---
pkg/converter/markdown.go | 1 +
1 file changed, 1 insertion(+)
diff --git a/pkg/converter/markdown.go b/pkg/converter/markdown.go
index af17d9bd..082a198a 100644
--- a/pkg/converter/markdown.go
+++ b/pkg/converter/markdown.go
@@ -60,6 +60,7 @@ func Markdown2HTML(source string) string {
filter.RequireNoFollowOnFullyQualifiedLinks(false)
filter.AllowElements("kbd")
filter.AllowAttrs("title").Matching(regexp.MustCompile(`^[\p{L}\p{N}\s\-_',\[\]!\./\\\(\)]*$|^@embed?$`)).Globally()
+ filter.AllowAttrs("start").OnElements("ol")
html = filter.Sanitize(html)
return html
}