Css 为什么这个函数不返回值,而是给vivg一个错误?

Css 为什么这个函数不返回值,而是给vivg一个错误?,css,sass,Css,Sass,此样式应用于.btn类,因此使用了。嗨,Razi,我不熟悉sass,但可能是因为您编写了function而不是function?哦!结果是很尴尬。谢谢你。 @funcion pastel ($clr){ $hue: hue($clr); $sat: 100%; $light: 90%; $pastel: HSL($hue, $sat, $light); @return $pastel; } //Trying to return here but it says "This

此样式应用于.btn类,因此使用了。

嗨,Razi,我不熟悉sass,但可能是因为您编写了function而不是function?哦!结果是很尴尬。谢谢你。
@funcion pastel ($clr){
  $hue: hue($clr);
  $sat: 100%;
  $light: 90%;
  $pastel: HSL($hue, $sat, $light);
  @return $pastel;
}

//Trying to return here but it says "This at-rule is not allowed here."
&:hover {
  background-color: pastel($color-primary);
  color: $color-primary;
  }