@types/jquery 3.3.27 → 3.3.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
jquery/JQuery.d.ts CHANGED
@@ -83,6 +83,7 @@ $( document.body )
83
83
  * @since 1.4
84
84
  */
85
85
  add(selector: JQuery.Selector, context: Element): this;
86
+ // TODO: The return type should reflect newly selected types.
86
87
  /**
87
88
  * Create a new jQuery object with elements added to the set of matched elements.
88
89
  * @param selector_elements_html_selection _@param_ `selector_elements_html_selection`
@@ -226,7 +227,7 @@ collection.css( "background", "yellow" );
226
227
  </html>
227
228
  ```
228
229
  */
229
- add(selector_elements_html_selection: JQuery.Selector | JQuery.TypeOrArray<Element> | JQuery.htmlString | JQuery): this;
230
+ add(selector_elements_html_selection: JQuery.Selector | JQuery.TypeOrArray<Element> | JQuery.htmlString | JQuery | JQuery.Node): this;
230
231
  /**
231
232
  * Add the previous set of elements on the stack to the current set, optionally filtered by a selector.
232
233
  * @param selector A string containing a selector expression to match the current set of elements against.
@@ -5141,7 +5142,9 @@ $( "div b" )
5141
5142
  </html>
5142
5143
  ```
5143
5144
  */
5144
- html(htmlString_function: JQuery.htmlString | ((this: TElement, index: number, oldhtml: JQuery.htmlString) => JQuery.htmlString)): this;
5145
+ html(htmlString_function: JQuery.htmlString |
5146
+ JQuery.Node |
5147
+ ((this: TElement, index: number, oldhtml: JQuery.htmlString) => JQuery.htmlString | JQuery.Node)): this;
5145
5148
  /**
5146
5149
  * Get the HTML contents of the first element in the set of matched elements.
5147
5150
  * @see \`{@link https://api.jquery.com/html/ }\`
@@ -9990,7 +9993,14 @@ $( "button" ).on( "click", function() {
9990
9993
  </html>
9991
9994
  ```
9992
9995
  */
9993
- replaceWith(newContent_function: JQuery.htmlString | JQuery | JQuery.TypeOrArray<Element> | ((this: TElement) => any)): this;
9996
+ replaceWith(newContent_function: JQuery.htmlString |
9997
+ JQuery<JQuery.Node> |
9998
+ JQuery.TypeOrArray<Element> |
9999
+ JQuery.Node |
10000
+ ((this: TElement, index: number, oldhtml: JQuery.htmlString) => JQuery.htmlString |
10001
+ JQuery<JQuery.Node> |
10002
+ JQuery.TypeOrArray<Element> |
10003
+ JQuery.Node)): this;
9994
10004
  /**
9995
10005
  * Bind an event handler to the "resize" JavaScript event, or trigger that event on an element.
9996
10006
  * @param eventData An object containing data that will be passed to the event handler.
jquery/README.md CHANGED
@@ -8,9 +8,9 @@ This package contains type definitions for jquery (https://jquery.com).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jquery
9
9
 
10
10
  Additional Details
11
- * Last updated: Thu, 13 Dec 2018 21:22:38 GMT
11
+ * Last updated: Mon, 05 Aug 2019 20:07:11 GMT
12
12
  * Dependencies: @types/sizzle
13
13
  * Global values: $, Symbol, jQuery
14
14
 
15
15
  # Credits
16
- These definitions were written by Leonard Thieu <https://github.com/leonard-thieu>, Boris Yankov <https://github.com/borisyankov>, Christian Hoffmeister <https://github.com/choffmeister>, Steve Fenton <https://github.com/Steve-Fenton>, Diullei Gomes <https://github.com/Diullei>, Tass Iliopoulos <https://github.com/tasoili>, Jason Swearingen <https://github.com/jasons-novaleaf>, 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>, 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>, Dick van den Brink <https://github.com/DickvdBrink>, Thomas Schulz <https://github.com/King2500>, Terry Mun <https://github.com/terrymun>.
16
+ These definitions were written by Leonard Thieu <https://github.com/leonard-thieu>, Boris Yankov <https://github.com/borisyankov>, Christian Hoffmeister <https://github.com/choffmeister>, Steve Fenton <https://github.com/Steve-Fenton>, Diullei Gomes <https://github.com/Diullei>, Tass Iliopoulos <https://github.com/tasoili>, Jason Swearingen <https://github.com/jasons-novaleaf>, 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>, 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>, Dick van den Brink <https://github.com/DickvdBrink>, Thomas Schulz <https://github.com/King2500>, and Terry Mun <https://github.com/terrymun>.
jquery/legacy.d.ts CHANGED
@@ -167,9 +167,12 @@ interface JQueryMouseEventObject extends JQueryInputEventObject {
167
167
  * @deprecated ​ Deprecated. Use \`{@link JQuery.Event }\`.
168
168
  */
169
169
  interface JQueryKeyEventObject extends JQueryInputEventObject {
170
- char: any;
170
+ /** @deprecated */
171
+ char: string;
172
+ /** @deprecated */
171
173
  charCode: number;
172
- key: any;
174
+ key: string;
175
+ /** @deprecated */
173
176
  keyCode: number;
174
177
  }
