I am trying to assign pseudo to the checkbox dynamically as below the color is not updating to the checkbox, please suggest
item.color = item.options.color;
$('input[type=checkbox]:checked + label::before').css("background-color", item.color);
Below is the CSS for reference where I am planning to put in jQuery as above:
input[type=checkbox]:checked + label::before {background-color:rgb(186,135,200);
border: none;box-shadow: none;}