1
0
mirror of https://github.com/squidfunk/mkdocs-material.git synced 2024-11-28 17:30:56 +01:00
mkdocs-material/material/partials/language.html

12 lines
415 B
HTML
Raw Normal View History

{% set languages = "en" %}
2017-10-31 18:21:09 +01:00
{% if config and config.theme %}
{% set languages = config.theme.language | default("en") %}
{% endif %}
{% if languages is string %}
{% set languages = languages.split(",") | map("trim") %}
{% endif %}
{% import "partials/language/" + (languages | first) + ".html" as lang %}
{% macro t(key) %}{{ {
"search.languages": languages | join(", ")
}[key] or lang.t(key) }}{% endmacro %}