0

In my Angular 14 application (with Angular Material) I defined a custom line-height to all the buttons. Then I updated from angular 14 to 15 (including angular material) and setting line-height in a button doesn't work anymore, i.e. it doesn't change the height of the button.

Here is a minimal example of the component containing the button:

import {Component} from '@angular/core';

/**
 * @title Basic buttons
 */
@Component({
  selector: 'button-overview-example',
  templateUrl: 'button-overview-example.html',
  styleUrls: ['button-overview-example.css'],
})
export class ButtonOverviewExample {}

<div class="example-button-row">
  <button mat-raised-button color="primary">Primary</button>
</div>
.mat-mdc-raised-button {
  line-height: 36px;
}

Would there be a possible way to fix this for all the buttons in order to look as similar as possible to what it was in version 14?

Here is a stackblitz with an example in v15:

https://stackblitz.com/edit/zfjwgj

André
  • 1,602
  • 2
  • 12
  • 26

0 Answers0