4 * Sizzle CSS Selector Engine - v1.0
5 * Copyright 2009, The Dojo Foundation
6 * Released under the MIT, BSD, and GPL Licenses.
7 * More information: http://sizzlejs.com/
11 var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
13 toString = Object.prototype.toString,
15 baseHasDuplicate = true;
17 // Here we check if the JavaScript engine is using some sort of
18 // optimization where it does not always call our comparision
19 // function. If that is the case, discard the hasDuplicate value.
20 // Thus far that includes Google Chrome.
21 [0, 0].sort(function(){
22 baseHasDuplicate = false;
26 var Sizzle = function(selector, context, results, seed) {
27 results = results || [];
28 context = context || document;
30 var origContext = context;
32 if ( context.nodeType !== 1 && context.nodeType !== 9 ) {
36 if ( !selector || typeof selector !== "string" ) {
40 var parts = [], m, set, checkSet, extra, prune = true, contextXML = Sizzle.isXML(context),
41 soFar = selector, ret, cur, pop, i;
43 // Reset the position of the chunker regexp (start from head)
46 m = chunker.exec(soFar);
60 if ( parts.length > 1 && origPOS.exec( selector ) ) {
61 if ( parts.length === 2 && Expr.relative[ parts[0] ] ) {
62 set = posProcess( parts[0] + parts[1], context );
64 set = Expr.relative[ parts[0] ] ?
66 Sizzle( parts.shift(), context );
68 while ( parts.length ) {
69 selector = parts.shift();
71 if ( Expr.relative[ selector ] ) {
72 selector += parts.shift();
75 set = posProcess( selector, set );
79 // Take a shortcut and set the context if the root selector is an ID
80 // (but not if it'll be faster if the inner selector is an ID)
81 if ( !seed && parts.length > 1 && context.nodeType === 9 && !contextXML &&
82 Expr.match.ID.test(parts[0]) && !Expr.match.ID.test(parts[parts.length - 1]) ) {
83 ret = Sizzle.find( parts.shift(), context, contextXML );
84 context = ret.expr ? Sizzle.filter( ret.expr, ret.set )[0] : ret.set[0];
89 { expr: parts.pop(), set: makeArray(seed) } :
90 Sizzle.find( parts.pop(), parts.length === 1 && (parts[0] === "~" || parts[0] === "+") && context.parentNode ? context.parentNode : context, contextXML );
91 set = ret.expr ? Sizzle.filter( ret.expr, ret.set ) : ret.set;
93 if ( parts.length > 0 ) {
94 checkSet = makeArray(set);
99 while ( parts.length ) {
103 if ( !Expr.relative[ cur ] ) {
113 Expr.relative[ cur ]( checkSet, pop, contextXML );
116 checkSet = parts = [];
125 Sizzle.error( cur || selector );
128 if ( toString.call(checkSet) === "[object Array]" ) {
130 results.push.apply( results, checkSet );
131 } else if ( context && context.nodeType === 1 ) {
132 for ( i = 0; checkSet[i] != null; i++ ) {
133 if ( checkSet[i] && (checkSet[i] === true || checkSet[i].nodeType === 1 && Sizzle.contains(context, checkSet[i])) ) {
134 results.push( set[i] );
138 for ( i = 0; checkSet[i] != null; i++ ) {
139 if ( checkSet[i] && checkSet[i].nodeType === 1 ) {
140 results.push( set[i] );
145 makeArray( checkSet, results );
149 Sizzle( extra, origContext, results, seed );
150 Sizzle.uniqueSort( results );
156 Sizzle.uniqueSort = function(results){
158 hasDuplicate = baseHasDuplicate;
159 results.sort(sortOrder);
161 if ( hasDuplicate ) {
162 for ( var i = 1; i < results.length; i++ ) {
163 if ( results[i] === results[i-1] ) {
164 results.splice(i--, 1);
173 Sizzle.matches = function(expr, set){
174 return Sizzle(expr, null, null, set);
177 Sizzle.find = function(expr, context, isXML){
184 for ( var i = 0, l = Expr.order.length; i < l; i++ ) {
185 var type = Expr.order[i], match;
187 if ( (match = Expr.leftMatch[ type ].exec( expr )) ) {
191 if ( left.substr( left.length - 1 ) !== "\\" ) {
192 match[1] = (match[1] || "").replace(/\\/g, "");
193 set = Expr.find[ type ]( match, context, isXML );
195 expr = expr.replace( Expr.match[ type ], "" );
203 set = context.getElementsByTagName("*");
206 return {set: set, expr: expr};
209 Sizzle.filter = function(expr, set, inplace, not){
210 var old = expr, result = [], curLoop = set, match, anyFound,
211 isXMLFilter = set && set[0] && Sizzle.isXML(set[0]);
213 while ( expr && set.length ) {
214 for ( var type in Expr.filter ) {
215 if ( (match = Expr.leftMatch[ type ].exec( expr )) != null && match[2] ) {
216 var filter = Expr.filter[ type ], found, item, left = match[1];
221 if ( left.substr( left.length - 1 ) === "\\" ) {
225 if ( curLoop === result ) {
229 if ( Expr.preFilter[ type ] ) {
230 match = Expr.preFilter[ type ]( match, curLoop, inplace, result, not, isXMLFilter );
233 anyFound = found = true;
234 } else if ( match === true ) {
240 for ( var i = 0; (item = curLoop[i]) != null; i++ ) {
242 found = filter( item, match, i, curLoop );
243 var pass = not ^ !!found;
245 if ( inplace && found != null ) {
259 if ( found !== undefined ) {
264 expr = expr.replace( Expr.match[ type ], "" );
275 // Improper expression
276 if ( expr === old ) {
277 if ( anyFound == null ) {
278 Sizzle.error( expr );
290 Sizzle.error = function( msg ) {
291 throw "Syntax error, unrecognized expression: " + msg;
294 var Expr = Sizzle.selectors = {
295 order: [ "ID", "NAME", "TAG" ],
297 ID: /#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
298 CLASS: /\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
299 NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,
300 ATTR: /\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,
301 TAG: /^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,
302 CHILD: /:(only|nth|last|first)-child(?:\((even|odd|[\dn+\-]*)\))?/,
303 POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,
304 PSEUDO: /:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/
308 "class": "className",
312 href: function(elem){
313 return elem.getAttribute("href");
317 "+": function(checkSet, part){
318 var isPartStr = typeof part === "string",
319 isTag = isPartStr && !/\W/.test(part),
320 isPartStrNotTag = isPartStr && !isTag;
323 part = part.toLowerCase();
326 for ( var i = 0, l = checkSet.length, elem; i < l; i++ ) {
327 if ( (elem = checkSet[i]) ) {
328 while ( (elem = elem.previousSibling) && elem.nodeType !== 1 ) {}
330 checkSet[i] = isPartStrNotTag || elem && elem.nodeName.toLowerCase() === part ?
336 if ( isPartStrNotTag ) {
337 Sizzle.filter( part, checkSet, true );
340 ">": function(checkSet, part){
341 var isPartStr = typeof part === "string",
342 elem, i = 0, l = checkSet.length;
344 if ( isPartStr && !/\W/.test(part) ) {
345 part = part.toLowerCase();
347 for ( ; i < l; i++ ) {
350 var parent = elem.parentNode;
351 checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false;
355 for ( ; i < l; i++ ) {
358 checkSet[i] = isPartStr ?
360 elem.parentNode === part;
365 Sizzle.filter( part, checkSet, true );
369 "": function(checkSet, part, isXML){
370 var doneName = done++, checkFn = dirCheck, nodeCheck;
372 if ( typeof part === "string" && !/\W/.test(part) ) {
373 part = part.toLowerCase();
375 checkFn = dirNodeCheck;
378 checkFn("parentNode", part, doneName, checkSet, nodeCheck, isXML);
380 "~": function(checkSet, part, isXML){
381 var doneName = done++, checkFn = dirCheck, nodeCheck;
383 if ( typeof part === "string" && !/\W/.test(part) ) {
384 part = part.toLowerCase();
386 checkFn = dirNodeCheck;
389 checkFn("previousSibling", part, doneName, checkSet, nodeCheck, isXML);
393 ID: function(match, context, isXML){
394 if ( typeof context.getElementById !== "undefined" && !isXML ) {
395 var m = context.getElementById(match[1]);
399 NAME: function(match, context){
400 if ( typeof context.getElementsByName !== "undefined" ) {
401 var ret = [], results = context.getElementsByName(match[1]);
403 for ( var i = 0, l = results.length; i < l; i++ ) {
404 if ( results[i].getAttribute("name") === match[1] ) {
405 ret.push( results[i] );
409 return ret.length === 0 ? null : ret;
412 TAG: function(match, context){
413 return context.getElementsByTagName(match[1]);
417 CLASS: function(match, curLoop, inplace, result, not, isXML){
418 match = " " + match[1].replace(/\\/g, "") + " ";
424 for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) {
426 if ( not ^ (elem.className && (" " + elem.className + " ").replace(/[\t\n]/g, " ").indexOf(match) >= 0) ) {
430 } else if ( inplace ) {
439 return match[1].replace(/\\/g, "");
441 TAG: function(match, curLoop){
442 return match[1].toLowerCase();
444 CHILD: function(match){
445 if ( match[1] === "nth" ) {
446 // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6'
447 var test = /(-?)(\d*)n((?:\+|-)?\d*)/.exec(
448 match[2] === "even" && "2n" || match[2] === "odd" && "2n+1" ||
449 !/\D/.test( match[2] ) && "0n+" + match[2] || match[2]);
451 // calculate the numbers (first)n+(last) including if they are negative
452 match[2] = (test[1] + (test[2] || 1)) - 0;
453 match[3] = test[3] - 0;
456 // TODO: Move to normal caching system
461 ATTR: function(match, curLoop, inplace, result, not, isXML){
462 var name = match[1].replace(/\\/g, "");
464 if ( !isXML && Expr.attrMap[name] ) {
465 match[1] = Expr.attrMap[name];
468 if ( match[2] === "~=" ) {
469 match[4] = " " + match[4] + " ";
474 PSEUDO: function(match, curLoop, inplace, result, not){
475 if ( match[1] === "not" ) {
476 // If we're dealing with a complex expression, or a simple one
477 if ( ( chunker.exec(match[3]) || "" ).length > 1 || /^\w/.test(match[3]) ) {
478 match[3] = Sizzle(match[3], null, null, curLoop);
480 var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not);
482 result.push.apply( result, ret );
486 } else if ( Expr.match.POS.test( match[0] ) || Expr.match.CHILD.test( match[0] ) ) {
492 POS: function(match){
493 match.unshift( true );
498 enabled: function(elem){
499 return elem.disabled === false && elem.type !== "hidden";
501 disabled: function(elem){
502 return elem.disabled === true;
504 checked: function(elem){
505 return elem.checked === true;
507 selected: function(elem){
508 // Accessing this property makes selected-by-default
509 // options in Safari work properly
510 elem.parentNode.selectedIndex;
511 return elem.selected === true;
513 parent: function(elem){
514 return !!elem.firstChild;
516 empty: function(elem){
517 return !elem.firstChild;
519 has: function(elem, i, match){
520 return !!Sizzle( match[3], elem ).length;
522 header: function(elem){
523 return (/h\d/i).test( elem.nodeName );
525 text: function(elem){
526 return "text" === elem.type;
528 radio: function(elem){
529 return "radio" === elem.type;
531 checkbox: function(elem){
532 return "checkbox" === elem.type;
534 file: function(elem){
535 return "file" === elem.type;
537 password: function(elem){
538 return "password" === elem.type;
540 submit: function(elem){
541 return "submit" === elem.type;
543 image: function(elem){
544 return "image" === elem.type;
546 reset: function(elem){
547 return "reset" === elem.type;
549 button: function(elem){
550 return "button" === elem.type || elem.nodeName.toLowerCase() === "button";
552 input: function(elem){
553 return (/input|select|textarea|button/i).test(elem.nodeName);
557 first: function(elem, i){
560 last: function(elem, i, match, array){
561 return i === array.length - 1;
563 even: function(elem, i){
566 odd: function(elem, i){
569 lt: function(elem, i, match){
570 return i < match[3] - 0;
572 gt: function(elem, i, match){
573 return i > match[3] - 0;
575 nth: function(elem, i, match){
576 return match[3] - 0 === i;
578 eq: function(elem, i, match){
579 return match[3] - 0 === i;
583 PSEUDO: function(elem, match, i, array){
584 var name = match[1], filter = Expr.filters[ name ];
587 return filter( elem, i, match, array );
588 } else if ( name === "contains" ) {
589 return (elem.textContent || elem.innerText || Sizzle.getText([ elem ]) || "").indexOf(match[3]) >= 0;
590 } else if ( name === "not" ) {
593 for ( var j = 0, l = not.length; j < l; j++ ) {
594 if ( not[j] === elem ) {
601 Sizzle.error( "Syntax error, unrecognized expression: " + name );
604 CHILD: function(elem, match){
605 var type = match[1], node = elem;
609 while ( (node = node.previousSibling) ) {
610 if ( node.nodeType === 1 ) {
614 if ( type === "first" ) {
619 while ( (node = node.nextSibling) ) {
620 if ( node.nodeType === 1 ) {
626 var first = match[2], last = match[3];
628 if ( first === 1 && last === 0 ) {
632 var doneName = match[0],
633 parent = elem.parentNode;
635 if ( parent && (parent.sizcache !== doneName || !elem.nodeIndex) ) {
637 for ( node = parent.firstChild; node; node = node.nextSibling ) {
638 if ( node.nodeType === 1 ) {
639 node.nodeIndex = ++count;
642 parent.sizcache = doneName;
645 var diff = elem.nodeIndex - last;
649 return ( diff % first === 0 && diff / first >= 0 );
653 ID: function(elem, match){
654 return elem.nodeType === 1 && elem.getAttribute("id") === match;
656 TAG: function(elem, match){
657 return (match === "*" && elem.nodeType === 1) || elem.nodeName.toLowerCase() === match;
659 CLASS: function(elem, match){
660 return (" " + (elem.className || elem.getAttribute("class")) + " ")
661 .indexOf( match ) > -1;
663 ATTR: function(elem, match){
665 result = Expr.attrHandle[ name ] ?
666 Expr.attrHandle[ name ]( elem ) :
667 elem[ name ] != null ?
669 elem.getAttribute( name ),
674 return result == null ?
679 value.indexOf(check) >= 0 :
681 (" " + value + " ").indexOf(check) >= 0 :
683 value && result !== false :
687 value.indexOf(check) === 0 :
689 value.substr(value.length - check.length) === check :
691 value === check || value.substr(0, check.length + 1) === check + "-" :
694 POS: function(elem, match, i, array){
695 var name = match[2], filter = Expr.setFilters[ name ];
698 return filter( elem, i, match, array );
704 var origPOS = Expr.match.POS,
705 fescape = function(all, num){
706 return "\\" + (num - 0 + 1);
709 for ( var type in Expr.match ) {
710 Expr.match[ type ] = new RegExp( Expr.match[ type ].source + (/(?![^\[]*\])(?![^\(]*\))/.source) );
711 Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, fescape) );
714 var makeArray = function(array, results) {
715 array = Array.prototype.slice.call( array, 0 );
718 results.push.apply( results, array );
725 // Perform a simple check to determine if the browser is capable of
726 // converting a NodeList to an array using builtin methods.
727 // Also verifies that the returned array holds DOM nodes
728 // (which is not the case in the Blackberry browser)
730 Array.prototype.slice.call( document.documentElement.childNodes, 0 )[0].nodeType;
732 // Provide a fallback method if it does not work
734 makeArray = function(array, results) {
735 var ret = results || [], i = 0;
737 if ( toString.call(array) === "[object Array]" ) {
738 Array.prototype.push.apply( ret, array );
740 if ( typeof array.length === "number" ) {
741 for ( var l = array.length; i < l; i++ ) {
742 ret.push( array[i] );
745 for ( ; array[i]; i++ ) {
746 ret.push( array[i] );
757 if ( document.documentElement.compareDocumentPosition ) {
758 sortOrder = function( a, b ) {
759 if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) {
763 return a.compareDocumentPosition ? -1 : 1;
766 var ret = a.compareDocumentPosition(b) & 4 ? -1 : a === b ? 0 : 1;
772 } else if ( "sourceIndex" in document.documentElement ) {
773 sortOrder = function( a, b ) {
774 if ( !a.sourceIndex || !b.sourceIndex ) {
778 return a.sourceIndex ? -1 : 1;
781 var ret = a.sourceIndex - b.sourceIndex;
787 } else if ( document.createRange ) {
788 sortOrder = function( a, b ) {
789 if ( !a.ownerDocument || !b.ownerDocument ) {
793 return a.ownerDocument ? -1 : 1;
796 var aRange = a.ownerDocument.createRange(), bRange = b.ownerDocument.createRange();
797 aRange.setStart(a, 0);
799 bRange.setStart(b, 0);
801 var ret = aRange.compareBoundaryPoints(Range.START_TO_END, bRange);
809 // Utility function for retreiving the text value of an array of DOM nodes
810 Sizzle.getText = function( elems ) {
813 for ( var i = 0; elems[i]; i++ ) {
816 // Get the text from text nodes and CDATA nodes
817 if ( elem.nodeType === 3 || elem.nodeType === 4 ) {
818 ret += elem.nodeValue;
820 // Traverse everything else, except comment nodes
821 } else if ( elem.nodeType !== 8 ) {
822 ret += Sizzle.getText( elem.childNodes );
829 // Check to see if the browser returns elements by name when
830 // querying by getElementById (and provide a workaround)
832 // We're going to inject a fake input element with a specified name
833 var form = document.createElement("div"),
834 id = "script" + (new Date()).getTime();
835 form.innerHTML = "<a name='" + id + "'/>";
837 // Inject it into the root element, check its status, and remove it quickly
838 var root = document.documentElement;
839 root.insertBefore( form, root.firstChild );
841 // The workaround has to do additional checks after a getElementById
842 // Which slows things down for other browsers (hence the branching)
843 if ( document.getElementById( id ) ) {
844 Expr.find.ID = function(match, context, isXML){
845 if ( typeof context.getElementById !== "undefined" && !isXML ) {
846 var m = context.getElementById(match[1]);
847 return m ? m.id === match[1] || typeof m.getAttributeNode !== "undefined" && m.getAttributeNode("id").nodeValue === match[1] ? [m] : undefined : [];
851 Expr.filter.ID = function(elem, match){
852 var node = typeof elem.getAttributeNode !== "undefined" && elem.getAttributeNode("id");
853 return elem.nodeType === 1 && node && node.nodeValue === match;
857 root.removeChild( form );
858 root = form = null; // release memory in IE
862 // Check to see if the browser returns only elements
863 // when doing getElementsByTagName("*")
865 // Create a fake element
866 var div = document.createElement("div");
867 div.appendChild( document.createComment("") );
869 // Make sure no comments are found
870 if ( div.getElementsByTagName("*").length > 0 ) {
871 Expr.find.TAG = function(match, context){
872 var results = context.getElementsByTagName(match[1]);
874 // Filter out possible comments
875 if ( match[1] === "*" ) {
878 for ( var i = 0; results[i]; i++ ) {
879 if ( results[i].nodeType === 1 ) {
880 tmp.push( results[i] );
891 // Check to see if an attribute returns normalized href attributes
892 div.innerHTML = "<a href='#'></a>";
893 if ( div.firstChild && typeof div.firstChild.getAttribute !== "undefined" &&
894 div.firstChild.getAttribute("href") !== "#" ) {
895 Expr.attrHandle.href = function(elem){
896 return elem.getAttribute("href", 2);
900 div = null; // release memory in IE
903 if ( document.querySelectorAll ) {
905 var oldSizzle = Sizzle, div = document.createElement("div");
906 div.innerHTML = "<p class='TEST'></p>";
908 // Safari can't handle uppercase or unicode characters when
910 if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) {
914 Sizzle = function(query, context, extra, seed){
915 context = context || document;
917 // Only use querySelectorAll on non-XML documents
918 // (ID selectors don't work in non-HTML documents)
919 if ( !seed && context.nodeType === 9 && !Sizzle.isXML(context) ) {
921 return makeArray( context.querySelectorAll(query), extra );
925 return oldSizzle(query, context, extra, seed);
928 for ( var prop in oldSizzle ) {
929 Sizzle[ prop ] = oldSizzle[ prop ];
932 div = null; // release memory in IE
937 var div = document.createElement("div");
939 div.innerHTML = "<div class='test e'></div><div class='test'></div>";
941 // Opera can't find a second classname (in 9.6)
942 // Also, make sure that getElementsByClassName actually exists
943 if ( !div.getElementsByClassName || div.getElementsByClassName("e").length === 0 ) {
947 // Safari caches class attributes, doesn't catch changes (in 3.2)
948 div.lastChild.className = "e";
950 if ( div.getElementsByClassName("e").length === 1 ) {
954 Expr.order.splice(1, 0, "CLASS");
955 Expr.find.CLASS = function(match, context, isXML) {
956 if ( typeof context.getElementsByClassName !== "undefined" && !isXML ) {
957 return context.getElementsByClassName(match[1]);
961 div = null; // release memory in IE
964 function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
965 for ( var i = 0, l = checkSet.length; i < l; i++ ) {
966 var elem = checkSet[i];
972 if ( elem.sizcache === doneName ) {
973 match = checkSet[elem.sizset];
977 if ( elem.nodeType === 1 && !isXML ){
978 elem.sizcache = doneName;
982 if ( elem.nodeName.toLowerCase() === cur ) {
995 function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
996 for ( var i = 0, l = checkSet.length; i < l; i++ ) {
997 var elem = checkSet[i];
1003 if ( elem.sizcache === doneName ) {
1004 match = checkSet[elem.sizset];
1008 if ( elem.nodeType === 1 ) {
1010 elem.sizcache = doneName;
1013 if ( typeof cur !== "string" ) {
1014 if ( elem === cur ) {
1019 } else if ( Sizzle.filter( cur, [elem] ).length > 0 ) {
1028 checkSet[i] = match;
1033 Sizzle.contains = document.compareDocumentPosition ? function(a, b){
1034 return !!(a.compareDocumentPosition(b) & 16);
1036 return a !== b && (a.contains ? a.contains(b) : true);
1039 Sizzle.isXML = function(elem){
1040 // documentElement is verified for cases where it doesn't yet exist
1041 // (such as loading iframes in IE - #4833)
1042 var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement;
1043 return documentElement ? documentElement.nodeName !== "HTML" : false;
1046 var posProcess = function(selector, context){
1047 var tmpSet = [], later = "", match,
1048 root = context.nodeType ? [context] : context;
1050 // Position selectors must be done after the filter
1051 // And so must :not(positional) so we move all PSEUDOs to the end
1052 while ( (match = Expr.match.PSEUDO.exec( selector )) ) {
1054 selector = selector.replace( Expr.match.PSEUDO, "" );
1057 selector = Expr.relative[selector] ? selector + "*" : selector;
1059 for ( var i = 0, l = root.length; i < l; i++ ) {
1060 Sizzle( selector, root[i], tmpSet );
1063 return Sizzle.filter( later, tmpSet );
1068 window.tinymce.dom.Sizzle = Sizzle;