RamseyInHouse/scut

Q: variables passed to scut-coordinates with negative sign

Closed this issue · 1 comments

Hi @davidtheclark ,

This is probably not an issue with scut itself but I was hoping you could provide some clarification.

I have a $gutter variable of 16px, and I want to pass its negative value to scut-absolute, which in turn uses scut-coordinates, like so:

@include scut-absolute(n n n -$gutter)

Unfortunately it yields the following error:

Error: index out of bounds for `nth($list, $n)`
        on line 81 of src/css/vendor/scut/_scut.scss
>>   $left: nth($coordinates, 4);
   ---------^

This works: @include scut-absolute(n n n $gutter*-1)

Is it because it's interpreting the third n and -$gutter as the third argument, trying to evaluate it as n - $gutter ? Is there another syntax which could work, besides $gutter*-1?

Thanks for any help you can provide!