onMaximizePanel: () => dispatch(maximizePanel(panelId)),
Example #2
0
 visitHome: () => {
   dispatch({ type: ROUTE_ACTION_TYPES.HOME });
 },
Example #3
0
 return async (dispatch: Dispatch<FetchGetRealmType>) => {
     dispatch(RequestGetRealms());
     dispatch(ReceiveGetRealms(await getStatus(region.name)));
 };
Example #4
0
 setTimeout(() => {
     dispatch(Actions.deleteTodo(id))
     setTimeout(() => dispatch(Actions.setTodoDeleted(id)), 250)
 }, 150)
Example #5
0
 onToggle: (id: number) => {
     dispatch(Actions.toggleTodo(id))
 },
Example #6
0
 onDurationChange: (id: number, duration: number) => {
     dispatch(Actions.setTodoDuration(id, duration))
 },
Example #7
0
 onDetailChange: (id: number, detail: string) => {
     dispatch(Actions.setTodoDetail(id, detail))
 },
 promise: Promise.resolve((action: string, dispatch: Dispatch<any>, getState: Function) => {
   dispatch({ type: "SECEOND_ACTION_TYPE", payload: "..." });
   dispatch(someActionCreator());
 })
 ).then(() =>
         Promise.all([
             dispatch(makeASandwichWithSecretSauce('Me')),
             dispatch(makeASandwichWithSecretSauce('My wife'))
         ])
Example #10
0
 return (dispatch: Dispatch<Action>) => {
   dispatch({
     type: "LOGOUT",
   });
 };
Example #11
0
 return (dispatch: Dispatch<Action>) => {
   dispatch({
     isActive,
     type: "TOGGLE_MENU",
   });
 };
 onUpdatePanelTitle: (newTitle: string) => dispatch(setPanelTitle({ title: newTitle, panelId })),
 onResetPanelTitle: () => dispatch(resetPanelTitle(panelId)),
 onMinimizePanel: () => dispatch(minimizePanel()),
Example #15
0
 setTimeout(() => dispatch(closeGlobalMessage(id)), 5000);
 ).then(() =>
         dispatch(makeASandwichWithSecretSauce('Our kids'))
Example #17
0
 onStartHourChange: (id: number, startHour: Date) => {
     dispatch(Actions.setTodoStartHour(id, startHour))
 },
 ).then(() =>
         dispatch(getState().myMoney > 42 ?
                 withdrawMoney(42) :
                 apologize('Me', 'The Sandwich Shop')
         )
Example #19
0
 onTaskChange: (id: number, task: string) => {
     dispatch(Actions.setTodoTask(id, task))
 },
 (sauce: any) => dispatch(makeASandwich(forPerson, sauce)),
Example #21
0
 onMove: (fromPos: number, toPos: number) => {
     dispatch(Actions.moveTodo(fromPos, toPos))
 },
 (error: any) => dispatch(apologize('The Sandwich Shop', forPerson, error))
Example #23
0
 setTimeout(() => dispatch(Actions.setTodoDeleted(id)), 250)
Example #24
0
 .then((responseJson: Tweet[]) => {
     dispatch(setRefreshingTweets(false));
     dispatch(setTweets(responseJson));
 })
Example #25
0
export const stopFetchingOlder = () => async (
  dispatch: Dispatch<SetCurrentOlderBatchIDAction>
) => {
  return dispatch(setCurrentOlderBatchID(undefined))
}
Example #26
0
 .catch((ex) => {
     console.log(JSON.stringify(ex));
     dispatch(setRefreshingTweets(false));
 })
Example #27
0
 return async (dispatch: Dispatch<FetchGetBootType>) => {
     dispatch(RequestGetBoot());
     dispatch(ReceiveGetBoot(await getBoot()));
 };
Example #28
0
 return (dispatch: Dispatch) => {
   const id = uniqueId('global-message-');
   dispatch(addGlobalMessageActionCreator(id, message, level));
   setTimeout(() => dispatch(closeGlobalMessage(id)), 5000);
 };
Example #29
0
 return async (dispatch: Dispatch<FetchGetPingType>) => {
     dispatch(RequestGetPing());
     dispatch(ReceiveGetPing(await getPing()));
 };
 openContextMenu: () => dispatch(setVisibleContextMenuPanelId(panelId)),