Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not operator matches too broadly #873

Closed
robbi5 opened this issue Feb 3, 2015 · 5 comments · Fixed by #903
Closed

not operator matches too broadly #873

robbi5 opened this issue Feb 3, 2015 · 5 comments · Fixed by #903

Comments

@robbi5
Copy link

robbi5 commented Feb 3, 2015

Hi,
not in declarations gets converted into false, even when other characters are appended.

Example:

div {
  foo: note; }

div {
  foo: note 1; }

Expected output:

div {
  foo: note; }

div {
  foo: note 1; }

Actual output:

div {
  foo: note; }

div {
  foo: false 1; }

(Our use case: We have a list of icons, with icons named like "icon-note", "icon-guitar", ...)

@rawalter21
Copy link

Below is another example of this problem:

@mixin test($var) {
    @debug "Value is #{$var}";
}

@include test(notFalse);

The output of the debug will be "Value is false" when it should be "Value is notFalse"

@xzyfer
Copy link
Contributor

xzyfer commented Feb 3, 2015

@robbi5 this case is fix on master and will be 3.2.

@rawalter21 this appears to still be an error. Can you please create a sass-spec? Here's an example of a good sass-spec PR sass/sass-spec#239

@satya164
Copy link

satya164 commented Feb 4, 2015

Similar issue here. I have something like,

$settings: (general, profile, notification);

@each $setting in $settings {
    &.list-item-#{$setting}-settings { background-image: url(../../img/client/icons/#{$setting}-settings.svg); }
}

In the output, I get "false" instead of "notification".

I tried with other strings which start with "not", and I get the same result.

@xzyfer
Copy link
Contributor

xzyfer commented Feb 15, 2015

Spec added sass/sass-spec#255

@xzyfer
Copy link
Contributor

xzyfer commented Feb 22, 2015

This is fixed and will be in 3.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants