Skip to content

Instantly share code, notes, and snippets.

@CharlieGreenman
Created September 3, 2019 12:55
Show Gist options
  • Save CharlieGreenman/1c8ab1b874f4e5c2d396fa9f931d3dc0 to your computer and use it in GitHub Desktop.
Save CharlieGreenman/1c8ab1b874f4e5c2d396fa9f931d3dc0 to your computer and use it in GitHub Desktop.
mat-base-typography part 1
@mixin mat-base-typography($config, $selector: '.mat-typography') {
.mat-h1, .mat-headline, #{$selector} h1 {
@include mat-typography-level-to-styles($config, headline);
margin: 0 0 16px;
}
.mat-h2, .mat-title, #{$selector} h2 {
@include mat-typography-level-to-styles($config, title);
margin: 0 0 16px;
}
.mat-h3, .mat-subheading-2, #{$selector} h3 {
@include mat-typography-level-to-styles($config, subheading-2);
margin: 0 0 16px;
}
.mat-h4, .mat-subheading-1, #{$selector} h4 {
@include mat-typography-level-to-styles($config, subheading-1);
margin: 0 0 16px;
}
// ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment