Skip to content
This repository was archived by the owner on Dec 11, 2021. It is now read-only.

Linting:Add scss variable files to linting #105

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .jshintrc
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
"trailing": true,
"undef": true,
"unused": true,

"node": true
"node": true,
"globals": {
"define": false
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"grunt-csscomb": "3.0.0",
"grunt-git-authors": "2.0.0",
"grunt-html": "1.6.0",
"grunt-jscs": "0.6.2",
"grunt-jscs": "2.0.0",
"grunt-sass": "0.17.0",
"grunt-selenium-server": "0.1.2",
"grunt-svgmin": "2.0.0",
Expand Down
4 changes: 2 additions & 2 deletions performance/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ var components = {
html = "";

function render( i ) {
framework[ component ].variations[ keys[ i ] ].forEach(function( value ) {
framework[ component ].variations[ keys[ i ] ].forEach( function( value ) {
current[ keys[ i ] ] = value;
if ( i < keys.length - 1 ) {
render( i + 1 );
Expand All @@ -17,7 +17,7 @@ var components = {
html = html + framework[ component ].generator.call( this, current );
}
}
});
} );
}
while ( currentCount < count ) {
render( 0 );
Expand Down
22 changes: 11 additions & 11 deletions scss/variables/chassis.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
// This is just boiuler plate dont worry about it
// This is just boiler plate dont worry about it
// This just supports loading in any enviroment
(function ( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [], factory );
} else if ( typeof exports === "object" ) {
module.exports = factory();
} else {
root.chassis = factory();
}
}( this, function () {
( function( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [], factory );
} else if ( typeof exports === "object" ) {
module.exports = factory();
} else {
root.chassis = factory();
}
}( this, function() {
return {};
} ) );
} ) );
23 changes: 12 additions & 11 deletions scss/variables/colors.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
( function ( root, factory ) {
if ( typeof define === 'function' && define.amd ) {
define( [ "./chassis" ], factory );
} else if (typeof exports === 'object') {
module.exports = factory( require('./chassis') );
} else {
root.chassis = factory( root.chassis );
}
}(this, function ( chassis ) {
( function( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [ "./chassis" ], factory );
} else if ( typeof exports === "object" ) {
module.exports = factory( require( "./chassis" ) );
} else {
root.chassis = factory( root.chassis );
}
}( this, function( chassis ) {

var colors = {
"chassis-gray-dark": {
"value": "#383838",
Expand All @@ -32,7 +33,7 @@ var colors = {
"value": "#fadf51",
"name": "Chassis Yellow"
}
}
};
chassis.colors = {
"background": colors[ "chassis-gray-dark" ],
"font": colors[ "chassis-gray-dark" ],
Expand All @@ -43,6 +44,6 @@ chassis.colors = {
name: "Chassis - Blockquote color",
value: "#eee"
}
}
};
return chassis;
} ) );
2 changes: 1 addition & 1 deletion scss/variables/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ fs.readdirSync( varPath ).forEach( function( file ) {
chassis = require( path.join( process.cwd(), "scss/variables" ) + "/" + file );
} );

module.exports = chassis;
module.exports = chassis;
21 changes: 11 additions & 10 deletions scss/variables/template.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
// This is just boiuler plate dont worry about it
// This is just boiler plate dont worry about it
// This just supports loading in any enviroment
(function ( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [], factory );
} else if ( typeof exports === "object" ) {
module.exports = factory();
} else {
root.chassis = factory();
}
}( this, function () {
( function( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [], factory );
} else if ( typeof exports === "object" ) {
module.exports = factory();
} else {
root.chassis = factory();
}
}( this, function() {

//>> return chasses.moduleName;
} ) );
16 changes: 8 additions & 8 deletions scss/variables/typography.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
( function ( root, factory ) {
if ( typeof define === 'function' && define.amd ) {
( function( root, factory ) {
if ( typeof define === "function" && define.amd ) {
define( [ "./chassis" ], factory );
} else if (typeof exports === 'object') {
module.exports = factory( require('./chassis') );
} else if ( typeof exports === "object" ) {
module.exports = factory( require( "./chassis" ) );
} else {
root.chassis = factory( root.chassis );
}
}(this, function ( chassis ) {
}( this, function( chassis ) {

var color = "#222";
var fontSize = "20px";
Expand Down Expand Up @@ -43,15 +43,15 @@ chassis.typography = {
},
monospace: {
name: "Font Family - Monospace",
value :"\"courier new\", monospace"
value: "\"courier new\", monospace"
},
serif: {
name: "Font Family - Serif",
value :"Georgia, \"Times New Roman\", Times, serif"
value: "Georgia, \"Times New Roman\", Times, serif"
},
sans: {
name: "Font Family - Sans",
value :"Helvetica, Arial, sans-serif"
value: "Helvetica, Arial, sans-serif"
}
};

Expand Down
4 changes: 2 additions & 2 deletions tasks/options/jscs.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module.exports = {
all: [ "*.js", "performance/**/*.js" ]
};
all: [ "*.js", "performance/**/*.js", "scss/variables/**/*.js" ]
};
4 changes: 2 additions & 2 deletions tasks/options/jshint.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module.exports = {
files: [ "*.js", "performance/**/*.js" ],
files: [ "*.js", "performance/**/*.js", "scss/variables/**/*.js" ],
options: {
jshintrc: ".jshintrc"
}
};
};