2 years ago

#71826

test-img

J82

Fallback for icon fonts that don't work in older versions of OSX?

I'm using Elegant Icons and this is an example of what the content looks like for my elements (the \35 content is a down arrow icon):

<span class="submenu-icon">::after</span>

.menu-navigation-vertical ul li.menu-item-has-children .submenu-icon:after {
    font-size: 1.83333rem;
    content: '\35';
    font-family: eleganticons;
    color: #050505;
    line-height: 1;
}

The issue I'm having is that the font doesn't render correctly in older versions of OSX (specifically El Capitan and down). It shows a '3' instead of the down arrow. Is there some sort of fallback I can add to this code to show alternate content (for example, a down arrow using just html) on older versions of OSX?

@font-face {
  font-family: "ElegantIcons";
  font-style: normal;
  font-weight: normal;
  src: url("https://cdn.rawgit.com/mdentinho/elegant-icons-sass/e48e7df0/fonts/ElegantIcons.woff2") format("woff2"), url("https://cdn.rawgit.com/mdentinho/elegant-icons-sass/e48e7df0/fonts/ElegantIcons.woff") format("woff");
}

css

fonts

fallback

0 Answers

Your Answer

Accepted video resources