I have this checkbox code
<div class="checkbox-group">
<label class="fc-contain-sm checkbox-status">
<input type="checkbox" class="formjs-checkbox-sm" checked disabled>
<div class="fc-status-sm"></div>
<span class="checkbox-lable-sm">Disabled checkbox</span>
</label>
<label class="fc-contain-sm checkbox-status">
<input type="checkbox" class="formjs-checkbox-sm">
<div class="fc-status-sm"></div>
<span class="checkbox-lable-sm">Normal checkbox</span>
</label>
</div>
And i want to add class disabled to checkbox-lable-sm class if the checkbox is disabled using jquery
css
.checkbox-group .disabled {
cursor: not-allowed;
}
I have tried this code but it is not working
$('.checkbox-group > input:disabled.formjs-checkbox-sm').each(function(){
$(this).find('.checkbox-lable-sm').addBack().addClass("disabled");
});
span?