[Compass Core] Don't suggest putting some values in quotes unecessarily, and unquote them if the user has.
Closes GH-143. Closes GH-141.
This commit is contained in:
parent
00b437ae8d
commit
ed35a3eb24
@ -6,11 +6,11 @@
|
|||||||
//
|
//
|
||||||
// This yields a linear gradient spanning from bottom to top
|
// This yields a linear gradient spanning from bottom to top
|
||||||
//
|
//
|
||||||
// +linear-gradient(color-stops(white, black), "bottom")
|
// +linear-gradient(color-stops(white, black), bottom)
|
||||||
//
|
//
|
||||||
// This yields a linear gradient spanning from left to right
|
// This yields a linear gradient spanning from left to right
|
||||||
//
|
//
|
||||||
// +linear-gradient(color-stops(white, black), "left")
|
// +linear-gradient(color-stops(white, black), left)
|
||||||
//
|
//
|
||||||
// This yields a linear gradient starting at white passing
|
// This yields a linear gradient starting at white passing
|
||||||
// thru blue at 33% down and then to black
|
// thru blue at 33% down and then to black
|
||||||
@ -24,7 +24,7 @@
|
|||||||
//
|
//
|
||||||
// This yields a linear gradient on top of a background image
|
// This yields a linear gradient on top of a background image
|
||||||
//
|
//
|
||||||
// +linear-gradient(color_stops(white,black), "top", image-url('noise.png'))
|
// +linear-gradient(color_stops(white,black), top, image-url('noise.png'))
|
||||||
// Browsers Supported:
|
// Browsers Supported:
|
||||||
//
|
//
|
||||||
// - Chrome
|
// - Chrome
|
||||||
@ -36,6 +36,7 @@
|
|||||||
// Webkit's gradient api sucks -- hence these backflips:
|
// Webkit's gradient api sucks -- hence these backflips:
|
||||||
$background: unquote("");
|
$background: unquote("");
|
||||||
@if $image { $background : $image + unquote(", "); }
|
@if $image { $background : $image + unquote(", "); }
|
||||||
|
$start: unquote($start);
|
||||||
$end: grad-opposite-position($start);
|
$end: grad-opposite-position($start);
|
||||||
@if $experimental-support-for-webkit {
|
@if $experimental-support-for-webkit {
|
||||||
background-image: #{$background}-webkit-gradient(linear, grad-point($start), grad-point($end), grad-color-stops($color-stops));
|
background-image: #{$background}-webkit-gradient(linear, grad-point($start), grad-point($end), grad-color-stops($color-stops));
|
||||||
@ -53,12 +54,12 @@
|
|||||||
// // Defaults to a centered, 100px radius gradient
|
// // Defaults to a centered, 100px radius gradient
|
||||||
// +radial-gradient(color-stops(#c00, #00c))
|
// +radial-gradient(color-stops(#c00, #00c))
|
||||||
// // 100px radius gradient in the top left corner
|
// // 100px radius gradient in the top left corner
|
||||||
// +radial-gradient(color-stops(#c00, #00c), "top left")
|
// +radial-gradient(color-stops(#c00, #00c), top left)
|
||||||
// // Three colors, ending at 50px and passing thru #fff at 25px
|
// // Three colors, ending at 50px and passing thru #fff at 25px
|
||||||
// +radial-gradient(color-stops(#c00, #fff, #00c 50px))
|
// +radial-gradient(color-stops(#c00, #fff, #00c 50px))
|
||||||
// // a background image on top of the gradient
|
// // a background image on top of the gradient
|
||||||
// // Requires an image with an alpha-layer.
|
// // Requires an image with an alpha-layer.
|
||||||
// +radial-gradient(color_stops(#c00, #fff), "top left", image-url("noise.png")))
|
// +radial-gradient(color_stops(#c00, #fff), top left, image-url("noise.png")))
|
||||||
// Browsers Supported:
|
// Browsers Supported:
|
||||||
//
|
//
|
||||||
// - Chrome
|
// - Chrome
|
||||||
@ -66,6 +67,7 @@
|
|||||||
// - Firefox 3.6
|
// - Firefox 3.6
|
||||||
|
|
||||||
@mixin radial-gradient($color-stops, $center-position: center center, $image: false) {
|
@mixin radial-gradient($color-stops, $center-position: center center, $image: false) {
|
||||||
|
$center-position: unquote($center-position);
|
||||||
$end-pos: grad-end-position($color-stops, true);
|
$end-pos: grad-end-position($color-stops, true);
|
||||||
$background: unquote("");
|
$background: unquote("");
|
||||||
@if $image { $background: $image + unquote(", "); }
|
@if $image { $background: $image + unquote(", "); }
|
||||||
|
@ -40,7 +40,7 @@ $default-transition-delay: false !default;
|
|||||||
// * these durations will affect the properties in the same list position
|
// * these durations will affect the properties in the same list position
|
||||||
|
|
||||||
@mixin transition-duration($duration: $default-transition-duration) {
|
@mixin transition-duration($duration: $default-transition-duration) {
|
||||||
@include experimental(transition-duration, $duration,
|
@include experimental(transition-duration, unquote($duration),
|
||||||
-moz, -webkit, -o, not -ms, not -khtml, official
|
-moz, -webkit, -o, not -ms, not -khtml, official
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -52,7 +52,7 @@ $default-transition-delay: false !default;
|
|||||||
// * These functions will effect the properties in the same list position
|
// * These functions will effect the properties in the same list position
|
||||||
|
|
||||||
@mixin transition-timing-function($function: $default-transition-function) {
|
@mixin transition-timing-function($function: $default-transition-function) {
|
||||||
@include experimental(transition-timing-function, $function,
|
@include experimental(transition-timing-function, unquote($function),
|
||||||
-moz, -webkit, -o, not -ms, not -khtml, official
|
-moz, -webkit, -o, not -ms, not -khtml, official
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -63,7 +63,7 @@ $default-transition-delay: false !default;
|
|||||||
// * these delays will effect the properties in the same list position
|
// * these delays will effect the properties in the same list position
|
||||||
|
|
||||||
@mixin transition-delay($delay: $default-transition-delay) {
|
@mixin transition-delay($delay: $default-transition-delay) {
|
||||||
@include experimental(transition-delay, $delay,
|
@include experimental(transition-delay, unquote($delay),
|
||||||
-moz, -webkit, -o, not -ms, not -khtml, official
|
-moz, -webkit, -o, not -ms, not -khtml, official
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user