0

In customizing my angular material theme's typography. I understand that one can override the default font with their own font like so:

$custom-typography: mat-typography-config(
  $font-family: 'Lato, monospace'
);

Although, I noticed that the source code shows two fonts , the default Roboto, and then Helvetica is also included in inverted commas:

$font-family: 'Roboto, "Helvetica Neue", sans-serif',

Is that a secondary font? I would like if I could choose a secondary font. If this is not a secondary font, what is it?

thanks

4

1 回答 1

0

font-family属性可以保存多个字体名称作为“后备”系统。如果浏览器不支持第一种字体,它会尝试下一种字体。

从您想要的字体开始,并始终以通用系列结尾,以让浏览器在通用系列中选择类似的字体,如果没有其他字体可用。

注意:用逗号分隔每个值。

注意:如果字体名称包含空格,则必须用引号引起来。在 HTML 中使用“样式”属性时必须使用单引号。

复制自w3schools

于 2018-09-06T08:40:59.003 回答