|
141 | 141 |
|
142 | 142 | {% block footer %} |
143 | 143 |
|
| 144 | +<div> |
| 145 | + <!-- Link to previous and/or next page --> |
| 146 | + {% if "navigation.footer" in features %} |
| 147 | + {% if page.previous_page or page.next_page %} |
| 148 | + {% if page.meta and page.meta.hide %} |
| 149 | + {% set hidden = "hidden" if "footer" in page.meta.hide %} |
| 150 | + {% endif %} |
| 151 | + <nav |
| 152 | + class="md-footer__inner md-grid" |
| 153 | + aria-label="{{ lang.t('footer') }}" |
| 154 | + {{ hidden }} |
| 155 | + > |
| 156 | + |
| 157 | + <!-- Link to previous page --> |
| 158 | + {% if page.previous_page %} |
| 159 | + {% set direction = lang.t("footer.previous") %} |
| 160 | + <a |
| 161 | + href="{{ page.previous_page.url | url }}" |
| 162 | + class="md-footer__link md-footer__link--prev" |
| 163 | + aria-label="{{ direction }}: {{ page.previous_page.title | e }}" |
| 164 | + > |
| 165 | + <div class="md-footer__button md-icon"> |
| 166 | + {% set icon = config.theme.icon.previous or "material/arrow-left" %} |
| 167 | + {% include ".icons/" ~ icon ~ ".svg" %} |
| 168 | + </div> |
| 169 | + <div class="md-footer__title"> |
| 170 | + <span class="md-footer__direction"> |
| 171 | + {{ direction }} |
| 172 | + </span> |
| 173 | + <div class="md-ellipsis"> |
| 174 | + {{ page.previous_page.title }} |
| 175 | + </div> |
| 176 | + </div> |
| 177 | + </a> |
| 178 | + {% endif %} |
| 179 | + |
| 180 | + <!-- Link to next page --> |
| 181 | + {% if page.next_page %} |
| 182 | + {% set direction = lang.t("footer.next") %} |
| 183 | + <a |
| 184 | + href="{{ page.next_page.url | url }}" |
| 185 | + class="md-footer__link md-footer__link--next" |
| 186 | + aria-label="{{ direction }}: {{ page.next_page.title | e }}" |
| 187 | + > |
| 188 | + <div class="md-footer__title"> |
| 189 | + <span class="md-footer__direction"> |
| 190 | + {{ direction }} |
| 191 | + </span> |
| 192 | + <div class="md-ellipsis"> |
| 193 | + {{ page.next_page.title }} |
| 194 | + </div> |
| 195 | + </div> |
| 196 | + <div class="md-footer__button md-icon"> |
| 197 | + {% set icon = config.theme.icon.next or "material/arrow-right" %} |
| 198 | + {% include ".icons/" ~ icon ~ ".svg" %} |
| 199 | + </div> |
| 200 | + </a> |
| 201 | + {% endif %} |
| 202 | + </nav> |
| 203 | + {% endif %} |
| 204 | + {% endif %} |
| 205 | +</div> |
| 206 | + |
144 | 207 | <footer class="footer"> |
145 | 208 | <div class="tmp-container"> |
146 | 209 |
|
|
0 commit comments