好吧,我认为问题是我的主题是深色主题。我去了
project/index.html
<body class="mat-typography mat-app-background">
将背景更改为深色
这是自 Angular Material 0.11 版本以来出现的常见问题。工具栏内的组件被涂成白色。此问题出现在例如:md-toolbar、md-fab-actions、md-raised 和 mat-tab 中。