css - Using Less, CSS3 calc() doesn't work correctly -


when use calc(100% + 20px) directly in chromes , firefox' inspector works fine , shown.

however when insert less file gets converted 120%. doing wrong?

i use less

imho it's better mention in question because less try process maths including 100% + 20px.

you either set strict math on:

lessc -sm=on lessc --strict-math=on 

or use tilde-quote ~"100% + 20px" in order prevent statement being processed less.

for instance:

.class {     padding-left: calc(~"100% + 20px"); } 

Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -