Sha256: 461c5aecbd76aee44e38234bc829e3033b2af7b429b829b6d45b353d9e25c33c

Contents?: true

Size: 1.97 KB

Versions: 6

Compression:

Stored size: 1.97 KB

Contents

// CSS 3 Mixins

// Add them as you need them. This should let us manage vendor prefixes in one place.


@mixin border-radius($radius) {
  -webkit-border-radius: $radius;
     -moz-border-radius: $radius;
          border-radius: $radius;
}
@mixin box-shadow($shadow) {
  -webkit-box-shadow: $shadow;
     -moz-box-shadow: $shadow;
          box-shadow: $shadow;
}
@mixin translate($x, $y) {
  -webkit-transform: translate($x, $y);
     -moz-transform: translate($x, $y);
       -o-transform: translate($x, $y);
          transform: translate($x, $y);
}

@mixin gradient($from, $to) {
  background-color: $from; // fallback/image non-cover color
  background-image: -moz-linear-gradient($from, $to); // Firefox 3.6+
  background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from($from), to($to)); // Safari 4+, Chrome 1+
  background-image: -webkit-linear-gradient($from, $to); // Safari 5.1+, Chrome 10+
  background-image: -o-linear-gradient($from, $to); // Opera 11.10+
  filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#{$from}', endColorstr='#{$to}',GradientType=0 ); // IE6-9
}

@mixin transition($property, $duration, $function, $delay: 0s) {
  -webkit-transition: ($property $duration $function $delay);
     -moz-transition: ($property $duration $function $delay);
      -ms-transition: ($property $duration $function $delay);
       -o-transition: ($property $duration $function $delay);
          transition: ($property $duration $function $delay);
}

@mixin box-sizing($type) { // Acceptable values are border, content, and padding - content is the default W3C model
  -webkit-box-sizing: $type;
     -moz-box-sizing: $type;
          box-sizing: $type;
}

@mixin appearance($appearance) {
  -webkit-appearance: $appearance;
     -moz-appearance: $appearance;
}

@mixin calc($property, $calc) {
  #{$property}: -webkit-calc(#{$calc});
  #{$property}: calc(#{$calc});
}

@mixin opacity($trans) {
  zoom: 1;
  filter: unquote('alpha(opacity=' + ($trans * 100) + ')');
  opacity: $trans;
}

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
govuk_frontend_toolkit-1.1.0 app/assets/stylesheets/_css3.scss
govuk_frontend_toolkit-1.0.1 app/assets/stylesheets/_css3.scss
govuk_frontend_toolkit-1.0.0 app/assets/stylesheets/_css3.scss
govuk_frontend_toolkit-0.48.0 app/assets/stylesheets/_css3.scss
govuk_frontend_toolkit-0.47.0 app/assets/stylesheets/_css3.scss
govuk_frontend_toolkit-0.46.1 app/assets/stylesheets/_css3.scss