import { createAction } from "redux-actions" ; import types from "../types/typs" ; import { IUser , IToastMsg } from 'src/components/Type/Type' ; import { ShowPopoveType } from 'src/components/Type/ReduxType' ; const setToken = createAction ( types . TOKEN , ( token ) => token ) ; const setUser = createAction ( types . USER_MSG , ( { ... params } ) => ( { ... params } ) ) ; const setPopoveState = createAction ( types . POPOVE_STATE , ( popove ) => ( { ... popove } ) ) ; const setLoginType = createAction ( types . LOGIN_TYPE , ( payload ) => payload ) ; const setToastStatus = createAction ( types . TOAST_STAUS , ( payload ) => ( { ... payload } ) ) ; const setTargetPage = createAction ( types . TARGET_PAGE , ( page ) => page ) ; const actionsStore = { setLoginType , setPopoveState , setToastStatus , setToken , setUser , setTargetPage , } ; export default actionsStore ;