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

时间:2017-05-16 11:30:07

标签: zurb-foundation

在通过NPM安装基础站点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

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

1 个答案:

答案 0 :(得分:0)

今天我也遇到过这个问题,经过多次摆弄后看起来就像你上次升级基金会一样,他们打破了它......

更改

@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

中的

为什么或何时改变它我不知道。