Skip to content

[css mode] teach it about CSS variables#3064

Closed
KwanEsq wants to merge 1 commit intocodemirror:masterfrom
KwanEsq:css-variables
Closed

[css mode] teach it about CSS variables#3064
KwanEsq wants to merge 1 commit intocodemirror:masterfrom
KwanEsq:css-variables

Conversation

@KwanEsq
Copy link
Copy Markdown
Contributor

@KwanEsq KwanEsq commented Feb 2, 2015

Currently CSS variables e.g. --main-color not only fail to highlight properly, but also screw up the parsing later in the document, so auto-indenting fails. (It indents an extra step after using a variable in var(), and sometimes un-indents a step after declaring the variable).
This fixes both of these problems by correctly parsing occurrences of --variable-name

Tests run locally, all pass.

marijnh added a commit that referenced this pull request Feb 2, 2015
@marijnh
Copy link
Copy Markdown
Member

marijnh commented Feb 2, 2015

Wonderful. Merged as 752c785, and test added in 9419164 (consider including a test in the pull req in the future).

@marijnh marijnh closed this Feb 2, 2015
@KwanEsq
Copy link
Copy Markdown
Contributor Author

KwanEsq commented Feb 2, 2015

Great, thanks! Apologies for the lack of a test, I didn't immediately grok your test syntax, and figured if you wanted one you would let me know. I'm attempting to write one for #3065, though not sure if I'm doing it correctly.

@KwanEsq KwanEsq deleted the css-variables branch June 20, 2018 01:29
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.

2 participants