mirror of
https://github.com/tenrok/bootstrap.git
synced 2026-06-08 17:22:31 +03:00
Add aria-pressed to single toggle buttons
also includes tiny fix/clarification to two existing unit tests for the .active class, adding data-toggle=“button” explicitly to the tested buttons Closes #14819.
This commit is contained in:
committed by
Heinrich Fenkart
parent
60bb69acd5
commit
e1d40f7633
@@ -60,6 +60,8 @@
|
||||
else $parent.find('.active').removeClass('active')
|
||||
}
|
||||
if (changed) $input.prop('checked', !this.$element.hasClass('active')).trigger('change')
|
||||
} else {
|
||||
this.$element.attr('aria-pressed', !this.$element.hasClass('active'))
|
||||
}
|
||||
|
||||
if (changed) this.$element.toggleClass('active')
|
||||
|
||||
Reference in New Issue
Block a user