diff options
Diffstat (limited to '_sass/bourbon/helpers/_radial-positions-parser.scss')
-rw-r--r-- | _sass/bourbon/helpers/_radial-positions-parser.scss | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/_sass/bourbon/helpers/_radial-positions-parser.scss b/_sass/bourbon/helpers/_radial-positions-parser.scss new file mode 100644 index 0000000..3c552ad --- /dev/null +++ b/_sass/bourbon/helpers/_radial-positions-parser.scss @@ -0,0 +1,18 @@ +@function _radial-positions-parser($gradient-pos) { + $shape-size: nth($gradient-pos, 1); + $pos: nth($gradient-pos, 2); + $shape-size-spec: _shape-size-stripper($shape-size); + + $pre-spec: unquote(if($pos, "#{$pos}, ", null)) + unquote(if($shape-size, "#{$shape-size},", null)); + $pos-spec: if($pos, "at #{$pos}", null); + + $spec: "#{$shape-size-spec} #{$pos-spec}"; + + // Add comma + @if ($spec != " ") { + $spec: "#{$spec},"; + } + + @return $pre-spec $spec; +} |