mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-21 18:54:30 +01:00
button.js: Set disabled property in addition to disabled attribute to preserve behavior under jQuery 3 (#20278)
This code ought to have used .prop instead of .attr in the first place, but we can't get rid of the attr manipulation now due to backward compatibility constraints. Refs https://github.com/jquery/jquery-migrate/blob/3.0.0/warnings.md#jqmigrate-jqueryfnremoveattr-no-longer-sets-boolean-properties Refs #16834 [skip validator]
This commit is contained in:
parent
1956146787
commit
e67e3e9b19
@ -41,10 +41,10 @@
|
||||
|
||||
if (state == 'loadingText') {
|
||||
this.isLoading = true
|
||||
$el.addClass(d).attr(d, d)
|
||||
$el.addClass(d).attr(d, d).prop(d, true)
|
||||
} else if (this.isLoading) {
|
||||
this.isLoading = false
|
||||
$el.removeClass(d).removeAttr(d)
|
||||
$el.removeClass(d).removeAttr(d).prop(d, false)
|
||||
}
|
||||
}, this), 0)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user