I need to implement a feature where all classes on a button are disabled if a specific class is present. I attempted to disable all classes, but it seems like I made an error somewhere.
Jquery:
if ($('.lgi_btn_cta_toggle').hasClass('lgi_cta_inactive')) {
$(this).attr("disabled", true);
}
HTML
<button data-action="Hyperlink" class="lgi_btn_cta_add add-sub lgi_btn_cta lgi_cta_inactive clearboth"><span>Hey</span></button>
CSS:
.lgi_btn_cta_remove:after {
font-family: "MaterialIcons";
content: "\e14c";
color: #ffffff;
font-weight: bold;
min-width: 43px;
height: 44px;
background: #5a9996;
position: absolute;
margin-top: -9px;
margin-left: 17px;
border-radius: 50px 18px 18px 50px;
padding-top: 10px !important;