-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Inconsistent --strict-math
handling of certain properties (hardcoded font
etc.)
#1627
Comments
Sounds like strict maths is on? If it is you have to add parentheses around If its not that please give more repro steps and exactly what output or
|
No, strict math was not on. The Code is still producing same result. The problem was with ceil as well but I have changed to make it work. Below code is not calculating. Here the code is not calculating:
Output in last media query:
Just checked in less2css.org. Above output is coming there as well w/o strict math. |
@satya61229, see my answer here. |
Got it. It can be the case. Checked again in less2css.org and it work when changed to font-size from font. Accepted as right answer there. Thanks. |
@lukeapage I know satya61229 closed his own issue here, but I'm not sure that the "issue" is actually resolved. The fact that a function like
I have not looked to see what other discussions you have had about
However, that might be pushing it. Of course, all the above would require parenthesis if |
For my purpose, working with LESS, it is resolved as I found a way to work. but from LESS own stability I agree with @scottgit . So, I am opening it. Hope you can close it later. |
You are right, we switch on the option inside font declarationa but we should actually switch it off again for functions. |
--strict-math
handling of certain properties (hardcoded font
etc.)
Merging to #1880 (since this one is impossible to "fix" w/o breaking a lot of things anyway). |
Some magic is happening in LESS. I used
ceil(@font-size-base * 1.25);
.. .
...
ceil(@font-size-base * 1.25);
First ceil was working but not the 2nd one. I was working with prepros downloaded recently. I checked in less2css.org there also same result. Now, it is working on less2css.
Another, issue was with this simple line of code:
@font-size-base * 1.25;
This was also used two times in my less. One for tablet and another for desktop with different number. First one was giving calculated number but another one was giving:
0.6em * 1.5; instead of calculated value.
I put the code here using which I was trying ceil and other:
http://stackoverflow.com/questions/19705791/why-this-less-css-is-failing
Also, "1em" with quote was coming whereas expected output was 1em.
The text was updated successfully, but these errors were encountered: