Skip to content
This repository has been archived by the owner on Apr 21, 2022. It is now read-only.

Fixed issue with social media icons being off centered by default #103

Merged
merged 5 commits into from
Apr 1, 2019

Conversation

LandonPatmore
Copy link
Contributor

When using the default:

  {% if site.social_media %}
  <div
    class="d-flex flex-wrap flex-items-start {% if site.layout == 'stacked' %}flex-justify-center mt-1 mt-md-3{% endif %}">
    {% for account in site.social_media %}
    <div class="mr-3 mb-3 smedia-icon">
      {% assign service_shortname = account[0] %}
      {% assign service = site.data.social_media[service_shortname] %}
      <a href="{{ service.profile_url_prefix }}{{ account[1] }}" title="{{ service.name }}: {{ account[1] }}"
        class="tooltipped tooltipped-s" aria-label="{{ service.name }}: {{ account[1] }}">
        {{ service.icon_svg }}<span class="d-none">{{ service.name }}</span>
      </a>
    </div>
    {% endfor %}
  </div>
  {% endif %}

inside of masthead.html, the icons are pushed left and off centered.

I added a fix so that the icons are centered properly.

Old:

New:

@LandonPatmore LandonPatmore changed the title fixes issue with social media icons offcentered Fixed issue with social media icons being off centered by default Mar 20, 2019
Copy link
Collaborator

@brandonrosage brandonrosage left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've replaced the custom CSS with a Liquid condition that omits the mr-3 utility class on the last item. Cool?

@LandonPatmore
Copy link
Contributor Author

@brandonrosage Huh, didn't know liquid could do that. Yah that is awesome! But you are going to hate me for this, but the Github name, email, and location also have the same exact issue. I noticed this after the fact.

@brandonrosage
Copy link
Collaborator

@landonp1203 Thanks for catching that! Got it fixed 👍

@brandonrosage brandonrosage merged commit 6c846f3 into github:master Apr 1, 2019
@LandonPatmore LandonPatmore deleted the dev branch April 1, 2019 19:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants