|
19 | 19 |
|
20 | 20 | // Represents a collection of typography levels.
|
21 | 21 | // Defaults come from https://material.io/guidelines/style/typography.html
|
| 22 | +// Note: The spec doesn't mention letter spacing. The values here come from |
| 23 | +// eyeballing it until it looked exactly like the spec examples. |
22 | 24 | @function mat-typography-config(
|
23 | 25 | $font-family: 'Roboto, "Helvetica Neue", sans-serif',
|
24 |
| - $display-4: mat-typography-level(112px, 112px, 300), |
25 |
| - $display-3: mat-typography-level(56px, 56px, 400), |
26 |
| - $display-2: mat-typography-level(45px, 48px, 400), |
| 26 | + $display-4: mat-typography-level(112px, 112px, 300, $letter-spacing: -0.05em), |
| 27 | + $display-3: mat-typography-level(56px, 56px, 400, $letter-spacing: -0.02em), |
| 28 | + $display-2: mat-typography-level(45px, 48px, 400, $letter-spacing: -0.005em), |
27 | 29 | $display-1: mat-typography-level(34px, 40px, 400),
|
28 | 30 | $headline: mat-typography-level(24px, 32px, 400),
|
29 | 31 | $title: mat-typography-level(20px, 32px, 500),
|
|
130 | 132 | @include mat-typography-level-to-styles($config, caption);
|
131 | 133 | }
|
132 | 134 |
|
133 |
| - // Note: The spec doesn't mention letter spacing. The value comes from |
134 |
| - // eyeballing it until it looked exactly like the spec examples. |
135 | 135 | .mat-display-4, #{$selector} .mat-display-4 {
|
136 | 136 | @include mat-typography-level-to-styles($config, display-4);
|
137 | 137 | margin: 0 0 56px;
|
138 |
| - letter-spacing: -0.05em; |
139 | 138 | }
|
140 | 139 |
|
141 | 140 | .mat-display-3, #{$selector} .mat-display-3 {
|
142 | 141 | @include mat-typography-level-to-styles($config, display-3);
|
143 | 142 | margin: 0 0 64px;
|
144 |
| - letter-spacing: -0.02em; |
145 | 143 | }
|
146 | 144 |
|
147 | 145 | .mat-display-2, #{$selector} .mat-display-2 {
|
148 | 146 | @include mat-typography-level-to-styles($config, display-2);
|
149 | 147 | margin: 0 0 64px;
|
150 |
| - letter-spacing: -0.005em; |
151 | 148 | }
|
152 | 149 |
|
153 | 150 | .mat-display-1, #{$selector} .mat-display-1 {
|
|
0 commit comments