NuclearDispersionSystem/ant-design-vue-jeecg/node_modules/d3-interpolate/src/array.js
2023-09-14 14:47:11 +08:00

18 lines
372 B
Java

import value from "./value";
export default function(a, b) {
var nb = b ? b.length : 0,
na = a ? Math.min(nb, a.length) : 0,
x = new Array(na),
c = new Array(nb),
i;
for (i = 0; i < na; ++i) x[i] = value(a[i], b[i]);
for (; i < nb; ++i) c[i] = b[i];
return function(t) {
for (i = 0; i < na; ++i) c[i] = x[i](t);
return c;
};
}