175
178
  /**
jquery/misc.d.ts CHANGED
@@ -677,6 +677,7 @@ declare namespace JQuery {
677
677
  'setRequestHeader' | 'status' | 'statusText'>,
678
678
  Partial<Pick<XMLHttpRequest, 'responseXML'>> {
679
679
  responseJSON?: any;
680
+ abort(statusText?: string): void;
680
681
 
681
682
  /**
682
683
  * Determine the current state of a Deferred object.
@@ -5456,6 +5457,92 @@ $( "#checkMetaKey" ).click(function( event ) {
5456
5457
  type: 'mouseup';
5457
5458
  }
5458
5459
 
5460
+ // region DragEvent
5461
+ // #region DragEvent
5462
+
5463
+ interface DragEventBase<
5464
+ TDelegateTarget = any,
5465
+ TData = any,
5466
+ TCurrentTarget = any,
5467
+ TTarget = any
5468
+ > extends UIEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5469
+ originalEvent?: _DragEvent;
5470
+ }
5471
+
5472
+ interface DragEvent<
5473
+ TDelegateTarget = any,
5474
+ TData = any,
5475
+ TCurrentTarget = any,
5476
+ TTarget = any
5477
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5478
+ type: 'drag';
5479
+ }
5480
+
5481
+ interface DragEndEvent<
5482
+ TDelegateTarget = any,
5483
+ TData = any,
5484
+ TCurrentTarget = any,
5485
+ TTarget = any
5486
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5487
+ type: 'dragend';
5488
+ }
5489
+
5490
+ interface DragEnterEvent<
5491
+ TDelegateTarget = any,
5492
+ TData = any,
5493
+ TCurrentTarget = any,
5494
+ TTarget = any
5495
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5496
+ type: 'dragenter';
5497
+ }
5498
+
5499
+ interface DragExitEvent<
5500
+ TDelegateTarget = any,
5501
+ TData = any,
5502
+ TCurrentTarget = any,
5503
+ TTarget = any
5504
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5505
+ type: 'dragexit';
5506
+ }
5507
+
5508
+ interface DragLeaveEvent<
5509
+ TDelegateTarget = any,
5510
+ TData = any,
5511
+ TCurrentTarget = any,
5512
+ TTarget = any
5513
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5514
+ type: 'dragleave';
5515
+ }
5516
+
5517
+ interface DragOverEvent<
5518
+ TDelegateTarget = any,
5519
+ TData = any,
5520
+ TCurrentTarget = any,
5521
+ TTarget = any
5522
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5523
+ type: 'dragover';
5524
+ }
5525
+
5526
+ interface DragStartEvent<
5527
+ TDelegateTarget = any,
5528
+ TData = any,
5529
+ TCurrentTarget = any,
5530
+ TTarget = any
5531
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5532
+ type: 'dragstart';
5533
+ }
5534
+
5535
+ interface DropEvent<
5536
+ TDelegateTarget = any,
5537
+ TData = any,
5538
+ TCurrentTarget = any,
5539
+ TTarget = any
5540
+ > extends DragEventBase<TDelegateTarget, TData, TCurrentTarget, TTarget> {
5541
+ type: 'drop';
5542
+ }
5543
+
5544
+ // #endregion
5545
+
5459
5546
  // #endregion
5460
5547
 
5461
5548
  // region KeyboardEvent
@@ -6284,6 +6371,17 @@ $( "#checkMetaKey" ).click(function( event ) {
6284
6371
  mouseover: MouseOverEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6285
6372
  mouseup: MouseUpEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6286
6373
 
6374
+ // DragEvent
6375
+
6376
+ drag: DragEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6377
+ dragend: DragEndEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6378
+ dragenter: DragEnterEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6379
+ dragexit: DragExitEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6380
+ dragleave: DragLeaveEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6381
+ dragover: DragOverEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6382
+ dragstart: DragStartEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6383
+ drop: DropEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
6384
+
6287
6385
  // KeyboardEvent
6288
6386
 
6289
6387
  keydown: KeyDownEvent<TDelegateTarget, TData, TCurrentTarget, TTarget>;
@@ -6538,6 +6636,7 @@ declare const $: JQueryStatic;
6538
6636
  type _Event = Event;
6539
6637
  type _UIEvent = UIEvent;
6540
6638
  type _MouseEvent = MouseEvent;
6639
+ type _DragEvent = DragEvent;
6541
6640
  type _KeyboardEvent = KeyboardEvent;
6542
6641
  type _TouchEvent = TouchEvent;
6543
6642
  type _FocusEvent = FocusEvent;
jquery/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/jquery",
3
- "version": "3.3.27",
3
+ "version": "3.3.31",
4
4
  "description": "TypeScript definitions for jquery",
5
5
  "license": "MIT",
6
6
  "contributors": [
@@ -119,12 +119,13 @@
119
119
  "types": "index",
120
120
  "repository": {
121
121
  "type": "git",
122
- "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git"
122
+ "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
123
+ "directory": "types/jquery"
123
124
  },
124
125
  "scripts": {},
125
126
  "dependencies": {
126
127
  "@types/sizzle": "*"
127
128
  },
128
- "typesPublisherContentHash": "fd6a1f908df0d77b06c48fb865610f270ce817399f68bbd66f6ccd34f0df87b1",
129
+ "typesPublisherContentHash": "6f3ac74aa9f284b3450b4dcbcabc842bfc2a70fa2d92e745851044d2bb78e94b",
129
130
  "typeScriptVersion": "2.3"
130
131
  }