mirror of
https://github.com/less/less.js.git
synced 2026-01-23 06:07:56 -05:00
simplified rule regex
This commit is contained in:
@@ -411,8 +411,7 @@ less.parser = {
|
||||
var name, value, match;
|
||||
|
||||
if (name = $(this.property) || $(this.entities.variable, true)) {
|
||||
if ((name[0] != '@') && (match =
|
||||
peek(/((?:[\s\w."']|-[a-z])+|[^@+\/*(;{}-]*)[;][\s\n]*/g))) {
|
||||
if ((name[0] != '@') && (match = peek(/([^@+\/*(;{}-]*)[;][\s\n]*/g))) {
|
||||
i += match[0].length;
|
||||
return new(tree.Rule)(name, match[1]);
|
||||
} else if ((value = $(this.value)) && ($(';') || peek(/\}/g))) {
|
||||
|
||||
Reference in New Issue
Block a user