mirror of
https://github.com/McShelby/hugo-theme-relearn
synced 2025-04-30 17:41:02 +08:00
theme: fix broken id renaming #646
This commit is contained in:
parent
b78ee3d8af
commit
df554691ce
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
<form action="javascript:triggerSearch()">
|
<form action="javascript:triggerSearch()">
|
||||||
<div class="searchform">
|
<div class="searchform">
|
||||||
<label class="a11y-only" for="R-section--detail">{{ T "Search" }}</label>
|
<label class="a11y-only" for="R-section-by-detail">{{ T "Search" }}</label>
|
||||||
<input data-search-input id="R-search-by-detail" class="search-by" name="search-by" type="search" placeholder="{{ T "Search-placeholder" }}">
|
<input data-search-input id="R-search-by-detail" class="search-by" name="search-by" type="search" placeholder="{{ T "Search-placeholder" }}">
|
||||||
{{- partial "shortcodes/button.html" (dict
|
{{- partial "shortcodes/button.html" (dict
|
||||||
"page" $page
|
"page" $page
|
||||||
|
@ -174,7 +174,7 @@
|
|||||||
{{- $currentAlwaysopen := .Params.alwaysopen | default $alwaysopen }}
|
{{- $currentAlwaysopen := .Params.alwaysopen | default $alwaysopen }}
|
||||||
{{- $pageHash := md5 .Page }}
|
{{- $pageHash := md5 .Page }}
|
||||||
{{- $isOpen := or $currentAlwaysopen $isSelf $isAncestor }}
|
{{- $isOpen := or $currentAlwaysopen $isSelf $isAncestor }}
|
||||||
<li data-nav-id="{{ $url }}" class="{{if $isActive }}active {{end}}{{if (or $isSelf $isAncestor) }}parent {{end}}{{if $currentAlwaysopen}}alwaysopen{{end}}">{{ if $isCollapsible }}<input type="checkbox" id="R-section-{{ $pageHash }}" aria-controls="#R-subsections-{{ $pageHash }}"{{ if $isOpen }} checked{{ end }}><label for="R-section-{{ $pageHash }}"><i class="fas fa-chevron-down"></i><i class="fas fa-chevron-right"></i><span class="a11y-only">{{ T "Submenu" $title }}</span></label>{{ end }}{{ if $url }}<a class="padding" href="{{ $url }}">{{ else }}<span class="padding">{{ end }}
|
<li data-nav-id="{{ $url }}" class="{{if $isActive }}active {{end}}{{if (or $isSelf $isAncestor) }}parent {{end}}{{if $currentAlwaysopen}}alwaysopen{{end}}">{{ if $isCollapsible }}<input type="checkbox" id="R-section-{{ $pageHash }}" aria-controls="R-subsections-{{ $pageHash }}"{{ if $isOpen }} checked{{ end }}><label for="R-section-{{ $pageHash }}"><i class="fas fa-chevron-down"></i><i class="fas fa-chevron-right"></i><span class="a11y-only">{{ T "Submenu" $title }}</span></label>{{ end }}{{ if $url }}<a class="padding" href="{{ $url }}">{{ else }}<span class="padding">{{ end }}
|
||||||
{{- partial "menu-pre.html" . }}{{ $title }}{{ partial "menu-post.html" . }}
|
{{- partial "menu-pre.html" . }}{{ $title }}{{ partial "menu-post.html" . }}
|
||||||
{{- if $url }}{{ if $showvisitedlinks }}<i class="fas fa-check read-icon"></i>{{ end }}</a>{{ else }}</span>{{ end }}<ul id="R-subsections-{{ $pageHash }}" class="morespace collapsible-menu">
|
{{- if $url }}{{ if $showvisitedlinks }}<i class="fas fa-check read-icon"></i>{{ end }}</a>{{ else }}</span>{{ end }}<ul id="R-subsections-{{ $pageHash }}" class="morespace collapsible-menu">
|
||||||
{{- $defaultAlwaysopen := .Site.Params.alwaysopen | default true }}
|
{{- $defaultAlwaysopen := .Site.Params.alwaysopen | default true }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user