Indent inside media queries
claviska opened this issue · 2 comments
Hi, I'm using this fork of CSSTidy for DirtyMarkup, as the original was abandoned, doesn't support media queries, etc. So thanks for your work on this project!
Quick feature request for indenting media queries. The current output looks like this:
@media (max-width: 767px) {
h1
font-size: 2em;
}
}
Desired output is:
@media (max-width: 767px) {
h1
font-size: 2em;
}
}
It looks like this would require a new formatter in the template files, or maybe it could be assumed that whatever the indent level is for properties could simply be doubled.
What are your thoughts on this?
As a matter of fact, as you can see in 2b6567a you'll never have what you say as current ouput.
In low compression format output is well indented in media query, whereas in high compression format every selector is on one line, without indentation. I think that makes sense and don't need any fix.
However thanks you issue I saw that in low compression format empty lines in media queries weren't empty, cause also indented and that was a waste.
After updating to the latest version and comparing templates, I realized this was happening because of my custom template file. Apologies for the bad report—I should have checked that first!