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

support added for css variables #1633

Merged
merged 2 commits into from Jan 10, 2021
Merged

support added for css variables #1633

merged 2 commits into from Jan 10, 2021

Conversation

zjeffer
Copy link
Contributor

@zjeffer zjeffer commented Dec 13, 2020

fixes #1060

I went with Name.Variable for the css vars, I hope that's the correct choice.

This works for both declaring variables:

--color-pink: HotPink;

and getting variables through the var() function:

border: 1px solid var(--button-color)

pygments/lexers/css.py Outdated Show resolved Hide resolved
@Anteru Anteru linked an issue Jan 10, 2021 that may be closed by this pull request
@Anteru Anteru added this to the 2.7.4 milestone Jan 10, 2021
@Anteru Anteru added the changelog-update Items which need to get mentioned in the changelog label Jan 10, 2021
@Anteru Anteru merged commit c83fe48 into pygments:master Jan 10, 2021
@Anteru Anteru removed the changelog-update Items which need to get mentioned in the changelog label Jan 12, 2021
@carltongibson
Copy link

Super. Thanks for the quick turnaround!

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

Successfully merging this pull request may close these issues.

Lexer not recognising CSS variables. Support for css variables (aka custom properties)
4 participants