Bug #19283 [Asn->Fbk]: CSS @media rules cause false positives
| From: | gsherwood at squiz dot net | Date: | Mon, 13 Feb 2012 06:05:03 +0000 |
| Subject: | Bug #19283 [Asn->Fbk]: CSS @media rules cause false positives | ||
| References: | 1 | Groups: | php.pear.bugs |
| Request: | Send a blank email to pear-bugs+get-8267@lists.php.net to get a copy of this message | ||
Edit report at https://pear.php.net/bugs/bug.php?id=19283&edit=1
ID: 19283
Updated by: gsherwood@squiz.net
Reported By: klaus dot purer at gmail dot com
Summary: CSS @media rules cause false positives
-Status: Assigned
+Status: Feedback
Type: Bug
Package: PHP_CodeSniffer
Operating System: Ubuntu 11.10
Package Version: SVN
PHP Version: 5.3.9
Assigned To: squiz
Roadmap Versions:
New Comment:
-Status: Assigned
+Status: Feedback
I couldn't use your patch directly because here was a typo in the
indentation sniff
(wrong var, minor thing), it didn't quite work with multiple classes in
the nested area
and I actually wanted to enforce spacing around the braces of a nesting
class
definition anyway. So I've updated the sniffs you identified and another
as well. THe
git repo has been updated.
Relevant commits:
https://github.com/squizlabs/PHP_CodeSniffer/commit/f09151959e8d0bdb93b50b8f1
04f1945a303213f
https://github.com/squizlabs/PHP_CodeSniffer/commit/d18cd88150e8a80400bae36d2
12cb1795c612f8f
Hopefully that fixes the problems with nested classes. Let me know if
you find more
and thanks for all your help so far.
Previous Comments:
------------------------------------------------------------------------
[2012-02-10 15:37:34] klausi
Added #patch
bug:19283;patch:phpcs-nested-followup.patch;revision:1328888254;.
------------------------------------------------------------------------
[2012-02-10 15:37:05] klausi
-Status: Closed
+Status: Open
Here is a followup patch that addresses some white space issues in the
sniffs. I think a nested rule definition should not be treated as class
definition. Therefore blank lines should be allowed in it.
CSS Test sample:
--------------------
@media screen and (max-device-width: 769px) {
header #logo img {
max-width: 100%;
}
.inner {
min-width: 1281px;
max-width: 1500px;
}
}
------------------------------------------------------------------------
[2012-02-10 00:56:42] squiz
-Status: Assigned
+Status: Closed
Fixed in Git:
https://github.com/squizlabs/PHP_CodeSniffer/commit/440d99d022314ae187b3a39f2
826b129a6d97806
Thanks again for another great patch.
------------------------------------------------------------------------
[2012-02-10 00:54:37] squiz
-Summary: CSS @media rules cause flase positives
+Summary: CSS @media rules cause false positives
------------------------------------------------------------------------
[2012-02-10 00:54:23] squiz
-Summary: CSS @media rules
+Summary: CSS @media rules cause flase positives
-Assigned To:
+Assigned To: squiz
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://pear.php.net/bugs/bug.php?id=19283
--
Edit this bug report at https://pear.php.net/bugs/bug.php?id=19283&edit=1