SublimeText / Sass

Sass and SCSS syntax for Sublime Text
https://packagecontrol.io/packages/Sass
MIT License
50 stars 8 forks source link

Syntax highlighting for variable definition #99

Closed Monokai closed 5 months ago

Monokai commented 2 years ago

I think there's a general bug in colorization for variables in SCSS that include more than 1 whitespace character between the variable name and the colon character:

$color1: #f00;
$color2 : #f00;
$color3     : #f00;
Screen Shot 2022-08-27 at 14 59 44

This seems to be the case for all variable types (strings, gradients, maps, etc.)

Use case: some people want multiple spaces before the colon character in order to visually line up the code:

$var-one        : #f00;
$var-twenty-one : #0f0;
$var-thirty     : #00f;
braver commented 2 years ago

I've got a branch with a lot of rework to improve and simplify various cases. It should be fixed there now if you're interested in checking that out.

Monokai commented 2 years ago

Thanks. What's the best way of installing that branch in Sublime Text?

braver commented 2 years ago

I usually uninstall the package installed via package control, then check out the git repo into the Packages directory... something like this

git clone --branch simplify git@github.com:braver/SublimeSass.git "~/Library/Application Support/Sublime Text/Packages/Sass"
Monokai commented 2 years ago

Ah yes, that makes sense, I was looking for a way to install it via Package Control somehow.

And the new branch fixes this issue 👍

braver commented 2 years ago

Awesome. Still working out the final kinks, but an official release is coming. I believe package control will keep your checkout up to date with commits on that branch, so you're good for now 👌🏻

braver commented 5 months ago

closed via #96