Bug #20542 [Com]: PHP CodeSniffer issue on CSS @media

From: Date: Tue, 05 May 2015 19:58:53 +0000
Subject: Bug #20542 [Com]: PHP CodeSniffer issue on CSS @media
References: 1  Groups: php.pear.bugs 
Request: Send a blank email to pear-bugs+get-11269@lists.php.net to get a copy of this message
Edit report at https://pear.php.net/bugs/bug.php?id=20542&edit=1 ID: 20542 Comment by: saneeshkv@gmail.com Reported By: saneeshkv at gmail dot com Summary: PHP CodeSniffer issue on CSS @media Status: Open Type: Bug Package: PHP_CodeSniffer Operating System: Windows Package Version: 2.3.2 PHP Version: 5.5.24 Roadmap Versions: New Comment: if possible please check the following link too. https://www.drupal.org/node/1431428 Previous Comments: ------------------------------------------------------------------------ [2015-05-05 20:55:20] saneesh_1980 So, what should I do? How can I fix it in Squiz/Drupal standard? What are the modifications I have to do? ------------------------------------------------------------------------ [2015-05-05 08:02:51] squiz There are included sniffs that are generating these errors from the Squiz standard. The Drupal standard might just be including them, in which case fixing them in PHPCS will fix them in Drupal. If Drupal has copied the sniffs and modified them, you'll need them to make a fix there as well. ------------------------------------------------------------------------ [2015-05-05 07:59:38] saneesh_1980 Sorry! This issue is not for the standard code sniffers with the PHP_CodeSniffer. This issue is ONLY with the Drupal's code sniffer. I'm not sure I could ask this question here. ------------------------------------------------------------------------ [2015-05-05 07:49:12] saneesh_1980 Description: ------------ For the following CSS class, it shows an error. @media (min-width: 320px) and (max-width: 961px) { .tooltipsrt:hover span.tltp, .tooltipsle:hover span.tltp, .tooltipsbt:hover span.tltp, .tooltipsbt1:hover span.tltp, .tooltipsbt2:hover span.tltp, .tooltipstp:hover span.tltp { visibility: hidden; } } If we give the space after the colon(:) the 'hover' will not work in the page (shown below). For a normal css class the space after the colon is fine, but for @media it should not. Expected result: ---------------- This should be passed by the codeSniffer Actual result: -------------- Style definitions must end with a semicolon Expected 1 space after colon in style definition; 0 found ------------------------------------------------------------------------ -- Edit this bug report at https://pear.php.net/bugs/bug.php?id=20542&edit=1

« previous php.pear.bugs (#11269) next »