diff --git a/docs/customization.md b/docs/customization.md index 3b6311cf7..00cdbcbe0 100644 --- a/docs/customization.md +++ b/docs/customization.md @@ -98,16 +98,14 @@ The directory layout of the Material theme is as follows: │ ├─ javascripts/ # JavaScript │ └─ stylesheets/ # Stylesheets ├─ partials/ -│ ├─ fonts.html # Webfont definitions │ ├─ footer.html # Footer bar │ ├─ header.html # Header bar -│ ├─ i18n.html # Localized labels +│ ├─ language.html # Localized labels │ ├─ nav-item.html # Main navigation item │ ├─ nav.html # Main navigation │ ├─ search.html # Search box │ ├─ social.html # Social links │ ├─ source.html # Repository information -│ ├─ svgs.html # Inline SVG definitions │ ├─ toc-item.html # Table of contents item │ └─ toc.html # Table of contents ├─ 404.html # 404 error page diff --git a/docs/getting-started.md b/docs/getting-started.md index 1d770d6b9..fdd2fee65 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -281,8 +281,8 @@ google_analytics: ### Localization L10N In order to localize the labels (e.g. *Previous* and *Next* in the footer), -you can override the file `partials/i18n.html` to provide your own translations -inside the macro `t`: +you can override the file `partials/language.html` to provide your own +translations inside the macro `t`: ``` jinja {% macro t(key) %}{{ { diff --git a/material/base.html b/material/base.html index 1d2d05cfd..7ad657477 100644 --- a/material/base.html +++ b/material/base.html @@ -1,4 +1,4 @@ -{% import "partials/i18n.html" as i18n %} +{% import "partials/language.html" as lang %}
@@ -34,7 +34,15 @@ {% endblock %} {% block fonts %} - {% include "partials/fonts.html" %} + {% if config.extra.font != "none" %} + {% set text = config.extra.get("font", {}).text | default("Roboto") %} + {% set code = config.extra.get("font", {}).code + | default("Roboto Mono") %} + {% set font = text + ':300,400,400i,700|' + code | replace(' ', '+') %} + + + {% endif %} + {% endblock %} {% block styles %} @@ -55,7 +63,18 @@ {% else %} {% endif %} - {% include "partials/svgs.html" %} + @@ -88,7 +107,7 @@