Skip to content

Commit

Permalink
Fix: 修复目录相关配置错误
Browse files Browse the repository at this point in the history
  • Loading branch information
Lruihao committed Oct 2, 2024
1 parent 2a67ddd commit c9298c9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions layouts/section/projects.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
{{- $fingerprint := .Scratch.Get "fingerprint" -}}
{{- $data := index .Site.Data (printf "projects.%v" .Language) | default .Site.Data.projects -}}
{{- $toc := .Scratch.Get "toc" -}}
{{- $tableOfContents := .Fragments.ToHTML ($toc.startLevel | int) ($toc.endLevel | int) false -}}
{{- $tableOfContents := .Fragments.ToHTML ($toc.startlevel | int) ($toc.endlevel | int) false -}}
{{- $contentToc := ne $tableOfContents `<nav id="TableOfContents"></nav>` -}}
{{- $hasToc := $contentToc | or (gt (len $data) 0) | or (gt .Pages.Len 0) -}}
{{- $showToc := $toc.enable | and $hasToc -}}
Expand Down Expand Up @@ -70,7 +70,7 @@ <h1 class="single-title animate__animated animate__pulse animate__faster">
{{- $tableOfContents = replaceRE "</nav>" (printf "<ul>%v</ul></nav>" .) $tableOfContents -}}
{{- end -}}
{{- end -}}
<div class="details toc{{ with $params.password }} encrypted-hidden{{ end }}" id="toc-static" data-kept="{{ if $toc.keepStatic }}true{{ else }}false{{ end }}">
<div class="details toc{{ with $params.password }} encrypted-hidden{{ end }}" id="toc-static" data-kept="{{ if $toc.keepstatic }}true{{ else }}false{{ end }}">
<div class="details-summary toc-title">
<span>{{ T "single.contents" }}</span>
<span>{{ dict "Class" "details-icon fa-solid fa-angle-right" | partial "plugin/icon.html" }}</span>
Expand Down

0 comments on commit c9298c9

Please sign in to comment.