update csslint
This commit is contained in:
parent
bb55802197
commit
dcd96294f7
2 changed files with 373 additions and 327 deletions
|
|
@ -1,7 +1,7 @@
|
|||
define(function(require, exports, module) {
|
||||
/*!
|
||||
CSSLint
|
||||
Copyright (c) 2013 Nicole Sullivan and Nicholas C. Zakas. All rights reserved.
|
||||
Copyright (c) 2014 Nicole Sullivan and Nicholas C. Zakas. All rights reserved.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
|
@ -22,7 +22,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|||
THE SOFTWARE.
|
||||
|
||||
*/
|
||||
/* Build: v0.10.0 15-August-2013 01:07:22 */
|
||||
/* Build: v0.10.0 31-March-2014 08:16:48 */
|
||||
/*!
|
||||
Parser-Lib
|
||||
Copyright (c) 2009-2011 Nicholas C. Zakas. All rights reserved.
|
||||
|
|
@ -46,7 +46,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|||
THE SOFTWARE.
|
||||
|
||||
*/
|
||||
/* Version v0.2.3, Build time: 19-June-2013 11:16:15 */
|
||||
/* Version v0.2.4, Build time: 7-January-2014 07:32:49 */
|
||||
var parserlib = {};
|
||||
(function(){
|
||||
|
||||
|
|
@ -956,7 +956,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|||
THE SOFTWARE.
|
||||
|
||||
*/
|
||||
/* Version v0.2.3, Build time: 19-June-2013 11:16:15 */
|
||||
/* Version v0.2.4, Build time: 7-January-2014 07:32:49 */
|
||||
(function(){
|
||||
var EventTarget = parserlib.util.EventTarget,
|
||||
TokenStreamBase = parserlib.util.TokenStreamBase,
|
||||
|
|
@ -991,6 +991,7 @@ var Colors = {
|
|||
darkcyan :"#008b8b",
|
||||
darkgoldenrod :"#b8860b",
|
||||
darkgray :"#a9a9a9",
|
||||
darkgrey :"#a9a9a9",
|
||||
darkgreen :"#006400",
|
||||
darkkhaki :"#bdb76b",
|
||||
darkmagenta :"#8b008b",
|
||||
|
|
@ -1002,11 +1003,13 @@ var Colors = {
|
|||
darkseagreen :"#8fbc8f",
|
||||
darkslateblue :"#483d8b",
|
||||
darkslategray :"#2f4f4f",
|
||||
darkslategrey :"#2f4f4f",
|
||||
darkturquoise :"#00ced1",
|
||||
darkviolet :"#9400d3",
|
||||
deeppink :"#ff1493",
|
||||
deepskyblue :"#00bfff",
|
||||
dimgray :"#696969",
|
||||
dimgrey :"#696969",
|
||||
dodgerblue :"#1e90ff",
|
||||
firebrick :"#b22222",
|
||||
floralwhite :"#fffaf0",
|
||||
|
|
@ -1017,6 +1020,7 @@ var Colors = {
|
|||
gold :"#ffd700",
|
||||
goldenrod :"#daa520",
|
||||
gray :"#808080",
|
||||
grey :"#808080",
|
||||
green :"#008000",
|
||||
greenyellow :"#adff2f",
|
||||
honeydew :"#f0fff0",
|
||||
|
|
@ -1034,12 +1038,14 @@ var Colors = {
|
|||
lightcyan :"#e0ffff",
|
||||
lightgoldenrodyellow :"#fafad2",
|
||||
lightgray :"#d3d3d3",
|
||||
lightgrey :"#d3d3d3",
|
||||
lightgreen :"#90ee90",
|
||||
lightpink :"#ffb6c1",
|
||||
lightsalmon :"#ffa07a",
|
||||
lightseagreen :"#20b2aa",
|
||||
lightskyblue :"#87cefa",
|
||||
lightslategray :"#778899",
|
||||
lightslategrey :"#778899",
|
||||
lightsteelblue :"#b0c4de",
|
||||
lightyellow :"#ffffe0",
|
||||
lime :"#00ff00",
|
||||
|
|
@ -1092,6 +1098,7 @@ var Colors = {
|
|||
skyblue :"#87ceeb",
|
||||
slateblue :"#6a5acd",
|
||||
slategray :"#708090",
|
||||
slategrey :"#708090",
|
||||
snow :"#fffafa",
|
||||
springgreen :"#00ff7f",
|
||||
steelblue :"#4682b4",
|
||||
|
|
@ -1117,6 +1124,7 @@ var Colors = {
|
|||
buttontext :"Text on push buttons.",
|
||||
captiontext :"Text in caption, size box, and scrollbar arrow box.",
|
||||
graytext :"Grayed (disabled) text. This color is set to #000 if the current display driver does not support a solid gray color.",
|
||||
greytext :"Greyed (disabled) text. This color is set to #000 if the current display driver does not support a solid grey color.",
|
||||
highlight :"Item(s) selected in a control.",
|
||||
highlighttext :"Text of item(s) selected in a control.",
|
||||
inactiveborder :"Inactive window border.",
|
||||
|
|
@ -3533,6 +3541,12 @@ nth
|
|||
var Properties = {
|
||||
|
||||
//A
|
||||
"align-items" : "flex-start | flex-end | center | baseline | stretch",
|
||||
"align-content" : "flex-start | flex-end | center | space-between | space-around | stretch",
|
||||
"align-self" : "auto | flex-start | flex-end | center | baseline | stretch",
|
||||
"-webkit-align-items" : "flex-start | flex-end | center | baseline | stretch",
|
||||
"-webkit-align-content" : "flex-start | flex-end | center | space-between | space-around | stretch",
|
||||
"-webkit-align-self" : "auto | flex-start | flex-end | center | baseline | stretch",
|
||||
"alignment-adjust" : "auto | baseline | before-edge | text-before-edge | middle | central | after-edge | text-after-edge | ideographic | alphabetic | hanging | mathematical | <percentage> | <length>",
|
||||
"alignment-baseline" : "baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",
|
||||
"animation" : 1,
|
||||
|
|
@ -3728,15 +3742,24 @@ var Properties = {
|
|||
"border-top-width" : "<border-width>",
|
||||
"border-width" : { multi: "<border-width>", max: 4 },
|
||||
"bottom" : "<margin-width> | inherit",
|
||||
"box-align" : "start | end | center | baseline | stretch", //http://www.w3.org/TR/2009/WD-css3-flexbox-20090723/
|
||||
"box-decoration-break" : "slice |clone",
|
||||
"box-direction" : "normal | reverse | inherit",
|
||||
"box-flex" : "<number>",
|
||||
"box-flex-group" : "<integer>",
|
||||
"box-lines" : "single | multiple",
|
||||
"box-ordinal-group" : "<integer>",
|
||||
"box-orient" : "horizontal | vertical | inline-axis | block-axis | inherit",
|
||||
"box-pack" : "start | end | center | justify",
|
||||
"-moz-box-align" : "start | end | center | baseline | stretch",
|
||||
"-moz-box-decoration-break" : "slice |clone",
|
||||
"-moz-box-direction" : "normal | reverse | inherit",
|
||||
"-moz-box-flex" : "<number>",
|
||||
"-moz-box-flex-group" : "<integer>",
|
||||
"-moz-box-lines" : "single | multiple",
|
||||
"-moz-box-ordinal-group" : "<integer>",
|
||||
"-moz-box-orient" : "horizontal | vertical | inline-axis | block-axis | inherit",
|
||||
"-moz-box-pack" : "start | end | center | justify",
|
||||
"-webkit-box-align" : "start | end | center | baseline | stretch",
|
||||
"-webkit-box-decoration-break" : "slice |clone",
|
||||
"-webkit-box-direction" : "normal | reverse | inherit",
|
||||
"-webkit-box-flex" : "<number>",
|
||||
"-webkit-box-flex-group" : "<integer>",
|
||||
"-webkit-box-lines" : "single | multiple",
|
||||
"-webkit-box-ordinal-group" : "<integer>",
|
||||
"-webkit-box-orient" : "horizontal | vertical | inline-axis | block-axis | inherit",
|
||||
"-webkit-box-pack" : "start | end | center | justify",
|
||||
"box-shadow" : function (expression) {
|
||||
var result = false,
|
||||
part;
|
||||
|
|
@ -3782,7 +3805,7 @@ var Properties = {
|
|||
|
||||
//D
|
||||
"direction" : "ltr | rtl | inherit",
|
||||
"display" : "inline | block | list-item | inline-block | table | inline-table | table-row-group | table-header-group | table-footer-group | table-row | table-column-group | table-column | table-cell | table-caption | box | inline-box | grid | inline-grid | none | inherit | -moz-box | -moz-inline-block | -moz-inline-box | -moz-inline-grid | -moz-inline-stack | -moz-inline-table | -moz-grid | -moz-grid-group | -moz-grid-line | -moz-groupbox | -moz-deck | -moz-popup | -moz-stack | -moz-marker | -webkit-box | -webkit-inline-box",
|
||||
"display" : "inline | block | list-item | inline-block | table | inline-table | table-row-group | table-header-group | table-footer-group | table-row | table-column-group | table-column | table-cell | table-caption | grid | inline-grid | none | inherit | -moz-box | -moz-inline-block | -moz-inline-box | -moz-inline-grid | -moz-inline-stack | -moz-inline-table | -moz-grid | -moz-grid-group | -moz-grid-line | -moz-groupbox | -moz-deck | -moz-popup | -moz-stack | -moz-marker | -webkit-box | -webkit-inline-box | -ms-flexbox | -ms-inline-flexbox | flex | -webkit-flex | inline-flex | -webkit-inline-flex",
|
||||
"dominant-baseline" : 1,
|
||||
"drop-initial-after-adjust" : "central | middle | after-edge | text-after-edge | ideographic | alphabetic | mathematical | <percentage> | <length>",
|
||||
"drop-initial-after-align" : "baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",
|
||||
|
|
@ -3799,6 +3822,26 @@ var Properties = {
|
|||
"filter" : 1,
|
||||
"fit" : "fill | hidden | meet | slice",
|
||||
"fit-position" : 1,
|
||||
"flex" : "none | [ <flex-grow> <flex-shrink>? || <flex-basis>",
|
||||
"flex-basis" : "<width>",
|
||||
"flex-direction" : "row | row-reverse | column | column-reverse",
|
||||
"flex-flow" : "<flex-direction> || <flex-wrap>",
|
||||
"flex-grow" : "<number>",
|
||||
"flex-shrink" : "<number>",
|
||||
"flex-wrap" : "nowrap | wrap | wrap-reverse",
|
||||
"-webkit-flex" : "none | [ <flex-grow> <flex-shrink>? || <flex-basis>",
|
||||
"-webkit-flex-basis" : "<width>",
|
||||
"-webkit-flex-direction" : "row | row-reverse | column | column-reverse",
|
||||
"-webkit-flex-flow" : "<flex-direction> || <flex-wrap>",
|
||||
"-webkit-flex-grow" : "<number>",
|
||||
"-webkit-flex-shrink" : "<number>",
|
||||
"-webkit-flex-wrap" : "nowrap | wrap | wrap-reverse",
|
||||
"-ms-flex" : "[[ <number> <number>? ] || [ <length> || <percentage> || auto ] ] | none",
|
||||
"-ms-flex-align" : "start | end | center | stretch | baseline",
|
||||
"-ms-flex-direction" : "row | column | row-reverse | column-reverse | inherit",
|
||||
"-ms-flex-order" : "<number>",
|
||||
"-ms-flex-pack" : "start | end | center | justify",
|
||||
"-ms-flex-wrap" : "nowrap | wrap | wrap-reverse",
|
||||
"float" : "left | right | none | inherit",
|
||||
"float-offset" : 1,
|
||||
"font" : 1,
|
||||
|
|
@ -3842,6 +3885,10 @@ var Properties = {
|
|||
"image-resolution" : 1,
|
||||
"inline-box-align" : "initial | last | <integer>",
|
||||
|
||||
//J
|
||||
"justify-content" : "flex-start | flex-end | center | space-between | space-around",
|
||||
"-webkit-justify-content" : "flex-start | flex-end | center | space-between | space-around",
|
||||
|
||||
//L
|
||||
"left" : "<margin-width> | inherit",
|
||||
"letter-spacing" : "<length> | normal | inherit",
|
||||
|
|
@ -3885,6 +3932,8 @@ var Properties = {
|
|||
|
||||
//O
|
||||
"opacity" : "<number> | inherit",
|
||||
"order" : "<integer>",
|
||||
"-webkit-order" : "<integer>",
|
||||
"orphans" : "<integer> | inherit",
|
||||
"outline" : 1,
|
||||
"outline-color" : "<color> | invert | inherit",
|
||||
|
|
@ -3893,6 +3942,7 @@ var Properties = {
|
|||
"outline-width" : "<border-width> | inherit",
|
||||
"overflow" : "visible | hidden | scroll | auto | inherit",
|
||||
"overflow-style" : 1,
|
||||
"overflow-wrap" : "normal | break-word",
|
||||
"overflow-x" : 1,
|
||||
"overflow-y" : 1,
|
||||
|
||||
|
|
@ -3970,6 +4020,8 @@ var Properties = {
|
|||
"text-transform" : "capitalize | uppercase | lowercase | none | inherit",
|
||||
"text-wrap" : "normal | none | avoid",
|
||||
"top" : "<margin-width> | inherit",
|
||||
"-ms-touch-action" : "auto | none | pan-x | pan-y",
|
||||
"touch-action" : "auto | none | pan-x | pan-y",
|
||||
"transform" : 1,
|
||||
"transform-origin" : 1,
|
||||
"transform-style" : 1,
|
||||
|
|
@ -3980,7 +4032,7 @@ var Properties = {
|
|||
"transition-timing-function" : 1,
|
||||
|
||||
//U
|
||||
"unicode-bidi" : "normal | embed | bidi-override | inherit",
|
||||
"unicode-bidi" : "normal | embed | isolate | bidi-override | isolate-override | plaintext | inherit",
|
||||
"user-modify" : "read-only | read-write | write-only | inherit",
|
||||
"user-select" : "none | text | toggle | element | elements | all | inherit",
|
||||
|
||||
|
|
@ -4004,7 +4056,8 @@ var Properties = {
|
|||
"width" : "<length> | <percentage> | auto | inherit" ,
|
||||
"word-break" : "normal | keep-all | break-all",
|
||||
"word-spacing" : "<length> | normal | inherit",
|
||||
"word-wrap" : 1,
|
||||
"word-wrap" : "normal | break-word",
|
||||
"writing-mode" : "horizontal-tb | vertical-rl | vertical-lr | lr-tb | rl-tb | tb-rl | bt-rl | tb-lr | bt-lr | lr-bt | rl-bt | lr | rl | tb | inherit",
|
||||
|
||||
//Z
|
||||
"z-index" : "<integer> | auto | inherit",
|
||||
|
|
@ -4275,9 +4328,6 @@ function PropertyValuePart(text, line, col){
|
|||
|
||||
}
|
||||
|
||||
} else if (/^([+\-]?[\d\.]+)%$/i.test(text)){ //percentage
|
||||
this.type = "percentage";
|
||||
this.value = +RegExp.$1;
|
||||
} else if (/^([+\-]?[\d\.]+)%$/i.test(text)){ //percentage
|
||||
this.type = "percentage";
|
||||
this.value = +RegExp.$1;
|
||||
|
|
@ -4374,6 +4424,7 @@ PropertyValuePart.prototype.constructor = PropertyValuePart;
|
|||
PropertyValuePart.fromToken = function(token){
|
||||
return new PropertyValuePart(token.value, token.startLine, token.startCol);
|
||||
};
|
||||
|
||||
var Pseudos = {
|
||||
":first-letter": 1,
|
||||
":first-line": 1,
|
||||
|
|
@ -5661,7 +5712,7 @@ var Tokens = [
|
|||
{ name: "FONT_FACE_SYM", text: "@font-face"},
|
||||
{ name: "CHARSET_SYM", text: "@charset"},
|
||||
{ name: "NAMESPACE_SYM", text: "@namespace"},
|
||||
{ name: "VIEWPORT_SYM", text: "@viewport"},
|
||||
{ name: "VIEWPORT_SYM", text: ["@viewport", "@-ms-viewport"]},
|
||||
{ name: "UNKNOWN_SYM" },
|
||||
//{ name: "ATKEYWORD"},
|
||||
|
||||
|
|
@ -6443,7 +6494,7 @@ var CSSLint = (function(){
|
|||
embeddedRuleset = /\/\*csslint([^\*]*)\*\//,
|
||||
api = new parserlib.util.EventTarget();
|
||||
|
||||
api.version = "0.10.0";
|
||||
api.version = "@VERSION@";
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Rule Management
|
||||
|
|
@ -8941,13 +8992,14 @@ CSSLint.addFormatter({
|
|||
output += filename + ": " + capitalize(message.type) + " - " + message.message + "\n";
|
||||
} else {
|
||||
output += filename + ": " + "line " + message.line +
|
||||
", col " + message.col + ", " + capitalize(message.type) + " - " + message.message + "\n";
|
||||
", col " + message.col + ", " + capitalize(message.type) + " - " + message.message + " (" + message.rule.id + ")\n";
|
||||
}
|
||||
});
|
||||
|
||||
return output;
|
||||
}
|
||||
});
|
||||
|
||||
/*global CSSLint*/
|
||||
CSSLint.addFormatter({
|
||||
//format information
|
||||
|
|
|
|||
|
|
@ -12,13 +12,7 @@ var deps = {
|
|||
csslint: {
|
||||
path: "mode/css/csslint.js",
|
||||
url: "https://raw.github.com/stubbornella/csslint/master/release/csslint.js",
|
||||
needsFixup: true,
|
||||
browserify: {
|
||||
npmModule: "git+https://github.com/stubbornella/csslint.git#master",
|
||||
path: "jshint/src/jshint.js",
|
||||
exports: "jshint"
|
||||
},
|
||||
fetch: browserify,
|
||||
needsFixup: true
|
||||
},
|
||||
requirejs: {
|
||||
path: "../../demo/kitchen-sink/require.js",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue