|
|
|
|
@ -593,17 +593,11 @@ export function pause_effect(effect, callback, destroy = true) {
|
|
|
|
|
|
|
|
|
|
pause_children(effect, transitions, true);
|
|
|
|
|
|
|
|
|
|
run_out_transitions(transitions, () => {
|
|
|
|
|
var fn = () => {
|
|
|
|
|
if (destroy) destroy_effect(effect);
|
|
|
|
|
if (callback) callback();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @param {TransitionManager[]} transitions
|
|
|
|
|
* @param {() => void} fn
|
|
|
|
|
*/
|
|
|
|
|
export function run_out_transitions(transitions, fn) {
|
|
|
|
|
var remaining = transitions.length;
|
|
|
|
|
if (remaining > 0) {
|
|
|
|
|
var check = () => --remaining || fn();
|
|
|
|
|
@ -620,7 +614,7 @@ export function run_out_transitions(transitions, fn) {
|
|
|
|
|
* @param {TransitionManager[]} transitions
|
|
|
|
|
* @param {boolean} local
|
|
|
|
|
*/
|
|
|
|
|
export function pause_children(effect, transitions, local) {
|
|
|
|
|
function pause_children(effect, transitions, local) {
|
|
|
|
|
if ((effect.f & INERT) !== 0) return;
|
|
|
|
|
effect.f ^= INERT;
|
|
|
|
|
|
|
|
|
|
|