Skip to content

Commit

Permalink
Merge pull request #495 from HubSpot/update-icon-set
Browse files Browse the repository at this point in the history
Update icon set + icons used for social follow module
  • Loading branch information
jazzyclimber authored Nov 1, 2023
2 parents aee54a7 + 419f40e commit 79308ff
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/modules/pricing-card.module/fields.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
"label": "Features list icon",
"name": "feature_icon",
"type": "icon",
"icon_set" : "fontawesome-6.4.2",
"default": {
"name": "check",
"type": "SOLID",
Expand Down
5 changes: 3 additions & 2 deletions src/modules/social-follow.module/fields.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"type": "choice",
"choices": [
["facebook-f", "Facebook"],
["twitter", "Twitter"],
["x-twitter", "Twitter"],
["instagram", "Instagram"],
["linkedin-in", "LinkedIn"],
["youtube", "YouTube"],
Expand All @@ -33,6 +33,7 @@
"label": "Custom icon",
"name": "custom_icon",
"type": "icon",
"icon_set" : "fontawesome-6.4.2",
"visibility": {
"controlling_field": "social_account",
"controlling_value_regex": "custom_icon",
Expand Down Expand Up @@ -108,7 +109,7 @@
}
},
{
"social_account": "twitter",
"social_account": "x-twitter",
"social_link": {
"no_follow": false,
"open_in_new_tab": true,
Expand Down
7 changes: 5 additions & 2 deletions src/modules/social-follow.module/module.html
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,10 @@

{# Sets a custom icon if the custom option is selected #}

{% if item.social_account != "custom_icon" %}
{% set social_icon = item.social_account %}
{% if item.social_account == "whatsapp" %}
{% set social_icon = "What's App" %}
{% elif item.social_account != "custom_icon" %}
{% set social_icon = item.social_account|replace("-", " ") %}
{% else %}
{% set social_icon = item.custom_icon.name %}
{% endif %}
Expand All @@ -118,6 +120,7 @@
{% icon
extra_classes="social-links__icon",
name="{{ social_icon }}",
icon_set="fontawesome-6.4.2"
purpose="semantic",
style="SOLID",
title="{{ item.accessibility.title }}",
Expand Down

0 comments on commit 79308ff

Please sign in to comment.