1
0
mirror of https://github.com/cotes2020/jekyll-theme-chirpy.git synced 2025-12-18 13:44:15 +00:00

Compare commits

...

1 Commits

Author SHA1 Message Date
nakamura
52d160f857 fix(i18n): localize the title (#2610) 2025-12-18 01:51:53 +08:00
2 changed files with 11 additions and 3 deletions

View File

@@ -57,9 +57,17 @@
<title>
{%- unless page.layout == 'home' -%}
{{ page.title | append: ' | ' }}
{%- capture title -%}
{%- if page.collection == 'tabs' -%}
{%- assign tab_key = page.title | downcase -%}
{{- site.data.locales[include.lang].tabs[tab_key] -}}
{%- else -%}
{{- page.title -}}
{%- endif -%}
{%- endcapture -%}
{{- title | append: ' | ' -}}
{%- endunless -%}
{{ site.title }}
{{- site.title -}}
</title>
{% include_cached favicons.html %}

View File

@@ -14,7 +14,7 @@ layout: compress
<!-- `site.alt_lang` can specify a language different from the UI -->
<html lang="{{ page.lang | default: site.alt_lang | default: site.lang }}" {{ prefer_mode }}>
{% include head.html %}
{% include head.html lang=lang %}
<body>
{% include sidebar.html lang=lang %}