diff options
| author | Chris Rebert <[email protected]> | 2014-06-05 13:31:39 -0700 |
|---|---|---|
| committer | Chris Rebert <[email protected]> | 2014-06-06 17:23:28 -0700 |
| commit | 739bf379a93a2a396e23f0423167b3552eb88191 (patch) | |
| tree | 1104a4e92c08462478ae1fa1cacd12b324342475 /less/forms.less | |
| parent | ef436c761b9587fbd0234788ec8bed4696aec516 (diff) | |
| download | bootstrap-739bf379a93a2a396e23f0423167b3552eb88191.tar.xz bootstrap-739bf379a93a2a396e23f0423167b3552eb88191.zip | |
set not-allowed cursor on disabled radio+checkbox labels; fixes #13281
[skip validator] [skip sauce]
Diffstat (limited to 'less/forms.less')
| -rw-r--r-- | less/forms.less | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/less/forms.less b/less/forms.less index cb8a74fa1..b678d44fc 100644 --- a/less/forms.less +++ b/less/forms.less @@ -247,19 +247,35 @@ input[type="month"] { } // Apply same disabled cursor tweak as for inputs +// Some special care is needed because <label>s don't inherit their parent's `cursor`. // // Note: Neither radios nor checkboxes can be readonly. input[type="radio"], -input[type="checkbox"], -.radio, +input[type="checkbox"] { + &[disabled], + &.disabled, + fieldset[disabled] & { + cursor: not-allowed; + } +} +// These classes are used directly on <label>s .radio-inline, -.checkbox, .checkbox-inline { - &[disabled], + &.disabled, fieldset[disabled] & { cursor: not-allowed; } } +// These classes are used on elements with <label> descendants +.radio, +.checkbox { + &.disabled, + fieldset[disabled] & { + label { + cursor: not-allowed; + } + } +} // Form control sizing |
