mercredi 1 mars 2017

How to implement a smart disabling of radio buttons(checkboxes)?

Suppose I have a 5x5 matrix of radio buttons(checkboxes)

enter image description here

What I am trying to achieve is that, for example, when user chooses 'first' radio button on the first row, the options within this row are disabled and also he can't choose 'first' button on any of other rows.

For instance I press 'three' on the second row. Here's red spots representing what options are disabled at this moment.

enter image description here

How can this be achieved? I don't believe this is possible using pure Angular 2 features, so I would also like to know how to do that with Javascript.




Aucun commentaire:

Enregistrer un commentaire