Latest solutions
Latest comments
- @kacper-reiman@thomaspaysac
Hi Kacper,
The simplest solution I found was to add the "disabled" attribute to the submit button, make it unclickable using
pointer-events: none;
in CSS while disabled, and then make the JavaScript remove the disabled attribute using a simple for loop so that when any rating is chosen the disabled attribute is removed :userRatingChoice[i].addEventListener('click', function() { SUBMIT_BUTTON.removeAttribute('disabled');; }) }
Marked as helpful