Formatting

This commit is contained in:
squidfunk 2020-03-18 17:28:26 +01:00
parent e7f7632278
commit 4ffa866609
17 changed files with 50 additions and 25 deletions

View File

@ -5,7 +5,7 @@
<footer class="md-footer">
{% if page.previous_page or page.next_page %}
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid">
<nav class="md-footer-nav__inner md-grid" aria-label="{{ lang.t('footer.title') }}">
{% if page.previous_page %}
<a href="{{ page.previous_page.url | url }}" title="{{ page.previous_page.title | striptags }}" class="md-footer-nav__link md-footer-nav__link--prev" rel="prev">
<div class="md-footer-nav__button md-icon">

View File

@ -2,8 +2,8 @@
This file was automatically generated - do not edit
-#}
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<a href="{{ config.site_url | default(nav.homepage.url, true) | url }}" title="{{ config.site_name }}" aria-label="{{ config.site_name }}" class="md-header-nav__button md-logo">
<nav class="md-header-nav md-grid" aria-label="{{ lang.t('header.title') }}">
<a href="{{ config.site_url | default(nav.homepage.url, true) | url }}" title="{{ config.site_name }}" class="md-header-nav__button md-logo" aria-label="{{ config.site_name }}">
{% if config.theme.logo %}
<img src="{{ config.theme.logo | url }}" alt="logo">
{% else %}

View File

@ -9,12 +9,16 @@
"edit.link.title": "Edit this page",
"footer.previous": "Previous",
"footer.next": "Next",
"footer.title": "Footer",
"header.title": "Header",
"meta.comments": "Comments",
"meta.source": "Source",
"nav.title": "Navigation",
"search.config.lang": "en",
"search.config.pipeline": "trimmer, stopWordFilter",
"search.config.separator": "[\s\-]+",
"search.placeholder": "Search",
"search.reset": "Clear",
"search.result.placeholder": "Type to start searching",
"search.result.none": "No matching documents",
"search.result.one": "1 matching document",
@ -22,5 +26,6 @@
"skip.link.title": "Skip to content",
"source.link.title": "Go to repository",
"source.revision.date": "Last update",
"tabs.title": "Tabs",
"toc.title": "Table of contents"
}[key] }}{% endmacro %}

View File

@ -8,10 +8,14 @@
"edit.link.title": "Editar esta página",
"footer.previous": "Anterior",
"footer.next": "Siguiente",
"footer.title": "Pie",
"header.title": "Cabecera",
"meta.comments": "Comentarios",
"meta.source": "Fuente",
"nav.title": "Navegación"
"search.config.lang": "es",
"search.placeholder": "Búsqueda",
"search.reset": "Limpiar",
"search.result.placeholder": "Teclee para comenzar búsqueda",
"search.result.none": "No se encontraron documentos",
"search.result.one": "1 documento encontrado",
@ -19,5 +23,6 @@
"skip.link.title": "Saltar a contenido",
"source.link.title": "Ir al repositorio",
"source.revision.date": "Última actualización",
"tabs.title": "Pestañas",
"toc.title": "Tabla de contenidos"
}[key] }}{% endmacro %}

View File

@ -18,7 +18,7 @@
{% include ".icons/material/chevron-right.svg" %}
</span>
</label>
<nav class="md-nav" data-md-level="{{ level }}">
<nav class="md-nav" aria-label="{{ nav_item.title }}" data-md-level="{{ level }}">
<label class="md-nav__title" for="{{ path }}">
<span class="md-nav__icon md-icon">
{% include ".icons/material/arrow-left.svg" %}

View File

