💄 🐛 Fixed multi languages page display & i18n translate message.

This commit is contained in:
凡梦星尘
2022-06-13 21:22:17 +08:00
parent 48d36a2a54
commit 26030c7fcd
8 changed files with 108 additions and 6 deletions

View File

@@ -13,7 +13,7 @@
<img class="custom-logo-image" src="{{ .Site.Params.customLogo }}" alt="{{ $title }}">
{{- end }}
<a href="{{ .Site.BaseURL }}" class="brand" rel="start">
<a href="{{ "/" | relLangURL }}" class="brand" rel="start">
<i class="logo-line"></i>
<h1 class="site-title">{{ $title }}</h1>
<i class="logo-line"></i>

View File

@@ -6,7 +6,7 @@
{{- $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">
<a href="{{ .URL | relLangURL }}" class="hvr-icon-pulse {{if $active }} menu-item-active{{ end }}" rel="section">
{{- if $ms.icons }}<i class="fa fa-{{ .Pre }} hvr-icon"></i>{{ end }}{{- .Name }}
{{- if and $ms.badges (eq .Identifier "archives" ) }}
<span class="badge">{{ $.Scratch.Get "postsCount" }}</span>

View File

@@ -7,7 +7,7 @@
<span class="post-meta-item-text">{{- print (T "PostCategory") (T "SymbolColon") -}}</span>
{{- range (first 1 .Params.categories) }}
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="/categories/{{ . | urlize }}" itemprop="url" rel="index">
<a href="{{ "/categories/" | relLangURL }}{{ . | urlize }}" itemprop="url" rel="index">
<span itemprop="name">{{- . -}}</span>
</a>
</span>