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

CSS syntax parsing bug #115

Open
jkpubsrc opened this issue Feb 16, 2021 · 0 comments
Open

CSS syntax parsing bug #115

jkpubsrc opened this issue Feb 16, 2021 · 0 comments

Comments

@jkpubsrc
Copy link

Hi!

lesscpy fails parsing the following line:

min-height: calc(100vh - 300px);

Apparently lesscpy expects something completely different instead of the 300px. If I replace 300px with a variable parsing succeeds, but CSS synthesis seems to be incorrect here.

NOTE: This syntax above is valid CSS modern web browsers understand. Something like this is extremely useful to define the height of content blocks in HTML in such a way that some footer might still be visible if the page is short. This must be calculated as the height of the window is not known and will change dynamically. A calc(...) will do that within CSS instantly during layout. It's complicated (and unnecessary) to achieve the same functionality using JavaScript.

Recommendation:

  • creating of a test case / multiple test cases
  • fix parsing / fix CSS synthesis

Thanks!

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

1 participant