Skip to content

Commit db2a1d1

Browse files
authored
Socials icons: Check if rss_icon: false (alshedivat#3282)
Partially addresses issue alshedivat#3280. Currently, the RSS feed icon in the socials section will show whenever `rss_icon` in `data/_socials.yml` has a value --- **even if that value is `false`**. Unlike the other social settings, which are empty by default, for `rss_icon` the default setting is `true`. So it makes sense that a user might expect `rss_icon: false` to disable said icon. This PR just adds a check if the value is `false` and hides the icon if so.
1 parent 859a245 commit db2a1d1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

_includes/social.liquid

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@
5959
{% when 'research_gate_profile' %}
6060
<a href="https://www.researchgate.net/profile/{{ social[1] }}/" title="ResearchGate"><i class="ai ai-researchgate"></i></a>
6161
{% when 'rss_icon' %}
62-
<a href="{{ site.baseurl }}/feed.xml" title="RSS Feed"><i class="fa-solid fa-square-rss"></i></a>
62+
{% if social[1] == true %}
63+
<a href="{{ site.baseurl }}/feed.xml" title="RSS Feed"><i class="fa-solid fa-square-rss"></i></a>
64+
{% endif %}
6365
{% when 'scholar_userid' %}
6466
<a href="https://scholar.google.com/citations?user={{ social[1] }}" title="Google Scholar"><i class="ai ai-google-scholar"></i></a>
6567
{% when 'scopus_id' %}

0 commit comments

Comments
 (0)