mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-28 22:19:59 +02:00
markup/goldmark: Update the CJK extension to allow specifying line break styles
This commit follows https://github.com/yuin/goldmark/pull/411
This commit is contained in:
@@ -140,7 +140,11 @@ func newMarkdown(pcfg converter.ProviderConfig) goldmark.Markdown {
|
||||
if cfg.Extensions.CJK.Enable {
|
||||
opts := []extension.CJKOption{}
|
||||
if cfg.Extensions.CJK.EastAsianLineBreaks {
|
||||
opts = append(opts, extension.WithEastAsianLineBreaks())
|
||||
if cfg.Extensions.CJK.EastAsianLineBreaksStyle == "css3draft" {
|
||||
opts = append(opts, extension.WithEastAsianLineBreaks(extension.EastAsianLineBreaksCSS3Draft))
|
||||
} else {
|
||||
opts = append(opts, extension.WithEastAsianLineBreaks())
|
||||
}
|
||||
}
|
||||
|
||||
if cfg.Extensions.CJK.EscapedSpace {
|
||||
|
Reference in New Issue
Block a user