Sass has an if function now. removing compass's version.
This commit is contained in:
parent
b17450e5e2
commit
6e30099473
@ -54,7 +54,7 @@ $default-box-shadow-inset : false !default;
|
|||||||
}
|
}
|
||||||
@else {
|
@else {
|
||||||
@if $shadow-1 == default {
|
@if $shadow-1 == default {
|
||||||
$shadow-1 : -compass-space-list(compact(if($default-box-shadow-inset, inset), $default-box-shadow-h-offset, $default-box-shadow-v-offset, $default-box-shadow-blur, $default-box-shadow-spread, $default-box-shadow-color));
|
$shadow-1 : -compass-space-list(compact(if($default-box-shadow-inset, inset, false), $default-box-shadow-h-offset, $default-box-shadow-v-offset, $default-box-shadow-blur, $default-box-shadow-spread, $default-box-shadow-color));
|
||||||
}
|
}
|
||||||
$shadow : compact($shadow-1, $shadow-2, $shadow-3, $shadow-4, $shadow-5, $shadow-6, $shadow-7, $shadow-8, $shadow-9, $shadow-10);
|
$shadow : compact($shadow-1, $shadow-2, $shadow-3, $shadow-4, $shadow-5, $shadow-6, $shadow-7, $shadow-8, $shadow-9, $shadow-10);
|
||||||
@include experimental(box-shadow, $shadow,
|
@include experimental(box-shadow, $shadow,
|
||||||
|
@ -110,7 +110,7 @@ $default-skew-y : 5deg !default;
|
|||||||
$origin-x: $default-origin-x,
|
$origin-x: $default-origin-x,
|
||||||
$origin-y: $default-origin-y,
|
$origin-y: $default-origin-y,
|
||||||
$origin-z: false,
|
$origin-z: false,
|
||||||
$only3d: if($origin-z)
|
$only3d: if($origin-z, true, false)
|
||||||
) {
|
) {
|
||||||
$origin: unquote('');
|
$origin: unquote('');
|
||||||
@if $origin-x or $origin-y or $origin-z {
|
@if $origin-x or $origin-y or $origin-z {
|
||||||
|
@ -2,7 +2,7 @@ module Compass::SassExtensions::Functions
|
|||||||
end
|
end
|
||||||
|
|
||||||
%w(
|
%w(
|
||||||
selectors enumerate urls display if
|
selectors enumerate urls display
|
||||||
inline_image image_size constants gradient_support
|
inline_image image_size constants gradient_support
|
||||||
font_files lists colors trig
|
font_files lists colors trig
|
||||||
).each do |func|
|
).each do |func|
|
||||||
@ -22,7 +22,6 @@ module Sass::Script::Functions
|
|||||||
include Compass::SassExtensions::Functions::Lists
|
include Compass::SassExtensions::Functions::Lists
|
||||||
include Compass::SassExtensions::Functions::Colors
|
include Compass::SassExtensions::Functions::Colors
|
||||||
include Compass::SassExtensions::Functions::Trig
|
include Compass::SassExtensions::Functions::Trig
|
||||||
include Compass::SassExtensions::Functions::If
|
|
||||||
end
|
end
|
||||||
|
|
||||||
# Wierd that this has to be re-included to pick up sub-modules. Ruby bug?
|
# Wierd that this has to be re-included to pick up sub-modules. Ruby bug?
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
module Compass::SassExtensions::Functions::If
|
|
||||||
def if(truth, if_true = nil, if_false = nil)
|
|
||||||
if truth.to_bool
|
|
||||||
if_true || Sass::Script::Bool.new(true)
|
|
||||||
else
|
|
||||||
if_false || Sass::Script::Bool.new(false)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
Loading…
Reference in New Issue
Block a user