// Copyright 2015 Palantir Technologies, Inc. All rights reserved.
// Licensed under the BSD-3 License as modified (the “License”); you may obtain a copy
// of the license at https://github.com/palantir/blueprint/blob/master/LICENSE
// and https://github.com/palantir/blueprint/blob/master/PATENTS

@import "variables";
@import "../generated/icon-variables";
@import "../generated/icon-map";

$icon-classes: (
  ".pt-icon",
  ".pt-icon-standard",
  ".pt-icon-large"
) !default;

@mixin pt-icon-font-smoothing() {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
}

@mixin pt-icon-sized(
  $font-size: $pt-icon-size-standard,
  $font-family-size: strip-units($font-size)
) {
  line-height: 1;
  font-family: "Icons#{$font-family-size}", sans-serif;
  font-size: $font-size;
  font-weight: 400;
  font-style: normal;
}

@mixin pt-icon-colors() {
  color: $pt-icon-color;

  &:hover {
    color: $pt-icon-color-hover;
  }

  .pt-dark & {
    color: $pt-dark-icon-color;

    &:hover {
      color: $pt-dark-icon-color-hover;
    }
  }
}

@mixin pt-icon(
  $font-size: $pt-icon-size-standard,
  $font-family-size: strip-units($font-size)
) {
  @include pt-icon-sized($font-size, $font-family-size);
  @include pt-icon-font-smoothing();
}
