feat: add rel="me"
to Mastodon sidebar contact links for verification (#807)
This will enable verification with Mastodon by including the `rel="me"` attribute. https://docs.joinmastodon.org/user/profile/#verification Co-authored-by: Cotes Chung <11371340+cotes2020@users.noreply.github.com>
This commit is contained in:
parent
8e73a91d25
commit
d2190c726f
2 changed files with 12 additions and 2 deletions
|
@ -19,7 +19,7 @@
|
||||||
# -
|
# -
|
||||||
# type: mastodon
|
# type: mastodon
|
||||||
# icon: 'fab fa-mastodon' # icons powered by <https://fontawesome.com/>
|
# icon: 'fab fa-mastodon' # icons powered by <https://fontawesome.com/>
|
||||||
# url: '' # Fill with your mastodon account page
|
# url: '' # Fill with your Mastodon account page, rel="me" will be applied for verification
|
||||||
# -
|
# -
|
||||||
# type: linkedin
|
# type: linkedin
|
||||||
# icon: 'fab fa-linkedin' # icons powered by <https://fontawesome.com/>
|
# icon: 'fab fa-linkedin' # icons powered by <https://fontawesome.com/>
|
||||||
|
|
|
@ -81,7 +81,17 @@
|
||||||
|
|
||||||
{% if url %}
|
{% if url %}
|
||||||
<a href="{{ url }}" aria-label="{{ entry.type }}"
|
<a href="{{ url }}" aria-label="{{ entry.type }}"
|
||||||
{% unless entry.noblank %}target="_blank" rel="noopener"{% endunless %}>
|
{% assign link_types = nil %}
|
||||||
|
{% unless entry.noblank %}
|
||||||
|
{% assign link_types = link_types | append: " noopener" %}
|
||||||
|
target="_blank"
|
||||||
|
{% endunless %}
|
||||||
|
|
||||||
|
{% if entry.type == 'mastodon' %}
|
||||||
|
{% assign link_types = link_types | append: " me" %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if link_types %}rel="{{ link_types | lstrip }}"{% endif %}>
|
||||||
<i class="{{ entry.icon }}"></i>
|
<i class="{{ entry.icon }}"></i>
|
||||||
</a>
|
</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
Loading…
Reference in a new issue