jQuery: coming on

This commit is contained in:
John Reilly
2014-03-17 14:25:38 +00:00
parent 09e0ce15f4
commit f48f188c6c
2 changed files with 66 additions and 2 deletions
+16
View File
@@ -3169,6 +3169,22 @@ function test_parseHTML() {
.appendTo( $log );
}
function test_not() {
$("li").not(":even").css("background-color", "red");
$("li").not(document.getElementById("notli"))
.css("background-color", "red");
$("div").not(".green, #blueone")
.css("border-color", "red");
$("p").not($("#selected")[0]);
$("p").not("#selected");
$("p").not($("div p.selected"));
}
function test_EventIsNewable() {
var ev = new jQuery.Event('click');
}
+50 -2
View File
@@ -3480,17 +3480,65 @@ interface JQuery {
*/
map(callback: (index: number, domElement: Element) => any): JQuery;
/**
* Get the immediately following sibling of each element in the set of matched elements. If a selector is provided, it retrieves the next sibling only if it matches that selector.
*
* @param selector A string containing a selector expression to match elements against.
*/
next(selector?: string): JQuery;
/**
* Get all following siblings of each element in the set of matched elements, optionally filtered by a selector.
*
* @param selector A string containing a selector expression to match elements against.
*/
nextAll(selector?: string): JQuery;
/**
* Get all following siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object passed.
*
* @param selector A string containing a selector expression to indicate where to stop matching following sibling elements.
* @param filter A string containing a selector expression to match elements against.
*/
nextUntil(selector?: string, filter?: string): JQuery;
/**
* Get all following siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object passed.
*
* @param element A DOM node or jQuery object indicating where to stop matching following sibling elements.
* @param filter A string containing a selector expression to match elements against.
*/
nextUntil(element?: Element, filter?: string): JQuery;
/**
* Get all following siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object passed.
*
* @param obj A DOM node or jQuery object indicating where to stop matching following sibling elements.
* @param filter A string containing a selector expression to match elements against.
*/
nextUntil(obj?: JQuery, filter?: string): JQuery;
/**
* Remove elements from the set of matched elements.
*
* @param selector A string containing a selector expression to match elements against.
*/
not(selector: string): JQuery;
not(func: (index: any) => any): JQuery;
not(element: any): JQuery;
/**
* Remove elements from the set of matched elements.
*
* @param func A function used as a test for each element in the set. this is the current DOM element.
*/
not(func: (index: number) => any): JQuery;
/**
* Remove elements from the set of matched elements.
*
* @param elements One or more DOM elements to remove from the matched set.
*/
not(...elements: Element[]): JQuery;
/**
* Remove elements from the set of matched elements.
*
* @param obj An existing jQuery object to match the current set of elements against.
*/
not(obj: JQuery): JQuery;
offsetParent(): JQuery;