MCPcopy Create free account
hub / github.com/TruthHun/BookStack / createPositionalPseudo

Function createPositionalPseudo

static/wangEditor/js/lib/jquery-2.2.1.js:986–1002  ·  view source on GitHub ↗

* Returns a function to use in pseudos for positionals * @param {Function} fn

( fn )

Source from the content-addressed store, hash-verified

984 * @param {Function} fn
985 */
986function createPositionalPseudo( fn ) {
987 return markFunction(function( argument ) {
988 argument = +argument;
989 return markFunction(function( seed, matches ) {
990 var j,
991 matchIndexes = fn( [], seed.length, argument ),
992 i = matchIndexes.length;
993
994 // Match elements found at the specified indexes
995 while ( i-- ) {
996 if ( seed[ (j = matchIndexes[i]) ] ) {
997 seed[j] = !(matches[j] = seed[j]);
998 }
999 }
1000 });
1001 });
1002}
1003
1004/**
1005 * Checks a node for validity as a Sizzle context

Callers 1

jquery-2.2.1.jsFile · 0.70

Calls 2

markFunctionFunction · 0.70
fnFunction · 0.50

Tested by

no test coverage detected