Merge branch 'main' into allow-sharing-without-description
This commit is contained in:
@ -15,6 +15,13 @@
|
||||
{%- if config.extra.nav.links %}
|
||||
{% include "partials/nav.html" %}
|
||||
{%- endif %}
|
||||
{%- if page.extra.toc_sidebar or section.extra.toc_sidebar -%}
|
||||
<div id="sidebar">
|
||||
<div>
|
||||
{%- include "partials/toc.html" -%}
|
||||
</div>
|
||||
</div>
|
||||
{%- endif -%}
|
||||
<main id="main-content">
|
||||
{% block custom %}{% endblock custom %}
|
||||
{% block content %}{% endblock content %}
|
||||
|
@ -3,6 +3,8 @@
|
||||
{% block content %}
|
||||
<h1>{{ page.title }}</h1>
|
||||
{%- include "partials/statements.html" -%}
|
||||
{%- if page.extra.toc and not page.extra.toc_sidebar -%}
|
||||
{%- include "partials/toc.html" -%}
|
||||
{%- endif -%}
|
||||
{{ page.content | safe }}
|
||||
{% endblock content %}
|
||||
|
@ -60,7 +60,6 @@
|
||||
</small>
|
||||
{%- endfor -%}
|
||||
{%- endif %}
|
||||
</small>
|
||||
</div>
|
||||
{%- endif -%}
|
||||
</article>
|
||||
|
@ -1,7 +1,35 @@
|
||||
{%- if page.title -%}
|
||||
{{- page.title }} {{ config.extra.title_separator | default(value="-") }} {{ config.title -}}
|
||||
{%- elif section.title -%}
|
||||
{{- section.title }} {{ config.extra.title_separator | default(value="-") }} {{ config.title -}}
|
||||
{# Taken from https://github.com/welpo/tabi/blob/69713c973c11d7646c8fe56476261d96cc1978d8/templates/partials/title.html #}
|
||||
|
||||
{#- Setup -#}
|
||||
{%- set suffix = config.title | safe -%}
|
||||
{%- set custom_separator = config.extra.title_separator | default(value="-") -%}
|
||||
{%- set separator = " " ~ custom_separator ~ " " -%}
|
||||
|
||||
{#- Get the base path for the current language -#}
|
||||
{%- if lang != config.default_language %}
|
||||
{%- set base_path = "/" ~ lang ~ "/" %}
|
||||
{%- else -%}
|
||||
{{- config.title -}}
|
||||
{%- set base_path = "/" %}
|
||||
{%- endif %}
|
||||
|
||||
{%- if current_path and current_path == base_path -%}
|
||||
{%- set prefix = "" -%}
|
||||
{%- set separator = "" -%}
|
||||
{% elif title %}
|
||||
{%- set prefix = title -%}
|
||||
{% elif section.title -%}
|
||||
{%- set prefix = section.title -%}
|
||||
{% elif page.title %}
|
||||
{%- set prefix = page.title -%}
|
||||
{% elif term.name %}
|
||||
{#- Individual tags -#}
|
||||
{%- set prefix = term.name -%}
|
||||
{% elif taxonomy.name %}
|
||||
{#- List of tags -#}
|
||||
{%- set prefix = macros_translate::translate(key=taxonomy.name, language_strings=language_strings) | capitalize -%}
|
||||
{% else %}
|
||||
{%- set prefix = "404" %}
|
||||
{%- endif -%}
|
||||
|
||||
{#- Return the final concatenated string -#}
|
||||
{{- prefix ~ separator ~ suffix -}}
|
||||
|
@ -12,7 +12,7 @@
|
||||
|
||||
{%- if page.extra.toc or section.extra.toc -%}
|
||||
{%- if toc | length > 0 -%}
|
||||
<h2>{{ macros_translate::translate(key="toc", default="Table of Contents", language_strings=language_strings) }}</h2>
|
||||
<h2>{{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }}</h2>
|
||||
<{{ list_element }}>
|
||||
{%- for h1 in toc -%}
|
||||
<li>
|
||||
|
@ -3,6 +3,8 @@
|
||||
{% block content %}
|
||||
<h1>{{ section.title }}</h1>
|
||||
{%- include "partials/statements.html" -%}
|
||||
{%- if section.extra.toc and not section.extra.toc_sidebar -%}
|
||||
{%- include "partials/toc.html" -%}
|
||||
{%- endif -%}
|
||||
{{ section.content | safe }}
|
||||
{% endblock content %}
|
||||
|
Reference in New Issue
Block a user