@ -1,9 +1,9 @@
{#-
This file was automatically generated - do not edit
-#}
<nav class="md-nav md-nav--primary" data-md-level="0">
<nav class="md-nav md-nav--primary" aria-label="{{ lang.t('nav.title') }}" data-md-level="0">
<label class="md-nav__title" for="__drawer">
<a href="{{ config.site_url | default(nav.homepage.url, true) | url }}" title="{{ config.site_name }}" aria-label="{{ config.site_name }}" class="md-nav__button md-logo">
<a href="{{ config.site_url | default(nav.homepage.url, true) | url }}" title="{{ config.site_name }}" class="md-nav__button md-logo" aria-label="{{ config.site_name }}">
{% if config.theme.logo %}
<img src="{{ config.theme.logo | url }}" alt="logo">
{% else %}

View File

@ -6,12 +6,12 @@
<label class="md-search__overlay" for="__search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" aria-label="search" placeholder="{{ lang.t('search.placeholder') }}" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="search-query" data-md-state="active" required>
<input type="text" class="md-search__input" name="query" placeholder="{{ lang.t('search.placeholder') }}" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="search-query" data-md-state="active" required>
<label class="md-search__icon md-icon" for="__search">
{% include ".icons/material/magnify.svg" %}
{% include ".icons/material/arrow-left.svg" %}
</label>
<button type="reset" class="md-search__icon md-icon" aria-label="reset" data-md-component="search-reset" tabindex="-1">
<button type="reset" class="md-search__icon md-icon" aria-label="{{ lang.t('search.reset') }}" data-md-component="search-reset" tabindex="-1">
{% include ".icons/material/close.svg" %}
</button>
</form>

View File

@ -5,7 +5,7 @@
{% if page.ancestors | length > 0 %}
{% set class = "md-tabs md-tabs--active" %}
{% endif %}
<nav class="{{ class }}" data-md-component="tabs">
<nav class="{{ class }}" aria-label="{{ lang.t('tabs.title') }}" data-md-component="tabs">
<div class="md-tabs__inner md-grid">
<ul class="md-tabs__list">
{% for nav_item in nav %}

View File

@ -6,7 +6,7 @@
{{ toc_item.title }}
</a>
{% if toc_item.children %}
<nav class="md-nav">
<nav class="md-nav" aria-label="{{ toc_item.title }}">
<ul class="md-nav__list">
{% for toc_item in toc_item.children %}
{% include "partials/toc-item.html" %}

View File

@ -2,7 +2,7 @@
This file was automatically generated - do not edit
-#}
{% import "partials/language.html" as lang with context %}
<nav class="md-nav md-nav--secondary">
<nav class="md-nav md-nav--secondary" aria-label="{{ lang.t('toc.title') }}">
{% set toc = page.toc %}
{% if toc | first is defined and "\x3ch1 id=" in page.content %}
{% set toc = (toc | first).children %}

View File

@ -28,7 +28,10 @@
<!-- Link to previous and/or next page -->
{% if page.previous_page or page.next_page %}
<div class="md-footer-nav">
<nav class="md-footer-nav__inner md-grid" aria-label="{{ lang.t('footer.title') }}">
<nav
class="md-footer-nav__inner md-grid"
aria-label="{{ lang.t('footer.title') }}"
>
<!-- Link to previous page -->
{% if page.previous_page %}

View File

@ -30,8 +30,8 @@
<a
href="{{ config.site_url | default(nav.homepage.url, true) | url }}"
title="{{ config.site_name }}"
aria-label="{{ config.site_name }}"
class="md-header-nav__button md-logo"
aria-label="{{ config.site_name }}"
>
{% if config.theme.logo %}
<img src="{{ config.theme.logo | url }}" alt="logo" />

View File

@ -27,25 +27,25 @@
"clipboard.copy": "Copy to clipboard",
"clipboard.copied": "Copied to clipboard",
"edit.link.title": "Edit this page",
"footer.title": "Pie",
"footer.previous": "Previous",
"footer.next": "Next",
"footer.title": "Footer",
"header.title": "Header",
"meta.comments": "Comments",
"meta.source": "Source",
"nav.title": "Navigation",
"search.config.lang": "en",
"search.config.pipeline": "trimmer, stopWordFilter",
"search.config.separator": "[\s\-]+",
"search.placeholder": "Search",
"search.reset": "Clear",
"search.result.placeholder": "Type to start searching",
"search.result.none": "No matching documents",
"search.result.one": "1 matching document",
"search.result.other": "# matching documents",
"search.reset": "Reset",
"skip.link.title": "Skip to content",
"source.link.title": "Go to repository",
"source.revision.date": "Last update",
"tabs.title": "Tabs",
"toc.title": "Table of contents",
"nav.title": "Navigation"
"toc.title": "Table of contents"
}[key] }}{% endmacro %}

View File

@ -26,23 +26,23 @@
"clipboard.copy": "Copiar al portapapeles",
"clipboard.copied": "Copiado al portapapeles",
"edit.link.title": "Editar esta página",
"footer.title": "Pie",
"footer.previous": "Anterior",
"footer.next": "Siguiente",
"footer.title": "Pie",
"header.title": "Cabecera",
"meta.comments": "Comentarios",
"meta.source": "Fuente",
"nav.title": "Navegación"
"search.config.lang": "es",
"search.placeholder": "Búsqueda",
"search.reset": "Limpiar",
"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.reset": "Restablecer",
"skip.link.title": "Saltar a contenido",
"source.link.title": "Ir al repositorio",
"source.revision.date": "Última actualización",
"tabs.title": "Pestañas",
"toc.title": "Tabla de contenidos",
"nav.title": "Navegación"
"toc.title": "Tabla de contenidos"
}[key] }}{% endmacro %}

View File

@ -55,7 +55,11 @@
{% include ".icons/material/chevron-right.svg" %}
</span>
</label>
<nav class="md-nav" data-md-level="{{ level }}" aria-label="{{ nav_item.title }}">
<nav
class="md-nav"
aria-label="{{ nav_item.title }}"
data-md-level="{{ level }}"
>
<label class="md-nav__title" for="{{ path }}">
<span class="md-nav__icon md-icon">
{% include ".icons/material/arrow-left.svg" %}

View File

@ -21,15 +21,19 @@
-->
<!-- Main navigation -->
<nav class="md-nav md-nav--primary" data-md-level="0" aria-label="{{ lang.t('nav.title') }}">
<nav
class="md-nav md-nav--primary"
aria-label="{{ lang.t('nav.title') }}"
data-md-level="0"
>
<!-- Site title -->
<label class="md-nav__title" for="__drawer">
<a
href="{{ config.site_url | default(nav.homepage.url, true) | url }}"
title="{{ config.site_name }}"
aria-label="{{ config.site_name }}"
class="md-nav__button md-logo"
aria-label="{{ config.site_name }}"
>
{% if config.theme.logo %}
<img src="{{ config.theme.logo | url }}" alt="logo" />

View File

@ -27,7 +27,11 @@
{% endif %}
<!-- Tabs with outline -->
<nav class="{{ class }}" data-md-component="tabs" aria-label="{{ lang.t('tabs.title') }}">
<nav
class="{{ class }}"
aria-label="{{ lang.t('tabs.title') }}"
data-md-component="tabs"
>
<div class="md-tabs__inner md-grid">
<ul class="md-tabs__list">
{% for nav_item in nav %}