foundation-sites 6.3.1:函数 rem-calc 没有名为 $base 的参数

foundation-sites 6.3.1: Function rem-calc has no parameter named $base

我在通过 NPM 安装 foundation-sites 6.3.1 后遇到问题。

messageFormatted: node_modules/foundation-sites/scss/util/_unit.scss
Error: Function rem-calc has no parameter named $base
    on line 61 of node_modules/foundation-sites/scss/util/_unit.scss
    $value: rem-calc($value, $base: 16px);
-----------------------------^

messageOriginal: Function rem-calc has no parameter named $base
relativePath: node_modules/foundation-sites/scss/util/_unit.scss

我删除了所有内容以重新安装。我不明白...你有什么想法吗?

我今天也遇到了这个问题,经过多次摆弄之后看起来就像你上次升级 Foundation 时他们把它弄坏了......

改变

@function rem-calc($values, $base-value: $rem-base) {
  $max: length($values);

  @if $max == 1 { @return convert-to-rem(nth($values, 1), $base-value); }

  $remValues: ();
  @for $i from 1 through $max {
    $remValues: append($remValues, convert-to-rem(nth($values, $i), $base-value));
  }
  @return $remValues;
}

也是

@function rem-calc($values, $base: $rem-base) {
  $max: length($values);

  @if $max == 1 { @return convert-to-rem(nth($values, 1), $base); }

  $remValues: ();
  @for $i from 1 through $max {
    $remValues: append($remValues, convert-to-rem(nth($values, $i), $base));
  }
  @return $remValues;
}

foundation/scss/foundation/_function.scss

我不知道他们为什么或什么时候改变了它。