Fixed migration guide

This commit is contained in:
squidfunk 2020-03-10 23:43:27 +01:00
parent bfa1d9ce47
commit ff8c4a30c6

View File

@ -672,14 +672,16 @@ matches the new structure:
#### `partials/social.html`
``` diff
@@ -3,9 +3,10 @@
@@ -3,9 +3,12 @@
-#}
{% if config.extra.social %}
<div class="md-footer-social">
- <link rel="stylesheet" href="{{ 'assets/fonts/font-awesome.css' | url }}">
{% for social in config.extra.social %}
- <a href="{{ social.link }}" target="_blank" rel="noopener" title="{{ social.type }}" class="md-footer-social__link fa fa-{{ social.type }}"></a>
+ <a href="{{ social.link }}" target="_blank" rel="noopener" class="md-footer-social__link">
+ {% set _,rest = social.link.split("//") %}
+ {% set domain = rest.split("/")[0] %}
+ <a href="{{ social.link }}" target="_blank" rel="noopener" title="{{ domain }}" class="md-footer-social__link">
+ {% include ".icons/" ~ social.icon ~ ".svg" %}
+ </a>
{% endfor %}
@ -711,7 +713,7 @@ matches the new structure:
#### `partials/source-link.html`
``` diff
@@ -0,0 +1,17 @@
@@ -0,0 +1,13 @@
+{#-
+ This file was automatically generated - do not edit
+-#}
@ -721,13 +723,9 @@ matches the new structure:
+ {% set repo = repo[:-1] %}
+{% endif %}
+{% set path = page.meta.path | default([""]) %}
+{% set file = page.meta.source %}
+{% set repo_icon = config.extra.repo_icon | default(
+ "fontawesome/brands/git-alt"
+) %}
+<a href="{{ [repo, path, page.meta.source] | join('/') }}" title="{{ file }}" class="md-content__button md-icon">
+ {{ lang.t("meta.source") }}
+ {% include ".icons/" ~ repo_icon ~ ".svg" %}
+ {% include ".icons/" ~ config.theme.icon.repo ~ ".svg" %}
+</a>
```