Animate closing of processes

This commit is contained in:
James Barnsley
2018-02-28 09:15:34 +13:00
parent 2a95af89de
commit 90f719c8f4
9 changed files with 50 additions and 21 deletions

View File

@ -158,12 +158,26 @@ const UIMiddleware = (function(){
next(action)
break
case 'PROCESS_FINISHING':
// start a timeout to remove this notification
// This gives us time to animate out the notification before we remove the data
var timeout = setTimeout(
function(){
store.dispatch(uiActions.processFinished(action.key))
},
200
)
next(action);
break;
case 'PROCESS_FINISHED':
store.dispatch({
type: action.key+'_FINISHED'
})
next(action)
break
});
next(action);
break;
// This action is irrelevant to us, pass it on to the next middleware
default: