JSFiddle - React, Tailwind, and code Playground
by Satpal Singh
HTML
<select id="Units">
<option value="Marketing">Marketing</option>
<option value="Finance">Finance</option>
<option value="Operations">Operations</option>
</select>
<input type="checkbox" class="dissable" value="1">chbx1
<br/>
<input type="checkbox" class="dissable" value="2">chbx2
<br/>
<input type="checkbox" class="dissable" value="3">chbx3
<br/>
<input type="checkbox" class="dissable" value="4">chbx4
<br/>
JavaScript
$("#Units").on("change", function () {
//Filter checkboxes whose value is 3 or 4
$(".dissable")
.filter(function(){
return $(this).val() == 3 || $(this).val() == 4;
}).prop("disabled", $(this).val() == "Finance"); //disable or enable based on condition
}).trigger('change');