mirror of
https://github.com/pure-css/pure
synced 2024-12-21 02:25:54 +01:00
Merge pull request #65 from ericf/csslint
Add CSSLint and `grunt test` task to lint CSS in the src/ dir
This commit is contained in:
commit
6a2a050fbd
5
.csslintrc
Normal file
5
.csslintrc
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"box-sizing" : false,
|
||||
"display-property-grouping": false,
|
||||
"star-property-hack" : false
|
||||
}
|
22
Gruntfile.js
22
Gruntfile.js
@ -135,6 +135,22 @@ grunt.initConfig({
|
||||
}
|
||||
},
|
||||
|
||||
// -- CSSLint Config -------------------------------------------------------
|
||||
|
||||
csslint: {
|
||||
options: {
|
||||
csslintrc: '.csslintrc'
|
||||
},
|
||||
|
||||
src: {
|
||||
src: [
|
||||
'src/**/css/*.css',
|
||||
'!src/base/css/*',
|
||||
'!src/forms/css/forms-core.css'
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
// -- CSSMin Config --------------------------------------------------------
|
||||
|
||||
cssmin: {
|
||||
@ -219,6 +235,7 @@ grunt.initConfig({
|
||||
grunt.loadNpmTasks('grunt-contrib-clean');
|
||||
grunt.loadNpmTasks('grunt-contrib-copy');
|
||||
grunt.loadNpmTasks('grunt-contrib-concat');
|
||||
grunt.loadNpmTasks('grunt-contrib-csslint');
|
||||
grunt.loadNpmTasks('grunt-contrib-cssmin');
|
||||
grunt.loadNpmTasks('grunt-contrib-compress');
|
||||
|
||||
@ -237,7 +254,12 @@ grunt.registerTask('import', [
|
||||
'import-normalize'
|
||||
]);
|
||||
|
||||
grunt.registerTask('test', [
|
||||
'csslint'
|
||||
]);
|
||||
|
||||
grunt.registerTask('release', [
|
||||
'test',
|
||||
'default',
|
||||
'clean:release',
|
||||
'compress:release'
|
||||
|
@ -2,6 +2,7 @@
|
||||
"name": "pure",
|
||||
"version": "0.1.1-pre",
|
||||
"private": true,
|
||||
"repository": "git://github.com/yui/pure.git",
|
||||
"devDependencies": {
|
||||
"grunt": "~0.4.1",
|
||||
"parserlib": "~0.2.2",
|
||||
@ -10,6 +11,7 @@
|
||||
"grunt-contrib-copy": "~0.4.1",
|
||||
"grunt-contrib-concat": "~0.3.0",
|
||||
"grunt-contrib-compress": "~0.5.0",
|
||||
"bower": "~0.9.2"
|
||||
"bower": "~0.9.2",
|
||||
"grunt-contrib-csslint": "~0.1.2"
|
||||
}
|
||||
}
|
||||
|
@ -11,6 +11,7 @@
|
||||
-webkit-user-drag: none;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
|
@ -1,3 +1,5 @@
|
||||
/*csslint unqualified-attributes:false*/
|
||||
|
||||
.pure-button {
|
||||
font-size: 100%;
|
||||
*font-size: 90%; /*IE 6/7 - To reduce IE's oversized button text*/
|
||||
|
@ -12,8 +12,8 @@
|
||||
-ms-transition: 0.3s linear border;
|
||||
-o-transition: 0.3s linear border;
|
||||
transition: 0.3s linear border;
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
@ -29,7 +29,7 @@
|
||||
.pure-form input[type="radio"]:focus,
|
||||
.pure-form input[type="checkbox"]:focus {
|
||||
outline: thin dotted #333;
|
||||
outline: 1px auto #129FEA;
|
||||
outline: 1px auto #129FEA;
|
||||
}
|
||||
.pure-form .pure-checkbox,
|
||||
.pure-form .pure-radio {
|
||||
@ -90,9 +90,9 @@
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
}
|
||||
|
||||
.pure-form.pure-form-stacked input[type='text'],
|
||||
.pure-form.pure-form-stacked select,
|
||||
.pure-form.pure-form-stacked label {
|
||||
.pure-form-stacked input[type='text'],
|
||||
.pure-form-stacked select,
|
||||
.pure-form-stacked label {
|
||||
display: block;
|
||||
}
|
||||
|
||||
|
@ -16,7 +16,8 @@
|
||||
|
||||
.pure-u {
|
||||
display: inline-block;
|
||||
zoom: 1; *display: inline; /* IE < 8: fake inline-block */
|
||||
*display: inline; /* IE < 8: fake inline-block */
|
||||
zoom: 1;
|
||||
letter-spacing: normal;
|
||||
word-spacing: normal;
|
||||
vertical-align: top;
|
||||
|
@ -1,3 +1,5 @@
|
||||
/*csslint regex-selectors:false, unqualified-attributes:false*/
|
||||
|
||||
.pure-g-r {
|
||||
letter-spacing: -0.31em;
|
||||
*letter-spacing: normal;
|
||||
|
@ -27,7 +27,8 @@
|
||||
.pure-u-19-24,
|
||||
.pure-u-23-24 {
|
||||
display: inline-block;
|
||||
zoom: 1; *display: inline; /* IE < 8: fake inline-block */
|
||||
*display: inline; /* IE < 8: fake inline-block */
|
||||
zoom: 1;
|
||||
letter-spacing: normal;
|
||||
word-spacing: normal;
|
||||
vertical-align: top;
|
||||
|
@ -1,3 +1,6 @@
|
||||
/*csslint adjoining-classes:false*/
|
||||
/*TODO: Remove this lint rule override after a refactor of this code.*/
|
||||
|
||||
.pure-menu ul {
|
||||
position: absolute;
|
||||
visibility: hidden;
|
||||
@ -39,15 +42,15 @@
|
||||
|
||||
.pure-menu.pure-menu-horizontal > .pure-menu-heading {
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
zoom: 1;
|
||||
*display: inline;
|
||||
zoom: 1;
|
||||
margin: 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.pure-menu.pure-menu-horizontal > ul {
|
||||
display: inline-block;
|
||||
zoom: 1;
|
||||
*display: inline;
|
||||
zoom: 1;
|
||||
vertical-align: middle;
|
||||
height: 2.4em;
|
||||
}
|
||||
@ -91,8 +94,8 @@
|
||||
/* Initial menus should be inline-block so that they are horizontal */
|
||||
.pure-menu-horizontal li {
|
||||
display: inline-block;
|
||||
zoom: 1;
|
||||
*display: inline;
|
||||
zoom: 1;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
|
@ -1,3 +1,6 @@
|
||||
/*csslint box-model:false*/
|
||||
/*TODO: Remove this lint rule override after a refactor of this code.*/
|
||||
|
||||
.pure-paginator {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
@ -6,8 +9,7 @@
|
||||
.pure-paginator li {
|
||||
display: inline-block;
|
||||
*display: inline;
|
||||
/* IE 7 inline-block hack */
|
||||
*zoom: 1;
|
||||
zoom: 1;
|
||||
margin: 0 -0.35em 0 0;
|
||||
}
|
||||
.pure-paginator .pure-button {
|
||||
@ -21,7 +23,7 @@
|
||||
}
|
||||
.pure-paginator .prev, .pure-paginator .next {
|
||||
color: #C0C1C3;
|
||||
text-shadow: 0px -1px 0px rgba(0,0,0, 0.45);
|
||||
text-shadow: 0 -1px 0 rgba(0,0,0, 0.45);
|
||||
}
|
||||
.pure-paginator .prev {
|
||||
border-radius: 2px 0 0 2px;
|
||||
|
@ -8,7 +8,7 @@
|
||||
|
||||
.pure-menu-children li {
|
||||
display: block;
|
||||
border-bottom:1px solid block;
|
||||
border-bottom: 1px solid black;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1,3 +1,6 @@
|
||||
/*csslint adjoining-classes:false*/
|
||||
/*TODO: Remove this lint rule override after a refactor of this code.*/
|
||||
|
||||
/* MAIN MENU STYLING */
|
||||
|
||||
.pure-menu.pure-menu-open,
|
||||
@ -7,7 +10,8 @@
|
||||
}
|
||||
|
||||
/* remove borders for horizontal menus */
|
||||
.pure-menu.pure-menu-horizontal, .pure-menu.pure-menu-horizontal .pure-menu-heading {
|
||||
.pure-menu.pure-menu-horizontal,
|
||||
.pure-menu.pure-menu-horizontal .pure-menu-heading {
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user