fix: transition perfect end

This commit is contained in:
cha0s 2024-07-04 09:08:20 -05:00
parent 7bdd598915
commit 48ef8a6cbd

View File

@ -161,6 +161,7 @@ export default function transition(object, properties) {
const transition = transitions[key];
transition.elapsed += elapsed;
if (transition.elapsed >= transition.duration) {
object[key] = transition.start + transition.magnitude;
resolve();
return;
}
@ -173,5 +174,5 @@ export default function transition(object, properties) {
}
},
);
return {stop, transition, promise};
return {stop, transitions, promise};
}