Css 角材料&x2B;主题生成器=>;`rgba($color,$alpha)`的参数`color`必须是颜色
我用这个在线工具生成了一个角度材质主题:并将其包含在styles.css中。我还重新编译了节点sas 但我(仍然)得到了这个错误:Css 角材料&x2B;主题生成器=>;`rgba($color,$alpha)`的参数`color`必须是颜色,css,angular,sass,angular-material,Css,Angular,Sass,Angular Material,我用这个在线工具生成了一个角度材质主题:并将其包含在styles.css中。我还重新编译了节点sas 但我(仍然)得到了这个错误: Argument `$color` of `rgba($color, $alpha)` must be a color 在node_modules/@angular/material/_theming.scss(第1277行,第11列)中。以下是出现问题的函数: @function mat-color($palette, $hue: default, $opa
Argument `$color` of `rgba($color, $alpha)` must be a color
在node_modules/@angular/material/_theming.scss(第1277行,第11列)中。以下是出现问题的函数:
@function mat-color($palette, $hue: default, $opacity: null) {
// If hueKey is a number between zero and one, then it actually contains an
// opacity value, so recall this function with the default hue and that given opacity.
@if type-of($hue) == number and $hue >= 0 and $hue <= 1 {
@return mat-color($palette, default, $hue);
}
$color: map-get($palette, $hue);
$opacity: if($opacity == null, opacity($color), $opacity);
@return rgba($color, $opacity);
}
@function mat color($palete,$hue:default,$opacity:null){
//如果hueKey是一个介于0和1之间的数字,那么它实际上包含一个
//不透明度值,因此使用默认色调和给定的不透明度调用此函数。
@如果($hue)=数字和$hue>=0和$hue的类型对任何有相同问题的人来说都是:我更新到Angular 7.1,现在可以使用了。链接不起作用。你在哪里使用mat color
?