@if $standard-iconset == font-awesome {
  $fa-font-path: "#{$portal-url}/++resource++ftw.theming/font-awesome/fonts";
  @import "../font-awesome/scss/font-awesome";

  /* We dont want the font-family to be changed on the text elements
     but only on the before pseudo-elements. */
  .#{$fa-css-prefix}-icon {
    &:before {
      display: inline-block;
      font-family: FontAwesome;
      text-align: center;
      min-width: 1.4em;
      margin-right: 0.2em;
    }
  }
  .#{$fa-css-prefix}-icon-right {
    &:after {
      display: inline-block;
      font-family: FontAwesome;
      text-align: center;
      min-width: 1.4em;
      margin-right: 0.2em;
    }
  }

  .icons-on [class^="contenttype-"],
  .icons-on [class*=" contenttype-"] {
    @extend .#{$fa-css-prefix}-times-circle;
    @extend .#{$fa-css-prefix}-icon;
    &:before {
      color: fuchsia;
    }
  }

  @each $type, $value in get-portal-type-icons-for-iconset(font-awesome) {
    body.icons-on .contenttype-$type {
      @extend .#{$fa-css-prefix}-#{$value};
      &:before {
        color: inherit;
      }
    }
  }

  @if $use-font-awesome-mimetype-icons == true {

    @each $type in get-portal-types-with-mimetype-icons() {
      .icons-on a.contenttype-$type:before {
        display: none;
      }

      .icons-on #plone-contentmenu-factories a.contenttype-$type:before,
      .icons-on.template-theming-icons a.contenttype-$type:before {
        display: inline-block;
      }
      .icons-on.template-theming-icons a.contenttype-$type {
        @extend .fa-icon-right;
        &:after {
          content: '\f005';
          color: #A00;
          font-size: 70%;
          vertical-align: top;
        }
      }

      .icons-on.template-search .searchResults > .contenttype-$type {
        &:before {
          display: none;
        }
      }
    }

    @each $classpostfix, $value in get-mime-type-icons-for-iconset(font-awesome) {
      body.icons-on span.mimetype-icon.icon-mimetype-img-$classpostfix {
        >img {
          display: none;
        }
        @extend .fa-icon;
        @extend .#{$fa-css-prefix}-#{$value};
      }
    }

  }
}
