Sha256: 68c189b283274ccf613cc24bbc1f4c816fb944b34ca35b19b5b35961a024e273

Contents?: true

Size: 1.36 KB

Versions: 47

Compression:

Stored size: 1.36 KB

Contents

// Render Deprecated Webkit Gradient - Linear || Radial
//************************************************************************//
@function _deprecated-webkit-gradient($type,
                                     $deprecated-pos1, $deprecated-pos2,
                                     $full,
                                     $deprecated-radius1: false, $deprecated-radius2: false) {
  $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 $gradient != null {
      @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, $deprecated-pos1, $deprecated-radius1, $deprecated-pos2, $deprecated-radius2, $gradient-list);
  }
  @else if $type == linear {
    $gradient: -webkit-gradient(linear, $deprecated-pos1, $deprecated-pos2, $gradient-list);
  }
  @return $gradient;
}

Version data entries

47 entries across 47 versions & 9 rubygems

Version Path
daiblogs-0.2.1 _sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.2.0 _sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.1.5 _sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.1.4 _sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.1.2 assets/_sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.1.1 assets/_sass/bourbon/helpers/_deprecated-webkit-gradient.scss
daiblogs-0.1.0 assets/_sass/bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.1.4 app/assets/stylesheets/bourbon/helpers/_deprecated-webkit-gradient.scss
stump-cli-0.1.3 lib/wp/wp-content/themes/stump/assets/vendor/manhattan/bourbon/helpers/_deprecated-webkit-gradient.scss
stump-cli-0.1.2 lib/wp/wp-content/themes/stump/assets/vendor/manhattan/bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.1.3 app/assets/stylesheets/bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.1.2 app/assets/stylesheets/bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.1.1 app/assets/stylesheets/bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.0.2 bourbon/helpers/_deprecated-webkit-gradient.scss
moovui-0.0.1 bourbon/helpers/_deprecated-webkit-gradient.scss
stump-cli-0.1.1 lib/wp/wp-content/themes/stump/assets/vendor/manhattan/bourbon/helpers/_deprecated-webkit-gradient.scss
blogelator-0.2.5 vendor/assets/stylesheets/blogelator/bourbon/helpers/_deprecated-webkit-gradient.scss
blocky-0.0.11 vendor/assets/stylesheets/blocky/bourbon/helpers/_deprecated-webkit-gradient.scss
blogelator-0.2.4 vendor/assets/stylesheets/blogelator/bourbon/helpers/_deprecated-webkit-gradient.scss
blocky-0.0.10 vendor/assets/stylesheets/blocky/bourbon/helpers/_deprecated-webkit-gradient.scss