html-select
Advanced tools
Comparing version 1.1.1 to 1.1.2
11
index.js
@@ -75,3 +75,11 @@ var inherits = require('inherits'); | ||
var m = this.matches[i]; | ||
if (m.stopIndex && m.stopIndex < this.stack.length) continue; | ||
m.stopIndex = undefined; | ||
var sel = this.selector[m.index]; | ||
if (sel === '>') { | ||
sel = this.selector[++m.index]; | ||
} | ||
var prev = m.index > 0 && this.selector[m.index-1]; | ||
if (match(sel, tag)) { | ||
@@ -91,2 +99,5 @@ if (++ m.index === this.selector.length) { | ||
} | ||
else if (prev === '>') { | ||
m.stopIndex = this.stack.length; | ||
} | ||
} | ||
@@ -93,0 +104,0 @@ |
{ | ||
"name": "html-select", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "match a tokenized html stream with css selectors", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
45850
25
744
7