Sha256: f4b6687b4a74b571e9985fb201da80e0b01832b1f0ef0581df8957a563e6d0c6

Contents?: true

Size: 1.09 KB

Versions: 11

Compression:

Stored size: 1.09 KB

Contents

// Render Deprecated Webkit Gradient - Linear || Radial
//************************************************************************//
@function deprecated-webkit-gradient($type, $full) {
  $gradient-list: ();
  $gradient: false;
  $full-length: length($full);
  $percentage: false;
  $gradient-type: $type;

  @for $i from 1 through $full-length {
    $gradient: nth($full, $i);

    @if length($gradient) == 2 {
      $color-stop: color-stop(nth($gradient, 2), nth($gradient, 1));
      $gradient-list: join($gradient-list, $color-stop, comma);
    }
    @else {
      @if $i == $full-length {
        $percentage: 100%;
      }
      @else {
        $percentage: ($i - 1) * (100 / ($full-length - 1)) + "%";
      }
      $color-stop: color-stop(unquote($percentage), $gradient);
      $gradient-list: join($gradient-list, $color-stop, comma);
    }
  }

  @if $type == radial {
    $gradient: -webkit-gradient(radial, center center, 0, center center, 460, $gradient-list);
  }
  @else if $type == linear {
    $gradient: -webkit-gradient(linear, left top, left bottom, $gradient-list);
  }
  @return $gradient;
}

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
app_sleuth-0.0.1.pre lib/app_sleuth/server/assets/sass/mixins/functions/_deprecated-webkit-gradient.scss
bourbon-1.4.0 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.6 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.5 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.4 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.3 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.2 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.3.0 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.2.0 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.1.0 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss
bourbon-1.0.4 app/assets/stylesheets/functions/_deprecated-webkit-gradient.scss