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 lexer: Add more property names? #2113

Closed
voussoir opened this issue Apr 15, 2022 · 2 comments
Closed

CSS lexer: Add more property names? #2113

voussoir opened this issue Apr 15, 2022 · 2 comments
Assignees
Milestone

Comments

@voussoir
Copy link

Hi, thanks for this great library.

Today, pointer-events caught my attention as Pygments does not highlight it. The list of recognized property names is here with 372 entries from the list at w3.org.

I checked the CSS package for Sublime Text and found these 503 entries. Of course, I'm not suggesting that Sublime is the source of truth here, it's simply a convenient point of reference for me. I'd like to understand the discrepancy between these lists. pointer-events is fully cross compatible according to MDN and presumably many other widely used names are on the list of differences.

inset is on w3 as Working Draft but absent from Pygments.

max-lines is on w3 as Working Draft but present in Pygments.

Could more of these names be added to Pygments's lexer, or are they excluded for a reason?

Thank you.

@amitkummer
Copy link
Contributor

These are definitely needed to be added to the lexer.

It also looks like some properties are located in a different list here, which could also be a part of this potential refactoring.

@birkenfeld
Copy link
Member

I agree. Best case would be an automatic way to update the list of properties from a web source, like we do for the builtins of several other languages (see the various _xxx_builtins.py modules)

@Anteru Anteru added this to the 2.12.0 milestone Apr 24, 2022
@Anteru Anteru closed this as completed in 94b4c6b Apr 24, 2022
@Anteru Anteru self-assigned this Apr 24, 2022
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