Skip to content

Commit

Permalink
v0.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
drublic committed Aug 30, 2013
1 parent 13abb09 commit 9ceb693
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 52 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

### HEAD

### 0.4.1 - 30.08.2013

* Remove `-o-` prefix for transforms, transition and tab-size (#17)
* Remove `-o-` and `-moz-` prefixes of linear gradients (#17)

Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sass-mixins",
"version": "0.4.0",
"version": "0.4.1",
"main": "mixins.scss",
"author": "Hans Christian Reinl",
"ignore": [
Expand Down
29 changes: 2 additions & 27 deletions mixins.scss
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,6 @@
* background-color: <fallback>;
* background-image: -webkit-gradient(linear, <direction - old converted>, from(<from>), to(<to>));
* background-image: -webkit-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: -moz-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: -o-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: linear-gradient(<direction>, <from>, <to>);
*
* @example
Expand All @@ -260,9 +258,7 @@
// Cross-browser linear-gradients
background-image: -webkit-gradient(linear, unquote(nth($directions, 2)), from($from), to($to)); // Android 2.1-3.0
background-image: -webkit-linear-gradient(unquote(nth($directions, 1)), $from, $to);
background-image: -moz-linear-gradient(unquote(nth($directions, 1)), $from, $to);
background-image: -o-linear-gradient(unquote(nth($directions, 1)), $from, $to);
background-image: linear-gradient(unquote($direction), $from, $to);
background-image: linear-gradient(unquote($direction), $from, $to);
}

/**
Expand All @@ -278,7 +274,7 @@
/*
* A function for prefixing gradients
*
* @param mode {'webkit-old'|'webkit'|'moz'|'o'|''}
* @param mode {'webkit-old'|'webkit'|''}
* @param gradient
* @returns
* -<mode>-linear-gradient(<gradient>);
Expand Down Expand Up @@ -351,16 +347,12 @@
@if (nth($background, 1) == 'linear-gradient') {
$combined-background-webkit-old: append($combined-background-webkit-old, prefixed-gradient('webkit-old', $background), comma);
$combined-background-webkit: append($combined-background-webkit, prefixed-gradient('webkit', $background), comma);
$combined-background-moz: append($combined-background-moz, prefixed-gradient('moz', $background), comma);
$combined-background-o: append($combined-background-o, prefixed-gradient('o', $background), comma);
$combined-background: append($combined-background, prefixed-gradient('', $background), comma);

// Nothing to do for non-gradients
} @else {
$combined-background-webkit-old: append($combined-background-webkit-old, $background, comma);
$combined-background-webkit: append($combined-background-webkit, $background, comma);
$combined-background-moz: append($combined-background-moz, $background, comma);
$combined-background-o: append($combined-background-o, $background, comma);
$combined-background: append($combined-background, $background, comma);
}

Expand All @@ -371,8 +363,6 @@
} @else if (type-of($background) == string) {
$combined-background-webkit-old: append($combined-background-webkit-old, $background, space);
$combined-background-webkit: append($combined-background-webkit, $background, comma);
$combined-background-moz: append($combined-background-moz, $background, comma);
$combined-background-o: append($combined-background-o, $background, comma);
$combined-background: append($combined-background, $background, comma);
}
}
Expand All @@ -381,17 +371,13 @@
@if $end != '' {
$combined-background-webkit-old: append($combined-background-webkit-old, $end, space);
$combined-background-webkit: append($combined-background-webkit, $end, comma);
$combined-background-moz: append($combined-background-moz, $end, comma);
$combined-background-o: append($combined-background-o, $end, comma);
$combined-background: append($combined-background, $end, comma);
}

// Only print all prefixed versions if necessary
@if ($combined-background != $combined-background-webkit) {
background: unquote($combined-background-webkit-old);
background: unquote($combined-background-webkit);
background: unquote($combined-background-moz);
background: unquote($combined-background-o);
background: unquote($combined-background);
} @else {
background: unquote($combined-background);
Expand All @@ -412,8 +398,6 @@
* @param stops {list}
* @returns
* background-image: -webkit-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: -moz-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: -o-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: linear-gradient(to bottom, <stops[1]>, <stops[2]>, ..., <stops[n]>);
*
* @example
Expand Down Expand Up @@ -467,8 +451,6 @@
}

background-image: -webkit-linear-gradient(unquote($pos), $gradient);
background-image: -moz-linear-gradient(unquote($pos), $gradient);
background-image: -o-linear-gradient(unquote($pos), $gradient);
background-image: unquote('linear-gradient(#{$pos_newsyntax}, #{$gradient})');
}

Expand Down Expand Up @@ -564,7 +546,6 @@
* @default 4
* @returns
* -moz-tab-size: <value>;
* -o-tab-size: <value>;
* tab-size: <value>;
*
* @example
Expand All @@ -590,8 +571,6 @@
* @param values
* @returns
* -webkit-transform: <values>;
* -moz-transform: <values>;
* -o-transform: <values>;
* -ms-transform: <values>;
* transform: <values>;
*
Expand All @@ -602,7 +581,6 @@
*/
@mixin x-transform ($values) {
-webkit-transform: $values; // Chrome, Safari, iOS Safari, Android Stock
-o-transform: $values; // Opera 12
-ms-transform: $values; // IE9
transform: $values;
}
Expand All @@ -619,8 +597,6 @@
* @param values
* @returns
* -webkit-transition: <values>;
* -moz-transition: <values>;
* -o-transition: <values>;
* transition: <values>;
*
* @example
Expand All @@ -630,7 +606,6 @@
*/
@mixin x-transition ($values) {
-webkit-transition: $values;
-o-transition: $values;
transition: $values;
}

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "sass-mixins",
"title": "Sass-Mixins",
"description": "Some Sass-Mixins to use in your project",
"version": "0.4.0",
"version": "0.4.1",
"homepage": "https://github.com/drublic/Sass-Mixins",
"author": {
"name": "Hans Christian Reinl",
Expand Down
24 changes: 1 addition & 23 deletions tests/css/main.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
@charset "UTF-8";
/**
* @description
* Generates keyframe animations
Expand Down Expand Up @@ -141,8 +140,6 @@
* background-color: <fallback>;
* background-image: -webkit-gradient(linear, <direction - old converted>, from(<from>), to(<to>));
* background-image: -webkit-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: -moz-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: -o-linear-gradient(<direction - converted>, <from>, <to>);
* background-image: linear-gradient(<direction>, <from>, <to>);
*
* @example
Expand All @@ -165,7 +162,7 @@
/*
* A function for prefixing gradients
*
* @param mode {'webkit-old'|'webkit'|'moz'|'o'|''}
* @param mode {'webkit-old'|'webkit'|''}
* @param gradient
* @returns
* -<mode>-linear-gradient(<gradient>);
Expand Down Expand Up @@ -200,8 +197,6 @@
* @param stops {list}
* @returns
* background-image: -webkit-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: -moz-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: -o-linear-gradient(top, <stops[1]>, <stops[2]>, ..., <stops[n]>);
* background-image: linear-gradient(to bottom, <stops[1]>, <stops[2]>, ..., <stops[n]>);
*
* @example
Expand Down Expand Up @@ -273,7 +268,6 @@
* @default 4
* @returns
* -moz-tab-size: <value>;
* -o-tab-size: <value>;
* tab-size: <value>;
*
* @example
Expand All @@ -293,8 +287,6 @@
* @param values
* @returns
* -webkit-transform: <values>;
* -moz-transform: <values>;
* -o-transform: <values>;
* -ms-transform: <values>;
* transform: <values>;
*
Expand All @@ -315,8 +307,6 @@
* @param values
* @returns
* -webkit-transition: <values>;
* -moz-transition: <values>;
* -o-transition: <values>;
* transition: <values>;
*
* @example
Expand Down Expand Up @@ -428,26 +418,20 @@ html {
background-color: #cccccc;
background-image: -webkit-gradient(linear, left top, left bottom, from(#dddddd), to(#bbbbbb));
background-image: -webkit-linear-gradient(top, #dddddd, #bbbbbb);
background-image: -moz-linear-gradient(top, #dddddd, #bbbbbb);
background-image: -o-linear-gradient(top, #dddddd, #bbbbbb);
background-image: linear-gradient(to bottom, #dddddd, #bbbbbb);
}

.linear-gradient-2 {
background-color: #dddddd;
background-image: -webkit-gradient(linear, top left, bottom right, from(#dddddd), to(#555555));
background-image: -webkit-linear-gradient(left, #dddddd, #555555);
background-image: -moz-linear-gradient(left, #dddddd, #555555);
background-image: -o-linear-gradient(left, #dddddd, #555555);
background-image: linear-gradient(to right, #dddddd, #555555);
}

.linear-gradient-3 {
background-color: #dddddd;
background-image: -webkit-gradient(linear, mod(405deg, 360deg), from(white), to(black));
background-image: -webkit-linear-gradient(mod(405deg, 360deg), white, black);
background-image: -moz-linear-gradient(mod(405deg, 360deg), white, black);
background-image: -o-linear-gradient(mod(405deg, 360deg), white, black);
background-image: linear-gradient(45deg, white, black);
padding: 50px 0;
}
Expand All @@ -461,16 +445,12 @@ html {
background-image: linear-gradient(to bottom, red 0%, green 50%, blue 100%);
*/
background-image: -webkit-linear-gradient(top, #aaffff 0%, #ffaaff 20%, #ffffaa 40%, #aaaaff 60%, #ffaaaa 80%, #aaaaaa 100%);
background-image: -moz-linear-gradient(top, #aaffff 0%, #ffaaff 20%, #ffffaa 40%, #aaaaff 60%, #ffaaaa 80%, #aaaaaa 100%);
background-image: -o-linear-gradient(top, #aaffff 0%, #ffaaff 20%, #ffffaa 40%, #aaaaff 60%, #ffaaaa 80%, #aaaaaa 100%);
background-image: linear-gradient(to bottom, #aaffff 0%, #ffaaff 20%, #ffffaa 40%, #aaaaff 60%, #ffaaaa 80%, #aaaaaa 100%);
}

.multiple-backgrounds {
background: url("../img/html5_logo.png") top right no-repeat -webkit-linear-gradient(left top, left bottom, #aaaaaa, #dddddd) rgba(0, 0, 0, 0.3);
background: url("../img/html5_logo.png") top right no-repeat, -webkit-linear-gradient(top, #aaaaaa, #dddddd), rgba(0, 0, 0, 0.3);
background: url("../img/html5_logo.png") top right no-repeat, -moz-linear-gradient(top, #aaaaaa, #dddddd), rgba(0, 0, 0, 0.3);
background: url("../img/html5_logo.png") top right no-repeat, -o-linear-gradient(top, #aaaaaa, #dddddd), rgba(0, 0, 0, 0.3);
background: url("../img/html5_logo.png") top right no-repeat, linear-gradient(to bottom, #aaaaaa, #dddddd), rgba(0, 0, 0, 0.3);
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
Expand Down Expand Up @@ -512,14 +492,12 @@ html {

.transform {
-webkit-transform: rotate(1deg);
-o-transform: rotate(1deg);
-ms-transform: rotate(1deg);
transform: rotate(1deg);
}

.transition {
-webkit-transition: background 0.3s ease-in;
-o-transition: background 0.3s ease-in;
transition: background 0.3s ease-in;
}
.transition:hover {
Expand Down

0 comments on commit 9ceb693

Please sign in to comment.