mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-17 21:01:26 +02:00
Merge commit '2e711a28c71e8667258e5ab824f9b9a71c261b0a'
This commit is contained in:
@@ -74,11 +74,9 @@ func GetTitleFunc(style string) func(s string) string {
|
||||
case "go":
|
||||
return strings.Title
|
||||
case "chicago":
|
||||
tc := transform.NewTitleConverter(transform.ChicagoStyle)
|
||||
return tc.Title
|
||||
return transform.NewTitleConverter(transform.ChicagoStyle)
|
||||
default:
|
||||
tc := transform.NewTitleConverter(transform.APStyle)
|
||||
return tc.Title
|
||||
return transform.NewTitleConverter(transform.APStyle)
|
||||
}
|
||||
}
|
||||
{{< / highlight >}}
|
||||
@@ -93,14 +91,10 @@ See [Highlight](/functions/highlight/).
|
||||
|
||||
Highlighting in code fences is enabled by default.{{< new-in "0.60.0" >}}
|
||||
|
||||
````
|
||||
```go-html-template{hl_lines=[3,"5-6"],linenos=true}
|
||||
```
|
||||
````
|
||||
|
||||
````
|
||||
```go {linenos=table,hl_lines=[8,"15-17"],linenostart=199}
|
||||
// ... code
|
||||
```
|
||||
````
|
||||
|
||||
|
||||
@@ -122,11 +116,9 @@ func GetTitleFunc(style string) func(s string) string {
|
||||
case "go":
|
||||
return strings.Title
|
||||
case "chicago":
|
||||
tc := transform.NewTitleConverter(transform.ChicagoStyle)
|
||||
return tc.Title
|
||||
return transform.NewTitleConverter(transform.ChicagoStyle)
|
||||
default:
|
||||
tc := transform.NewTitleConverter(transform.APStyle)
|
||||
return tc.Title
|
||||
return transform.NewTitleConverter(transform.APStyle)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
Reference in New Issue
Block a user