From 20c38d7083b188a70ac78362cc6af4c521a479c3 Mon Sep 17 00:00:00 2001 From: Frans de Jonge Date: Wed, 14 Aug 2019 22:29:28 +0200 Subject: [CI] Run stylelint (#2477) * [CI] Run stylelint Perform some basic CSS sanity checking and style enforcement. I removed vendor prefixed linear-gradient and transform because those are from the IE9 era. With IE11 as a minimum and soon obsolete requirement it doesn't make much sense anymore. * Remove as-link override * Don't require newline after comment * Also apply those newline rules to SCSS * refine opening/closing braces, allow for single-line --- p/themes/Mapco/_mixins.scss | 92 +++++++++++++++++++++++++-------------------- 1 file changed, 52 insertions(+), 40 deletions(-) (limited to 'p/themes/Mapco/_mixins.scss') diff --git a/p/themes/Mapco/_mixins.scss b/p/themes/Mapco/_mixins.scss index 3542ade6b..9dbed6945 100644 --- a/p/themes/Mapco/_mixins.scss +++ b/p/themes/Mapco/_mixins.scss @@ -1,59 +1,71 @@ +/* stylelint-disable property-no-vendor-prefix */ + /* FUNCTIONS */ //animation + @mixin transition($target, $duration, $ease) { - -webkit-transition: $target $duration $ease; - -moz-transition: $target $duration $ease; - -o-transition: $target $duration $ease; - -ms-transition: $target $duration $ease; - transition: $target $duration $ease; + -webkit-transition: $target $duration $ease; + -moz-transition: $target $duration $ease; + -o-transition: $target $duration $ease; + -ms-transition: $target $duration $ease; + transition: $target $duration $ease; } //animation + @mixin animation-delay($delay) { - -webkit-animation-delay: $delay; - /* Safari 4.0 - 8.0 */ - animation-delay: $delay; + -webkit-animation-delay: $delay; + /* Safari 4.0 - 8.0 */ + animation-delay: $delay; } //animation + @mixin animation($animate...) { - $max: length($animate); - $animations: ''; - @for $i from 1 through $max { - $animations: #{$animations + nth($animate, $i)}; - @if $i < $max { - $animations: #{$animations + ", "}; - } - } - -webkit-animation: $animations; - -moz-animation: $animations; - -o-animation: $animations; - -ms-transition: $animations; - animation: $animations; + $max: length($animate); + $animations: ''; + + @for $i from 1 through $max { + $animations: #{$animations + nth($animate, $i)}; + + @if $i < $max { + $animations: #{$animations + ", "}; + } + } + -webkit-animation: $animations; + -moz-animation: $animations; + -o-animation: $animations; + -ms-transition: $animations; + animation: $animations; } //keyframes + @mixin keyframes($animationName) { - @-webkit-keyframes #{$animationName} { - @content; - } - @-moz-keyframes #{$animationName} { - @content; - } - @-o-keyframes #{$animationName} { - @content; - } - @keyframes #{$animationName} { - @content; - } + + @-webkit-keyframes #{$animationName} { + @content; + } + + @-moz-keyframes #{$animationName} { + @content; + } + + @-o-keyframes #{$animationName} { + @content; + } + + @keyframes #{$animationName} { + @content; + } } -@mixin border-radius($radius: 4px){ - -moz-border-radius: $radius; - -webkit-border-radius: $radius; - -ms-border-radius: $radius; - -o-border-radius: $radius; - -khtml-border-radius: $radius; - border-radius: $radius; +@mixin border-radius($radius: 4px) { + -moz-border-radius: $radius; + -webkit-border-radius: $radius; + -ms-border-radius: $radius; + -o-border-radius: $radius; + -khtml-border-radius: $radius; + border-radius: $radius; } -- cgit v1.2.3