mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-19 21:21:39 +02:00
markup/goldmark: Make the autoID type config a string
To potentially make room for one more. See #6707
This commit is contained in:
@@ -19,6 +19,8 @@ import (
|
||||
"unicode"
|
||||
"unicode/utf8"
|
||||
|
||||
"github.com/gohugoio/hugo/markup/goldmark/goldmark_config"
|
||||
|
||||
"github.com/gohugoio/hugo/common/text"
|
||||
|
||||
"github.com/yuin/goldmark/ast"
|
||||
@@ -85,10 +87,10 @@ type idFactory struct {
|
||||
vals map[string]struct{}
|
||||
}
|
||||
|
||||
func newIDFactory(asciiOnly bool) *idFactory {
|
||||
func newIDFactory(idType string) *idFactory {
|
||||
return &idFactory{
|
||||
vals: make(map[string]struct{}),
|
||||
asciiOnly: asciiOnly,
|
||||
asciiOnly: idType == goldmark_config.AutoHeadingIDTypeGitHubAscii,
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user