Skip to content

Commit a16c3b4

Browse files
Connor CartwrightAurelioDeRosa
authored andcommitted
disabled: Described when an element is actually disabled
Fixes jquerygh-734 Closes jquerygh-920
1 parent 0d78b3a commit a16c3b4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

entries/disabled-selector.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
<longdesc>
1010
<p>As with other pseudo-class selectors (those that begin with a ":"), it is recommended to precede it with a tag name or some other selector; otherwise, the universal selector ("*") is implied. In other words, the bare <code>$(':disabled')</code> is equivalent to <code>$('*:disabled')</code>, so <code>$('input:disabled')</code> or similar should be used instead. </p>
1111

12-
<p>Although their resulting selections are usually the same, the <code>:disabled</code> selector is subtly different from the <code>[disabled]</code> attribute selector; <code>:disabled</code> checks the boolean (true/false) value of the element's disabled property while <code>[disabled]</code> checks for the existence of the disabled attribute.</p>
12+
<p>Although their resulting selections are usually the same, the <code>:disabled</code> selector is subtly different from the <code>[disabled]</code> attribute selector;<code>:disabled</code> matches elements that are <a href="https://html.spec.whatwg.org/multipage/scripting.html#disabled-elements">actually disabled</a> while <code>[disabled]</code> only checks for the existence of the disabled attribute.</p>
1313

14-
<p>The <code>:disabled</code> selector should only be used for selecting HTML elements that support the <code>disabled</code> attribute (<code>&lt;button&gt;</code>, <code>&lt;input&gt;</code>, <code>&lt;optgroup&gt;</code>, <code>&lt;option&gt;</code>, <code>&lt;select&gt;</code>, and <code>&lt;textarea&gt;</code>).</p>
14+
<p>The <code>:disabled</code> selector should only be used for selecting HTML elements that support the <code>disabled</code> attribute (<code>&lt;button&gt;</code>, <code>&lt;input&gt;</code>, <code>&lt;optgroup&gt;</code>, <code>&lt;option&gt;</code>, <code>&lt;select&gt;</code>, <code>&lt;textarea&gt;</code>, <code>&lt;menuitem&gt;</code>, and <code>&lt;fieldset&gt;</code>).</p>
1515

1616
</longdesc>
1717
<example>

0 commit comments

Comments
 (0)