Improve email javascript in sidebar (#155)

This will appear in Firefox and Safari.

Remediates the issue describe here: https://stackoverflow.com/questions/21461589/javascript-mailto-using-window-open#32675594
This commit is contained in:
Marnick Vandecauter 2020-10-18 16:10:27 +00:00 committed by GitHub
parent b9fb716e6a
commit 46a8efb38a
1 changed files with 2 additions and 2 deletions

View File

@ -72,7 +72,7 @@
https://twitter.com/{{ site.twitter.username }}
{%- elsif entry.type == 'email' -%}
{% assign email = site.social.email | split: '@' %}
javascript:window.open('mailto:' + ['{{ email[0] }}','{{ email[1] }}'].join('@'))
javascript:location.href = 'mailto:' + ['{{ email[0] }}','{{ email[1] }}'].join('@')
{%- elsif entry.type == 'rss' -%}
{{ "/feed.xml" | relative_url }}
{%- else -%}