mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-10 11:40:16 +08:00
Merge pull request #1359 from johnnyreilly/master
jQuery: Added missing overloads with tests + contributors to head
This commit is contained in:
@@ -646,6 +646,7 @@ function test_change() {
|
||||
$('.target').change();
|
||||
});
|
||||
$("input[type='text']").change(function () { });
|
||||
$("input[type='text']").change();
|
||||
}
|
||||
|
||||
function test_children() {
|
||||
@@ -703,6 +704,13 @@ function test_click() {
|
||||
$("p").click();
|
||||
}
|
||||
|
||||
function test_submit() {
|
||||
$("#target").submit(function () {
|
||||
alert("Handler for .submit() called.");
|
||||
});
|
||||
$("#target").submit();
|
||||
}
|
||||
|
||||
function test_clone() {
|
||||
$('.hello').clone().appendTo('.goodbye');
|
||||
var $elem = $('#elem').data({ "arr": [1] }),
|
||||
@@ -895,6 +903,7 @@ function test_dblclick() {
|
||||
divdbl.dblclick(function () {
|
||||
divdbl.toggleClass('dbl');
|
||||
});
|
||||
$('#target').dblclick();
|
||||
}
|
||||
|
||||
function test_deferred() {
|
||||
|
||||
Vendored
+36
-1
@@ -13,7 +13,10 @@ See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */
|
||||
|
||||
// Typing for the jQuery library, version 2.0.x
|
||||
// Typing for the jQuery library, version 1.10.x / 2.0.x
|
||||
// Project: http://jquery.com/
|
||||
// Definitions by: Boris Yankov <https://github.com/borisyankov/>, Christian Hoffmeister <https://github.com/choffmeister>, Steve Fenton, Diullei Gomes <https://github.com/Diullei>, Tass Iliopoulos <https://github.com/tasoili>, Jason Swearingen, Sean Hill <https://github.com/seanski>, Guus Goossens <https://github.com/Guuz>, Kelly Summerlin <https://github.com/ksummerlin>, Basarat Ali Syed <https://github.com/basarat>, Nicholas Wolverson <https://github.com/nwolverson>, Derek Cicerone <https://github.com/derekcicerone>, Andrew Gaspar <https://github.com/AndrewGaspar>, James Harrison Fisher <https://github.com/jameshfisher>, Seikichi Kondo <https://github.com/seikichi>, Benjamin Jackman <https://github.com/benjaminjackman>, Poul Sorensen <https://github.com/s093294>, Josh Strobl <https://github.com/JoshStrobl>, John Reilly <https://github.com/johnnyreilly/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/*
|
||||
Interface for the AJAX setting that will configure the AJAX request
|
||||
@@ -656,6 +659,10 @@ interface JQuery {
|
||||
blur(handler: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
blur(eventData?: any, handler?: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "change" event on an element.
|
||||
*/
|
||||
change(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "change" JavaScript event
|
||||
*
|
||||
@@ -670,6 +677,10 @@ interface JQuery {
|
||||
*/
|
||||
change(eventData?: any, handler?: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "click" event on an element.
|
||||
*/
|
||||
click(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "click" JavaScript event
|
||||
*
|
||||
@@ -684,6 +695,10 @@ interface JQuery {
|
||||
*/
|
||||
click(eventData?: any, handler?: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "dblclick" event on an element.
|
||||
*/
|
||||
dblclick(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "dblclick" JavaScript event
|
||||
*
|
||||
@@ -700,6 +715,10 @@ interface JQuery {
|
||||
|
||||
delegate(selector: any, eventType: string, handler: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "focus" event on an element.
|
||||
*/
|
||||
focus(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "focus" JavaScript event
|
||||
*
|
||||
@@ -745,6 +764,10 @@ interface JQuery {
|
||||
hover(handlerIn: (eventObject: JQueryEventObject) => any, handlerOut: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
hover(handlerInOut: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "keydown" event on an element.
|
||||
*/
|
||||
keydown(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "keydown" JavaScript event
|
||||
*
|
||||
@@ -759,6 +782,10 @@ interface JQuery {
|
||||
*/
|
||||
keydown(eventData?: any, handler?: (eventObject: JQueryKeyEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "keypress" event on an element.
|
||||
*/
|
||||
keypress(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "keypress" JavaScript event
|
||||
*
|
||||
@@ -773,6 +800,10 @@ interface JQuery {
|
||||
*/
|
||||
keypress(eventData?: any, handler?: (eventObject: JQueryKeyEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "keyup" event on an element.
|
||||
*/
|
||||
keyup(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "keyup" JavaScript event
|
||||
*
|
||||
@@ -843,6 +874,10 @@ interface JQuery {
|
||||
select(handler: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
select(eventData?: any, handler?: (eventObject: JQueryEventObject) => any): JQuery;
|
||||
|
||||
/**
|
||||
* Trigger the "submit" event on an element.
|
||||
*/
|
||||
submit(): JQuery;
|
||||
/**
|
||||
* Bind an event handler to the "submit" JavaScript event
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user