Skip to content
Snippets Groups Projects
Commit 5e7ad632 authored by squidfunk's avatar squidfunk Committed by Martin Donath
Browse files

Improved downward compatibility with custom partials

parent 9dd7aac4
No related branches found
No related tags found
No related merge requests found
{% set languages = "en" %}
{% if config and config.extra %}
{% set languages = config.extra.language | default("en") %} {% set languages = config.extra.language | default("en") %}
{% endif %}
{% if languages is string %} {% if languages is string %}
{% set languages = languages.split(",") | map("trim") %} {% set languages = languages.split(",") | map("trim") %}
{% endif %} {% endif %}
......
{% macro t(key) %}{{ {
"language": "es",
"clipboard.copy": "Copiar al portapapeles",
"clipboard.copied": "Copiado al portapapeles",
"edit.link.title": "Editar esta página",
"footer.previous": "Anterior",
"footer.next": "Siguiente",
"meta.comments": "Comentarios",
"meta.source": "Fuente",
"search.placeholder": "Búsqueda",
"search.result.placeholder": "Teclee para comenzar búsqueda",
"search.result.none": "No se encontraron documentos",
"search.result.one": "1 documento encontrado",
"search.result.other": "# documentos encontrados",
"search.tokenizer": "[\s\-]+",
"source.link.title": "Ir al repositorio",
"toc.title": "Tabla de contenidos"
}[key] }}{% endmacro %}
{% macro t(key) %}{{ { "language": "pl", "clipboard.copy": "Kopiuj do schowka", "clipboard.copied": "Skopiowane", "edit.link.title": "Edytuj tę stronę", "footer.previous": "Poprzednia strona", "footer.next": "Następna strona", "meta.comments": "Komentarze", "meta.source": "Kod źródłowy", "search.placeholder": "Szukaj", "search.result.placeholder": "Zacznij pisać, aby szukać", "search.result.none": "Brak wyników wyszukiwania", "search.result.one": "Wyniki wyszukiwania: 1", "search.result.other": "Wyniki wyszukiwania: #", "search.tokenizer": "[\s\-]+", "source.link.title": "Idź do repozytorium", "toc.title": "Spis treści" }[key] }}{% endmacro %}
{% macro t(key) %}{{ {
"language": "sv",
"clipboard.copy": "Kopiera till urklipp",
"clipboard.copied": "Kopierat till urklipp",
"edit.link.title": "Redigera sidan",
"footer.previous": "Föregående",
"footer.next": "Nästa",
"meta.comments": "Kommentarer",
"meta.source": "Källa",
"search.placeholder": "Sök",
"search.result.placeholder": "Skriv sökord",
"search.result.none": "Inga sökresultat",
"search.result.one": "1 sökresultat",
"search.result.other": "# sökresultat",
"search.tokenizer": "[\s\-]+",
"source.link.title": "Gå till datakatalog",
"toc.title": "Innehållsförteckning"
}[key] }}{% endmacro %}
...@@ -21,7 +21,10 @@ ...@@ -21,7 +21,10 @@
--> -->
<!-- Normalize language configuration --> <!-- Normalize language configuration -->
{% set languages = "en" %}
{% if config and config.extra %}
{% set languages = config.extra.language | default("en") %} {% set languages = config.extra.language | default("en") %}
{% endif %}
{% if languages is string %} {% if languages is string %}
{% set languages = languages.split(",") | map("trim") %} {% set languages = languages.split(",") | map("trim") %}
{% endif %} {% endif %}
......
<!-- <!--
Copyright (c) 2016-2017 Martin Donath <martin.donath@squidfunk.com> Copyright (c) 2016-2017 Martin Donath <martin.donath@squidfunk.com>
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions: furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software. all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE
......
...@@ -21,7 +21,6 @@ IN THE SOFTWARE. ...@@ -21,7 +21,6 @@ IN THE SOFTWARE.
--> -->
<!-- Translations: Swedish --> <!-- Translations: Swedish -->
{% macro t(key) %}{{ { {% macro t(key) %}{{ {
"language": "sv", "language": "sv",
"clipboard.copy": "Kopiera till urklipp", "clipboard.copy": "Kopiera till urklipp",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment