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

CSS: support add newline between rules #574

Merged
merged 1 commit into from
Dec 8, 2014

Conversation

numbbbbb
Copy link
Contributor

It's suggested by Google that newline should be added between rules, so I think we should support
that and try to make it.

I added this behavior to both JS and Python with tests. Besides, I added
the new option to README and cli.js.

If I need to modify other files, please let me know.

Thanks!

@numbbbbb
Copy link
Contributor Author

Sorry, this is my first time using CI and mustache, so I tried many times to pass it.

}
],
tests: [
{ input: '.div {}\n.span {}', output: '.div {}{{separator}}.span {}'}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great start, but a few more tests are needed.

@bitwiseman
Copy link
Member

More tests and please squash your commits down to one.

@numbbbbb
Copy link
Contributor Author

I add more tests and squash them, if I have to do other things please let me know, thanks!

@@ -0,0 +1,87 @@
0 info it worked if it ends with ok
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this file.

@numbbbbb
Copy link
Contributor Author

Ok, I'll add more tests, thanks.

It's suggested by
[Google](https://google-styleguide.googlecode.com/svn/trunk/htmlcssguide.xml#CSS_Formatting_Rules)
that newline should be added between rules, so I think we should support
that and try to make it.

I added this behavior to both JS and Python with tests. Besides, I added
the new option to README and cli.js.

If I need to modify other files, please let me know.

Thanks!

complete cli.js

fix bugs in test.py

fix tests

use newLine function

fix python tests

fix tests

use indentLevel instead of nestedLevel

match default js tests

still

Revert "still"

This reverts commit 32797e8.

Find it!

update tests file

add more tests

add test

fix test

fix test

fix test

fix test

fix test

fix test

fix test
@numbbbbb
Copy link
Contributor Author

I hava added more tests, should I do something else?

@numbbbbb numbbbbb closed this Nov 29, 2014
@numbbbbb numbbbbb reopened this Nov 29, 2014
@numbbbbb
Copy link
Contributor Author

Sorry, I click the close button by mistake...

@bitwiseman
Copy link
Member

Thanks for seeing this through. This should sufficiently address #467, I think as well.

bitwiseman added a commit that referenced this pull request Dec 8, 2014
 CSS: support add newline between rules
@bitwiseman bitwiseman merged commit 4e09eb0 into beautifier:master Dec 8, 2014
@bitwiseman bitwiseman added this to the v1.6.0 milestone Dec 8, 2014
@joseluisq
Copy link

Great news !
So I can't wait for the next 1.5.5 version 👍
Congrats 😄 !

@joseluisq
Copy link

I hope the Sass support for the next version..

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

Successfully merging this pull request may close these issues.

None yet

3 participants