Skip to content
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

Extra space after scss pseudo classes. #500

Closed
dankmitchell opened this issue Aug 7, 2014 · 11 comments
Closed

Extra space after scss pseudo classes. #500

dankmitchell opened this issue Aug 7, 2014 · 11 comments

Comments

@dankmitchell
Copy link

If you format your scss and have and &:hover for example the format puts a space in between the colon and pseudo class i.e.

a {
color: red;
&:hover {
background: black;
}
}

@gnrlbzik
Copy link

Have same issue.

Bellow code

.column {
    &:nth-child(2n+1) {
         clear: left;
    }
}

brakes, and formatted code looks like so:

.column {
    & :nth-child(2n+1) {
         clear: left;
    }
}

@bertyhell
Copy link

Yes me too. This also happens in less code.

@gnrlbzik
Copy link

Time to fork and dig through i guess ; )

@bitwiseman
Copy link
Member

SCSS - again this is a templating language based on css. The fact that a css beautifier doesn't handle different language correctly should not be a surprise. 😄 This is a common theme for this suite of tools. We will be looking for ways to make able to handle template languages. In the meanwhile, you should fork and if you can suggest a way to push the added functionality back to this tool we'll be happy to review it.

@gnrlbzik
Copy link

@bitwiseman i figured that much 😄

@kevin-heil
Copy link

Same here.
Funny about this is that if you have something before your nested pseudoclass this effect doesn't appear at all.
Screencast that shows this suggestion:
http://youtu.be/VJeQ_smWW48

victorporof/Sublime-HTMLPrettify#154

@gnrlbzik
Copy link

thanks @kevin-heil good to know : ) i wonder if comments will do it.

@kevin-heil
Copy link

Nope, comments will not help here.

@PixelT
Copy link

PixelT commented Sep 14, 2014

+1

@bitwiseman
Copy link
Member

Fixed!
184492f

@bitwiseman bitwiseman added this to the v1.5.3 milestone Oct 2, 2014
@gnrlbzik
Copy link

gnrlbzik commented Oct 2, 2014

thank you @bitwiseman

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants