Within a module I have this social sharing code that utilizes Hubspots Social icons.
I was asked to update the module last month to account for Twitter being X now and found that there was no Hubspot Icon for it. However having x-twitter in the place of twitter in the module below still showed the Twitter icon on the page. My Hope was when the icon got updated, I didn’t have to go back into code to update it there again. Guess I did. LOL.
Yesterday this stopped working and now I am back on twitter as a variable. Does anyone know if there was a change in the backend of the system? Anyone know if there is an ETA? It sounds like we are waiting on X to do some proper branding according to this forum post:
{# Social sharing #}
<div class=“social-sharing” >
{% if module.share_text %}
<h4 class=“social-sharing__share-text” style=“text-align: {{ module.alignment}};”>{{ module.share_text }}</h4>
{% endif %}
{# Loops through icons in the repeater #}
{% for social_link in module.social_links %}
{# Sets href attribute used for the link field #}
{% set social_icon = social_link.social_account %}
{% if social_icon == “facebook-f” %}
{% set href = “http://www.facebook.com/share.php?u={{ content.absolute_url }}” %}
{% elif social_icon == “twitter” %}
{% set href = “https://twitter.com/intent/tweet?url={{ content.absolute_url }}” %}
{% elif social_icon == “linkedin-in” %}
{% set href = “LinkedIn Login, Sign in | LinkedIn{{ content.absolute_url }}” %}
{% elif social_icon == “pinterest-p” %}
{% set href = “Pinterest{{ content.absolute_url }}” %}
{% elif social_icon == “envelope” %}
{% set href = “mailto:?body={{ content.absolute_url }}” %}
{% endif %}
{# Social sharing icon and link #}
<a class=“social-sharing__link” href=“{{ href }}” target=“_blank” rel=“noopener” title=“{{ social_link.social_account }}”>
<span class=“{{ icon_size }} {{ icon_color }} {{ icon_shape }}”>
{% icon
extra_classes=“social-sharing__icon icon”,
name=“{{ social_icon }}”,
purpose=“semantic”,
style=“SOLID”,
title=“{{ social_link.accessibility_options.title }}”
%}
</span>
</a>
{% endfor %}
