🐛 Fixed menu active action match error item that it could not use cached function.
This commit is contained in:
parent
f1fafdc587
commit
56166c7e76
@ -17,7 +17,7 @@
|
|||||||
<main class="main">
|
<main class="main">
|
||||||
<header class="header" itemscope itemtype="http://schema.org/WPHeader">
|
<header class="header" itemscope itemtype="http://schema.org/WPHeader">
|
||||||
<div class="header-inner">
|
<div class="header-inner">
|
||||||
{{- partialCached "header.html" . }}
|
{{- partial "header.html" . }}
|
||||||
</div>
|
</div>
|
||||||
<!-- Sidebar -->
|
<!-- Sidebar -->
|
||||||
{{- if ne .Site.Params.sidebar.display "remove" }}
|
{{- if ne .Site.Params.sidebar.display "remove" }}
|
||||||
|
@ -1,3 +1,2 @@
|
|||||||
{{ $paginator := .Paginator.Pages.GroupByDate "2006" }}
|
{{ $paginator := .Paginator.Pages.GroupByDate "2006" }}
|
||||||
{{ partial "list.html" $paginator }}
|
{{ partial "list.html" $paginator }}
|
||||||
|
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
<ul class="main-menu menu">
|
|
||||||
{{- $curP := . }}
|
|
||||||
{{- range .Site.Menus.main }}
|
|
||||||
{{ $active := or ($curP.IsMenuCurrent "main" .) ($curP.HasMenuCurrent "main" .) }}
|
|
||||||
{{ $active = or $active (eq .URL "/")}}
|
|
||||||
<li class="menu-item menu-item-{{ .Identifier }}">
|
|
||||||
<a href="{{ .URL }}" class="hvr-icon-pulse{{if $active }} menu-item-active{{ end }}" rel="section">
|
|
||||||
<i class="fa fa-{{ .Pre }} hvr-icon"></i>{{- .Name }}
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
{{- end }}
|
|
||||||
</ul>
|
|
Loading…
Reference in New Issue
Block a user