You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: categories.xml
+41-2
Original file line number
Diff line number
Diff line change
@@ -71,6 +71,11 @@
71
71
<p>For more information, see the Release Notes/Changelog at <a href="https://blog.jquery.com/2016/06/09/jquery-3-0-final-released/">https://blog.jquery.com/2016/06/09/jquery-3-0-final-released/</a></p>
<desc><![CDATA[All the aspects of the API that were deprecated in the corresponding version of jQuery.
76
+
<p>For more information, see the Release Notes/Changelog at <a href="https://blog.jquery.com/2017/03/16/jquery-3-2-0-is-out/">https://blog.jquery.com/2017/03/16/jquery-3-2-0-is-out/</a></p>
<desc><![CDATA[All the aspects of the API that were deprecated in the corresponding version of jQuery.
76
81
<p>For more information, see the Release Notes/Changelog at <a href="https://blog.jquery.com/2018/01/19/jquery-3-3-0-a-fragrant-bouquet-of-deprecations-and-is-that-a-new-feature/">https://blog.jquery.com/2018/01/19/jquery-3-3-0-a-fragrant-bouquet-of-deprecations-and-is-that-a-new-feature/</a></p>
@@ -81,6 +86,11 @@
81
86
<p>For more information, see the Release Notes/Changelog at <a href="https://blog.jquery.com/2019/04/10/jquery-3-4-0-released/">https://blog.jquery.com/2019/04/10/jquery-3-4-0-released/</a></p>
<desc><![CDATA[All the aspects of the API that were deprecated in the corresponding version of jQuery.
91
+
<p>For more information, see the Release Notes/Changelog at <a href="https://blog.jquery.com/2020/04/10/jquery-3-5-0-released/">https://blog.jquery.com/2020/04/10/jquery-3-5-0-released/</a></p>
92
+
]]></desc>
93
+
</category>
84
94
</category>
85
95
<categoryname="Dimensions"slug="dimensions">
86
96
<desc><![CDATA[These methods are used to get and set the CSS dimensions for the various properties.]]></desc>
@@ -429,7 +439,7 @@ var files = event.originalEvent.dataTransfer.files;
429
439
<hr/>
430
440
]]></desc>
431
441
</category>
432
-
<categoryname="Version 1.12 & 2.2"slug="1.12-2.2">
442
+
<categoryname="Version 1.12 & 2.2"slug="1.12-and-2.2">
433
443
<desc><![CDATA[
434
444
<p>Aspects of the API that were changed in the corresponding versions of jQuery. Changes in jQuery 1.12 and 2.2 includes performance improvements of the selector engine, manipulation of class names for SVG elements, support for the Symbol type and iterators added in ES2015, and a new hook has been added for filtering HTML. A <a href="https://github.com/jquery/jquery-migrate">jQuery Migrate Plugin</a> was offered to help developers with a transitional upgrade path.
435
445
</p>
@@ -447,7 +457,36 @@ var files = event.originalEvent.dataTransfer.files;
447
457
</category>
448
458
<categoryname="Version 3.1"slug="3.1">
449
459
<desc><![CDATA[
450
-
<p><a href="/jQuery.readyException">jQuery.readyException</a> was added.</p>
460
+
<p>Aspects of the API that were changed in the corresponding version of jQuery. Version 3.1 added the <a href="/jQuery.readyException">jQuery.readyException</a> API.</p>
461
+
<p>For more information, see the <a href="https://blog.jquery.com/2016/07/07/jquery-3-1-0-released-no-more-silent-errors/">Release Notes/Changelog</a></p>
462
+
<hr/>
463
+
]]></desc>
464
+
</category>
465
+
<categoryname="Version 3.2"slug="3.2">
466
+
<desc><![CDATA[
467
+
<p>Aspects of the API that were changed in the corresponding version of jQuery. Version 3.2 added support for custom CSS properties, made <code>.contents()</code> work on the <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/template"><code><template></code> element</a> & made <code>.width()</code> & <code>.height()</code> ignore CSS transforms. A few APIs were deprecated. The deprecated module was added back to the slim build.</p>
468
+
<p>For more information, see the <a href="https://blog.jquery.com/2017/03/16/jquery-3-2-0-is-out/">Release Notes/Changelog</a></p>
469
+
<hr/>
470
+
]]></desc>
471
+
</category>
472
+
<categoryname="Version 3.3"slug="3.3">
473
+
<desc><![CDATA[
474
+
<p>Aspects of the API that were changed in the corresponding version of jQuery. <code>.addClass()</code>, <code>.removeClass()</code> & <code>.toggleClass()</code> now work on arrays of classes; a few APIs were deprecated.</p>
475
+
<p>For more information, see the <a href="https://blog.jquery.com/2018/01/19/jquery-3-3-0-a-fragrant-bouquet-of-deprecations-and-is-that-a-new-feature/">Release Notes/Changelog</a></p>
476
+
<hr/>
477
+
]]></desc>
478
+
</category>
479
+
<categoryname="Version 3.4"slug="3.4">
480
+
<desc><![CDATA[
481
+
<p>Aspects of the API that were changed in the corresponding version of jQuery. <code>nonce</code> & <code>nomodule</code> attributes are now preserved during script manipulation, layout thrashing was eliminated in some cases in <code>.width()</code> & <code>.height()</code> APIs. Radio elements state is now updated before event handlers run. Passing data now works when triggering all events, including <code>focus</code>. A minor security fix is also included.</p>
482
+
<p>For more information, see the <a href="https://blog.jquery.com/2019/04/10/jquery-3-4-0-released/">Release Notes/Changelog</a></p>
483
+
<hr/>
484
+
]]></desc>
485
+
</category>
486
+
<categoryname="Version 3.5"slug="3.5">
487
+
<desc><![CDATA[
488
+
<p>Aspects of the API that were changed in the corresponding version of jQuery. Security fixes, new <code>.even()</code> & <code>.odd()</code> methods; <code>jQuery.globalEval</code> now accepts context; unsuccessful HTTP script responses are no longer evaluated; performance improvements. <code>jQuery.trim</code> is now deprecated.</p>
489
+
<p>For more information, see the <a href="https://jquery.com/upgrade-guide/3.5/">jQuery Core 3.5 Upgrade guide</a> and the <a href="https://blog.jquery.com/2020/04/10/jquery-3-5-0-released/">Release Notes/Changelog</a></p>
Copy file name to clipboardexpand all lines: entries/addClass.xml
+32-1
Original file line number
Diff line number
Diff line change
@@ -7,10 +7,16 @@
7
7
<desc>One or more space-separated classes to be added to the class attribute of each matched element.</desc>
8
8
</argument>
9
9
</signature>
10
+
<signature>
11
+
<added>3.3</added>
12
+
<argumentname="classNames"type="Array">
13
+
<desc>An array of classes to be added to the class attribute of each matched element.</desc>
14
+
</argument>
15
+
</signature>
10
16
<signature>
11
17
<added>1.4</added>
12
18
<argumentname="function"type="Function">
13
-
<desc>A function returning one or more space-separated class names to be added to the existing class name(s). Receives the index position of the element in the set and the existing class name(s) as arguments. Within the function, <code>this</code> refers to the current element in the set.</desc>
19
+
<desc>A function returning one or more space-separated classes or an array of classes to be added to the existing class name(s). Receives the index position of the element in the set and the existing class name(s) as arguments. Within the function, <code>this</code> refers to the current element in the set.</desc>
Copy file name to clipboardexpand all lines: entries/contents.xml
+2
Original file line number
Diff line number
Diff line change
@@ -8,6 +8,7 @@
8
8
<longdesc>
9
9
<p>Given a jQuery object that represents a set of DOM elements, the <code>.contents()</code> method allows us to search through the immediate children of these elements in the DOM tree and construct a new jQuery object from the matching elements. The <code>.contents()</code> and <code>.children()</code> methods are similar, except that the former includes text nodes and comment nodes as well as HTML elements in the resulting jQuery object. Please note that most jQuery operations don't support text nodes and comment nodes. The few that do will have an explicit note on their API documentation page.</p>
10
10
<p>The <code>.contents()</code> method can also be used to get the content document of an iframe, if the iframe is on the same domain as the main page.</p>
11
+
<p><strong>As of jQuery 3.2</strong>, <code>.contents()</code> returns contents of <code><template></code> elements as well.</p>
11
12
<p>Consider a simple <code><div></code> with a number of text nodes, each of which is separated by two line break elements (<code><br></code>):</p>
Copy file name to clipboardexpand all lines: entries/css.xml
+4
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,7 @@
23
23
<p>Retrieval of shorthand CSS properties (e.g., <code>margin</code>, <code>background</code>, <code>border</code>), although functional with some browsers, is not guaranteed. For example, if you want to retrieve the rendered <code>border-width</code>, use: <code>$( elem ).css( "borderTopWidth" )</code>, <code>$( elem ).css( "borderBottomWidth" )</code>, and so on.</p>
24
24
<p>An element should be connected to the DOM when calling <code>.css()</code> on it. If it isn't, jQuery may throw an error.</p>
25
25
<p><strong>As of jQuery 1.9</strong>, passing an array of style properties to <code>.css()</code> will result in an object of property-value pairs. For example, to retrieve all four rendered <code>border-width</code> values, you could use <code>$( elem ).css([ "borderTopWidth", "borderRightWidth", "borderBottomWidth", "borderLeftWidth" ])</code>. </p>
26
+
<p><strong>As of jQuery 3.2</strong>, <ahref="https://developer.mozilla.org/en-US/docs/Web/CSS/--*">CSS Custom Properties</a> (also called CSS Variables) are supported: <code>$( "p" ).css( "--custom-property" )</code>. Note that you need to provide the property name as-is, camelCasing it won't work as it does for regular CSS properties.</p>
26
27
</longdesc>
27
28
<example>
28
29
<desc>Get the background color of a clicked div.</desc>
<p>This example sets the widths of the matched elements to incrementally larger values.</p>
159
161
<p><strong>Note: </strong>If nothing is returned in the setter function (ie. <code>function( index, style ){} )</code>, or if <code>undefined</code> is returned, the current value is not changed. This is useful for selectively setting values only when certain criteria are met.</p>
162
+
<p><strong>As of jQuery 3.2</strong>, <ahref="https://developer.mozilla.org/en-US/docs/Web/CSS/--*">CSS Custom Properties</a> (also called CSS Variables) are supported: <code>$( "p" ).css( "--custom-property", "value" )</code>. Note that you need to provide the property name as-is, camelCasing it won't work as it does for regular CSS properties.</p>
160
163
</longdesc>
161
164
<example>
162
165
<desc>Change the color of any paragraph to red on mouseover event.</desc>
Copy file name to clipboardexpand all lines: entries/eq-selector.xml
+3-1
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,9 @@
17
17
</signature>
18
18
<desc>Select the element at index <code>n</code> within the matched set.</desc>
19
19
<longdesc>
20
-
<p><strong>As of jQuery 3.4</strong>, the <code>:eq</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/eq/"><code>.eq()</code></a>.</p>
20
+
<divclass="warning">
21
+
<p><strong>As of jQuery 3.4</strong>, the <code>:eq</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/eq/"><code>.eq()</code></a>.</p>
22
+
</div>
21
23
<p>The index-related selectors (<code>:eq()</code>, <code>:lt()</code>, <code>:gt()</code>, <code>:even</code>, <code>:odd</code>) filter the set of elements that have matched the expressions that precede them. They narrow the set down based on the order of the elements within this matched set. For example, if elements are first selected with a class selector (<code>.myclass</code>) and four elements are returned, these elements are given indices <code>0</code> through <code>3</code> for the purposes of these selectors.</p>
22
24
<p>Note that since JavaScript arrays use <em>0-based indexing</em>, these selectors reflect that fact. This is why <code>$( ".myclass:eq(1)" )</code> selects the second element in the document with the class myclass, rather than the first. In contrast, <code>:nth-child(n)</code> uses <em>1-based indexing</em> to conform to the CSS specification.</p>
23
25
<p>Prior to jQuery 1.8, the <code>:eq(index)</code> selector did <em>not</em> accept a negative value for <code>index</code> (though the <ahref="/eq/"><code>.eq(index)</code></a> method did).</p>
Copy file name to clipboardexpand all lines: entries/even-selector.xml
+4-1
Original file line number
Diff line number
Diff line change
@@ -5,8 +5,11 @@
5
5
<signature>
6
6
<added>1.0</added>
7
7
</signature>
8
-
<desc>Selects even elements, zero-indexed. See also <ahref="/Selectors/odd/">odd</a>.</desc>
8
+
<desc>Selects even elements, zero-indexed. See also <ahref="/odd-selector/"><code>:odd</code></a>.</desc>
9
9
<longdesc>
10
+
<divclass="warning">
11
+
<p><strong>As of jQuery 3.4</strong>, the <code>:even</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/even/"><code>.even()</code></a> (available in jQuery 3.5.0 or newer).</p>
12
+
</div>
10
13
<p>In particular, note that the <em>0-based indexing</em> means that, counter-intuitively, <code>:even</code> selects the first element, third element, and so on within the matched set.</p>
<desc>Reduce the set of matched elements to the even ones in the set, numbered from zero.</desc>
8
+
<longdesc>
9
+
<p>Given a jQuery object that represents a set of DOM elements, the <code>.even()</code> method constructs a new jQuery object from the even elements in that set. Counting starts from zero!</p>
10
+
<p>Consider a page with a simple list on it:</p>
11
+
<pre><code>
12
+
<ul>
13
+
<li>list item 1</li>
14
+
<li>list item 2</li>
15
+
<li>list item 3</li>
16
+
<li>list item 4</li>
17
+
<li>list item 5</li>
18
+
</ul>
19
+
</code></pre>
20
+
<p>We can apply this method to the set of list items:</p>
<p>The result of this call is a red background for items 1, 3, and 5, as they match the selector (recall that <code>:even</code> and <code>:odd</code> use 0-based indexing).</p>
47
+
<p>The result of this call is a red background for items 2, 4, and 6, as they match the selector.</p>
48
48
<h4id="using-filter-function">Using a Filter Function</h4>
49
49
<p>The second form of this method allows us to filter elements against a function rather than a selector. For each element, if the function returns <code>true</code> (or a "truthy" value), the element will be included in the filtered set; otherwise, it will be excluded. Suppose we have a somewhat more involved HTML snippet:</p>
Copy file name to clipboardexpand all lines: entries/first-selector.xml
+3-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,9 @@
7
7
</signature>
8
8
<desc>Selects the first matched DOM element.</desc>
9
9
<longdesc>
10
-
<p><strong>As of jQuery 3.4</strong>, the <code>:first</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/first/"><code>.first()</code></a>.</p>
10
+
<divclass="warning">
11
+
<p><strong>As of jQuery 3.4</strong>, the <code>:first</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/first/"><code>.first()</code></a>.</p>
12
+
</div>
11
13
<p>The <code>:first</code> pseudo-class is equivalent to <code>:eq( 0 )</code>. It could also be written as <code>:lt( 1 )</code>. While this matches only a single element, <ahref="/first-child-selector/">:first-child</a> can match more than one: One for each parent.</p>
Copy file name to clipboardexpand all lines: entries/gt-selector.xml
+3-1
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,9 @@
17
17
</signature>
18
18
<desc>Select all elements at an index greater than <code>index</code> within the matched set.</desc>
19
19
<longdesc>
20
-
<p><strong>As of jQuery 3.4</strong>, the <code>:gt</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/slice/"><code>.slice()</code></a>. For example, <code>:gt(3)</code> can be replaced with a call to <code>.slice( 4 )</code> (the provided index needs to be increased by one).</p>
20
+
<divclass="warning">
21
+
<p><strong>As of jQuery 3.4</strong>, the <code>:gt</code> pseudo-class is deprecated. Remove it from your selectors and filter the results later using <ahref="/slice/"><code>.slice()</code></a>. For example, <code>:gt(3)</code> can be replaced with a call to <code>.slice( 4 )</code> (the provided index needs to be increased by one).</p>
0 commit comments