Comparing version 0.42.2 to 0.42.3
@@ -378,3 +378,3 @@ | ||
if (this.isPartOfSelector()) { | ||
tok = new Token('ident', new nodes.Ident('null')); | ||
tok = new Token('ident', new nodes.Ident(captures[0])); | ||
} else { | ||
@@ -403,3 +403,3 @@ tok = new Token('null', nodes.null); | ||
if (this.isPartOfSelector()) { | ||
tok = new Token('ident', new nodes.Ident(keyword)); | ||
tok = new Token('ident', new nodes.Ident(captures[0])); | ||
} else { | ||
@@ -430,3 +430,3 @@ tok = new Token(keyword, keyword); | ||
if (this.isPartOfSelector()) { | ||
tok = new Token('ident', new nodes.Ident(op)); | ||
tok = new Token('ident', new nodes.Ident(captures[0])); | ||
} else { | ||
@@ -433,0 +433,0 @@ op = alias[op] || op; |
@@ -33,1 +33,12 @@ | ||
Comment.prototype.__proto__ = Node.prototype; | ||
/** | ||
* Return comment. | ||
* | ||
* @return {String} | ||
* @api public | ||
*/ | ||
Comment.prototype.toString = function(){ | ||
return this.str; | ||
}; |
@@ -62,29 +62,80 @@ | ||
/** | ||
* CSS3 pseudo-selectors. | ||
* CSS pseudo-classes and pseudo-elements. | ||
* See http://dev.w3.org/csswg/selectors4/ | ||
*/ | ||
var pseudoSelectors = [ | ||
'root' | ||
// Logical Combinations | ||
'matches' | ||
, 'not' | ||
// Linguistic Pseudo-classes | ||
, 'dir' | ||
, 'lang' | ||
// Location Pseudo-classes | ||
, 'any-link' | ||
, 'link' | ||
, 'visited' | ||
, 'local-link' | ||
, 'target' | ||
, 'scope' | ||
// User Action Pseudo-classes | ||
, 'hover' | ||
, 'active' | ||
, 'focus' | ||
, 'drop' | ||
// Time-dimensional Pseudo-classes | ||
, 'current' | ||
, 'past' | ||
, 'future' | ||
// The Input Pseudo-classes | ||
, 'enabled' | ||
, 'disabled' | ||
, 'read-only' | ||
, 'read-write' | ||
, 'placeholder-shown' | ||
, 'default' | ||
, 'checked' | ||
, 'indeterminate' | ||
, 'valid' | ||
, 'invalid' | ||
, 'in-range' | ||
, 'out-of-range' | ||
, 'required' | ||
, 'optional' | ||
, 'user-error' | ||
// Tree-Structural pseudo-classes | ||
, 'root' | ||
, 'empty' | ||
, 'blank' | ||
, 'nth-child' | ||
, 'nth-last-child' | ||
, 'first-child' | ||
, 'last-child' | ||
, 'only-child' | ||
, 'nth-of-type' | ||
, 'nth-last-of-type' | ||
, 'first-child' | ||
, 'last-child' | ||
, 'first-of-type' | ||
, 'last-of-type' | ||
, 'only-child' | ||
, 'only-of-type' | ||
, 'empty' | ||
, 'link' | ||
, 'visited' | ||
, 'active' | ||
, 'hover' | ||
, 'focus' | ||
, 'target' | ||
, 'lang' | ||
, 'enabled' | ||
, 'disabled' | ||
, 'checked' | ||
, 'not' | ||
, 'nth-match' | ||
, 'nth-last-match' | ||
// Grid-Structural Selectors | ||
, 'nth-column' | ||
, 'nth-last-column' | ||
// Pseudo-elements | ||
, 'first-line' | ||
, 'first-letter' | ||
, 'before' | ||
, 'after' | ||
// Non-standard | ||
, 'selection' | ||
]; | ||
@@ -404,3 +455,5 @@ | ||
if (':' == this.lookahead(i).type && !this.isPseudoSelector(i + 1) && this.lineContains('.')) | ||
if (':' == this.lookahead(i).type | ||
&& ':' != this.lookahead(i + 1).type && !this.isPseudoSelector(i + 1) | ||
&& this.lineContains('.')) | ||
return false; | ||
@@ -407,0 +460,0 @@ |
@@ -120,3 +120,3 @@ /*! | ||
this.buf += arr.join(this.compress ? '' : '\n'); | ||
this.buf += '\n'; | ||
this.buf += (this.compress ? '' : '\n'); | ||
} | ||
@@ -448,3 +448,3 @@ | ||
var path = node.filename == 'stdin' ? 'stdin' : fs.realpathSync(node.filename) | ||
, line = node.nodes ? node.nodes[0].lineno : node.lineno; | ||
, line = node.nodes && node.nodes.length ? node.nodes[0].lineno : node.lineno; | ||
@@ -451,0 +451,0 @@ if (this.linenos){ |
@@ -864,3 +864,3 @@ | ||
// Literal | ||
if (~path.indexOf('.css') && !~path.indexOf('.css.')) { | ||
if (/\.css(?:"|$)/.test(path)) { | ||
literal = true; | ||
@@ -956,3 +956,3 @@ if (!imported.once && !this.includeCSS) { | ||
if (arg) { | ||
if (!arg.isEmpty) node.val = arg; | ||
arg.isEmpty ? args.nodes[i - 1] = node.val : node.val = arg; | ||
} else { | ||
@@ -959,0 +959,0 @@ args.push(node.val); |
{ | ||
"name": "stylus", | ||
"description": "Robust, expressive, and feature-rich CSS superset", | ||
"version": "0.42.2", | ||
"version": "0.42.3", | ||
"author": "TJ Holowaychuk <tj@vision-media.ca>", | ||
@@ -6,0 +6,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 4 instances in 1 package
10241
3
269676
69