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

calc(expr) incorrectly parsed #74

Closed
brbulic opened this issue Nov 10, 2015 · 3 comments
Closed

calc(expr) incorrectly parsed #74

brbulic opened this issue Nov 10, 2015 · 3 comments

Comments

@brbulic
Copy link

brbulic commented Nov 10, 2015

Example CSS

.step-header-brlje > ul.process-bar > li:not(:first-child):after {
  content: '';
  width: calc(100% - 16px);
  position: absolute;
  left: calc(-50% + 6px);
  top: 10px;
  border-top: 2px solid gray;
}

Result CSS:

.step-header-brlje > ul.process-bar > li:not(:first-child):after {
    content: '';
    width: calc(100% = 16px);
    position: absolute;
    left: calc(-50% = 6px);
    top: 10px;
    border-top: 2px solid gray;
}

Obviously the calc expressions are being parsed wrongly (notice the equal signs instead of math operators).

Can you assist ?

@brbulic
Copy link
Author

brbulic commented Nov 10, 2015

Temporary fix is to escape the + and - characters

width: calc(100% \- 16px)

@clarkd
Copy link

clarkd commented Jun 3, 2016

Having the same issue here but the workaround is useful, thanks @brbulic

@T-Hugs
Copy link

T-Hugs commented Apr 6, 2018

This doesn't repro for me. Fixed?

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

No branches or pull requests

4 participants