I'm struggling with the next problem. I'm trying to change the color of the angular material 2 radio button on PROPER way, without overriding css. By default, it uses accent color of the material theme, but I want to use the primary.
Other components have color property like checkbox, button, etc...
Thanks in advance.
Set Radio Button Selected in Angular It will set selected value of radio button in Angular's Reactive Forms. registrationForm = this. fb. group({ gender: ['male'] // Pass the name value in form control array. })
<mat-radio-button> is used to select one option when we have multiple options. Approach: First, install the angular material using the above-mentioned command. After completing the installation, Import 'MatRadioModule' from '@angular/material/radio' in the app.
In case anyone else stumbles across this issue, you can now use the color property on MatRadioButton components. Here is the link to the GitHub issue where I was corrected:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With