Comparing version 1.1.1 to 1.1.2
@@ -8,3 +8,3 @@ var path = require('path'), | ||
var less = { | ||
version: [1, 1, 1], | ||
version: [1, 1, 2], | ||
Parser: require('less/parser').Parser, | ||
@@ -11,0 +11,0 @@ importer: require('less/parser').importer, |
@@ -11,8 +11,9 @@ (function (tree) { | ||
eval: function (env) { | ||
var mixins, rules = [], match = false; | ||
var mixins, args, rules = [], match = false; | ||
for (var i = 0; i < env.frames.length; i++) { | ||
if ((mixins = env.frames[i].find(this.selector)).length > 0) { | ||
args = this.arguments && this.arguments.map(function (a) { return a.eval(env) }); | ||
for (var m = 0; m < mixins.length; m++) { | ||
if (mixins[m].match(this.arguments, env)) { | ||
if (mixins[m].match(args, env)) { | ||
try { | ||
@@ -19,0 +20,0 @@ Array.prototype.push.apply( |
@@ -19,8 +19,9 @@ (function (tree) { | ||
var that = this; | ||
this.value = this.value.replace(/`([^`]+)`/g, function (_, exp) { | ||
var value = this.value.replace(/`([^`]+)`/g, function (_, exp) { | ||
return new(tree.JavaScript)(exp, that.index, true).eval(env).value; | ||
}).replace(/@\{([\w-]+)\}/g, function (_, name) { | ||
return new(tree.Variable)('@' + name, that.index).eval(env).value; | ||
var v = new(tree.Variable)('@' + name, that.index).eval(env); | ||
return v.value || v.toCSS(); | ||
}); | ||
return this; | ||
return new(tree.Quoted)(this.quote + value + this.quote, value, this.escaped, this.index); | ||
} | ||
@@ -27,0 +28,0 @@ }; |
@@ -8,3 +8,3 @@ { | ||
"contributors" : [], | ||
"version" : "1.1.1", | ||
"version" : "1.1.2", | ||
"bin" : { "lessc": "./bin/lessc" }, | ||
@@ -11,0 +11,0 @@ "main" : "./lib/less/index", |
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
698570
13197
91
5