-
Notifications
You must be signed in to change notification settings - Fork 3
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
Syntax highlight fixes for quoted codes and aliases after keywords #73
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This probably fits into the category of "just be happy it doesn't break" -- but I noticed inconsistency in the highlighing:
- URL system and unquoted code is all brown
- URL system and quoted code has brown system, green
#
, and green code - Alias and unquoted code is all green
- Alias and quoted code has green alias, brown
#
, and brown code
So basically, it's totally different across each of those 4 possible cominations. Did you see this? Do we care?
Alrighty, I was tempted to say we don't care, but really I did care. I think that pattern of mismatched highlighting has actually been around for a long time, but I think I found a pretty easy way to address it. I did two things to get the highlighting to be consistent:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright! These look good to me! Thanks for doing the bonus round as well!
Fixes #72
This PR fixes the issue reported in #72. With the current version of the extension, having a coding with a system that uses an alias and a code that has spaces does not highlight correctly. With this branch, the following rule no longer breaks the syntax highlighting for the rest of the file:
I also made a bonus update to an issue that I saw recently. When using an Alias that starts with
$
after a FSH keyword, it wasn't highlighted. If this shouldn't have been highlighted, I can revert this change. With this branch, the following keyword highlight as expected:I checked and neither of these issues appear on FSH Online because it uses slightly different syntax highlighting.
I also ran an
npm audit fix
and committed those changes, and I had to update the@vscode/test-electron
dependency to get the tests to run again.