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

Fix Less test for function-calc-no-invalid #4534

Closed
wants to merge 1 commit into from
Closed

Fix Less test for function-calc-no-invalid #4534

wants to merge 1 commit into from

Conversation

LolliDepp
Copy link

@LolliDepp LolliDepp commented Jan 9, 2020

Which issue, if any, is this issue related to?

This changes 2 test cases to highlight the issues explained on #4533

Is there anything in the PR that needs further explanation?

The syntax which was replaced and is now gone I don't think has any value inside of that test file.
It's not related to that rule at all.

The syntax that was being allowed was actually just plain wrong, but not for the reason being reported.
The issue is more along the lines of "You cannot directly do variable interpolations in the value section of CSS properties"

See LESS docs... http://lesscss.org/features/#variables-feature

allowed to interpolate in properties:

@{my-var}: 10px

allowed to interpolate in class names:

.@{my-var} { 
  width: 10px 
}

allowed to interpolate in strings:

background: url("@{base-url}-red.png");

@LolliDepp LolliDepp changed the title fix test cases arguments to highlight issues with rule Fix test cases arguments to highlight issues with rule (will add test failures) Jan 9, 2020
@jeddy3 jeddy3 changed the title Fix test cases arguments to highlight issues with rule (will add test failures) Fix Less test for function-calc-no-invalid Jan 12, 2020
@jeddy3
Copy link
Member

jeddy3 commented Jan 12, 2020

@LolliDepp Thank you for fixing the syntax of these tests

The issue is more along the lines of "You cannot directly do variable interpolations in the value section of CSS properties"

Thank you also for breaking down the valid usage of interpolation in Less so clearly.

I proposed a fix in #4533 that should address the now failing tests in this PR.

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

Successfully merging this pull request may close these issues.

None yet

3 participants