Skip to content

Enhance Python injection syntax via Issue #6 #9

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

cachebag
Copy link

@cachebag cachebag commented Apr 23, 2025

This change improves the TextMate grammar patterns in python.injection.json and adds some explicit checks for comment characters at the start of lines, which should fix #6.

There's also some better handling of white-space around CSS string declarations

E.g.

Screenshot 2025-04-23 at 1 25 54 PM

@rodrigogiraoserrao
Copy link
Contributor

Hey there, thanks for the PR!
I apologise for asking you this, but do you mind making it clearer for me what the exact examples being fixed by this PR are?
I haven't touched this grammar in a looong time and I definitely appreciate your PR, but I can't merge it without making sure it's a step in the right direction :D

Maybe a comparison screenshot (before and after) would help + the specific example of issue 6, that you say this fixes.

Thank you in advance!

@cachebag
Copy link
Author

@rodrigogiraoserrao

No worries! My apologies for not making it more clear. Here's that same code block in #6 before and after for clarity since that was the focus.

Before my changes:
Screenshot 2025-04-26 at 10 18 21 AM

After my changes:
Screenshot 2025-04-26 at 10 16 58 AM

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.

Commented out CSS string breaks syntax highlighting for rest of file
2 participants