serving social icons from static instead of using the ones from their sites (faster, does not set cookies from <website of icon>)

This commit is contained in:
Leonard Lorenz 2020-12-05 22:23:37 +01:00
parent 4f6ba72fc3
commit cbc7831193
7 changed files with 6 additions and 6 deletions

2
.gitignore vendored
View file

@ -3,4 +3,4 @@ target
db.sqlite3 db.sqlite3
*.png *.png
*.jpg *.jpg
*.ico ./content/static/favicon.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 614 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View file

@ -21,19 +21,19 @@
<p> <p>
<ul style="list-style: none;"> <ul style="list-style: none;">
{% if github_account %} {% if github_account %}
<li><img class="social-icon" src="https://github.com/favicon.ico"><a href="https://github.com/{{ github_account }}"> {{ github_account }}</a></li> <li><img class="social-icon" src="/static/social-icons/github.ico"><a href="https://github.com/{{ github_account }}"> {{ github_account }}</a></li>
{% endif %} {% endif %}
{% if twitter_account %} {% if twitter_account %}
<li><img class="social-icon" src="https://twitter.com/favicon.ico"><a href="https://twitter.com/{{ twitter_account }}"> {{ twitter_account }}</a></li> <li><img class="social-icon" src="/static/social-icons/twitter.ico"><a href="https://twitter.com/{{ twitter_account }}"> {{ twitter_account }}</a></li>
{% endif %} {% endif %}
{% if reddit_account %} {% if reddit_account %}
<li><img class="social-icon" src="https://reddit.com/favicon.ico"><a href="https://reddit.com/u/{{ reddit_account }}"> {{ reddit_account }}</a></li> <li><img class="social-icon" src="/static/social-icons/reddit.ico"><a href="https://reddit.com/u/{{ reddit_account }}"> {{ reddit_account }}</a></li>
{% endif %} {% endif %}
{% if mastodon_account %} {% if mastodon_account %}
<li><img class="social-icon" src="https://mastodon.social/favicon.ico"><a href="https://discord.com/"> {{ mastodon_account }}</a></li> <li><img class="social-icon" src="/static/social-icons/mastodon.ico"><a href="https://mastodon.social/"> {{ mastodon_account }}</a></li>
{% endif %} {% endif %}
{% if discord_account %} {% if discord_account %}
<li><img class="social-icon" src="https://discord.com/assets/07dca80a102d4149e9736d4b162cff6f.ico"><a href="https://discord.com/"> {{ discord_account }}</a></li> <li><img class="social-icon" src="/static/social-icons/discord.ico"><a href="https://discord.com/"> {{ discord_account }}</a></li>
{% endif %} {% endif %}
</ul> </ul>
</p> </p>