Closed niksy closed 6 months ago
Hi, thanks for your contribution.
My usual answer for this would be the same as always:
The way I usually approach this is is to wait for a feature to land in the Sublime Text default CSS package (or open a PR there to get things moving). The Sass/SCSS and LESS syntaxes are based off that default syntax, and it makes it easier to sync them all up if a new CSS feature is implemented "upstream" first.
Now, we are currently slightly deviated from the default CSS package because I need to port a pretty massive rewrite. So maybe it wouldn't be so bad to walk out ahead a little bit. But like most Sass users I write some plain vanilla CSS as well from time to time, and I would definitely like to have these media features in that syntax as well. So, even then it makes sense to start with a PR there. If that takes too long I might still be interested in this PR, but I would like a test to go along with the changes.
I think this is already covered in CSS package, but as you said this package already deviated a little bit so it needs special treatment. I can’t check right now since I’m on vacation.
I checked “prefers-color-scheme” in css and it isn’t recognized at all.
Ah, you’re right, I guess I’ve seen something different. I will start with PR on CSS syntax and see the response.
Thanks! I’ll keep an eye on it. I’m in the process of syncing back up with the CSS syntax, but it’s a bit of a project… when that’s done though, I should be able to integrate the new media queries with ease.
Here it is: https://github.com/sublimehq/Packages/pull/2891
@braver it’s merged!
Cool! Thanks!
So, I’m currently rebuilding the Sass syntax based on the current version of the CSS syntax (and improving it along the way, making it more maintainable). It’s quite a bit of a project but it will get done and that will bring all the new CSS features along with it. So, some patience still 😉
A 3.0 beta release is out now, check the readme on how to get the early builds to take advantage of the improvements and help out improving the package before we ship it to the world. In 3.0 we should also be able support your requested features if we don't do so already. Please have a look!
confirmed these are supported in #96
This PR adds support for new media queries features:
prefers-color-scheme
prefers-reduced-motion
any-pointer
andpointer
any-hover
andhover