diff options
-rw-r--r-- | layouts/partials/table-of-contents.html | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/layouts/partials/table-of-contents.html b/layouts/partials/table-of-contents.html index 2b6f532..e0d72f1 100644 --- a/layouts/partials/table-of-contents.html +++ b/layouts/partials/table-of-contents.html @@ -18,11 +18,13 @@ <ul class="toc-h{{ . }}"> {{end}} {{ $base := ($.Page.File.LogicalName) }} - {{ $anchorId := ($header | plainify | htmlEscape | urlize) }} + {{ $anchorId := ($header | plainify | htmlUnescape | anchorize) }} {{ $href := delimit (slice $base $anchorId) "#" | string }} - <a href="{{ relref $.Page $href }}"> - <li>{{ $header | plainify | htmlEscape }}</li> - </a> + <li> + <a href="{{ relref $.Page $href }}"> + {{ $header | plainify | htmlUnescape | emojify }} + </a> + </li> <!-- close list --> {{ range seq $next_heading }} </ul> @@ -31,4 +33,4 @@ {{end}} {{ end }} </div> -{{ end }}
\ No newline at end of file +{{ end }} |