securityos/node_modules/framer-motion/dist/es/utils/offsets/fill.mjs

13 lines
346 B
JavaScript
Raw Permalink Normal View History

2024-09-06 15:32:35 +00:00
import { mix } from '../mix.mjs';
import { progress } from '../progress.mjs';
function fillOffset(offset, remaining) {
const min = offset[offset.length - 1];
for (let i = 1; i <= remaining; i++) {
const offsetProgress = progress(0, remaining, i);
offset.push(mix(min, 1, offsetProgress));
}
}
export { fillOffset };