Search code examples
angularangular-material

Angular Material Toogle Buttons with unwanted marks after minor update


I updated my Angular Material from 17.0 to 17.3 (only a minor update) and suddenly there are some hook/checkmarks in the mat-button-toggle buttons.

<mat-button-toggle class="btn-primary" [checked]="this.settings.value1===0" (click)="this.settings.value1=0">MyLabel</mat-button-toggle>

Before:

enter image description here

After:

enter image description here

In the documentation is no hint, how to remove these marks and restore the old style/behavior. How can I remove them or do I have to change the whole component and look for something else, if I don't want this marks?


Solution

  • In the 17.3 changelog there is description about that. Here is pr where it was added. https://github.com/angular/components/pull/28553

    You can remove those checkmark with [hideSingleSelectionIndicator]="true" or [hideMultipleSelectionIndicator]="true" added to mat-button-toggle-group.