1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-28 14:16:41 +07:00

hero slider

This commit is contained in:
Fedor Katurov 2019-10-24 15:44:40 +07:00
parent a9da7e8cef
commit 5cd5941be0
12 changed files with 266 additions and 14 deletions

View file

@ -1,11 +1,15 @@
import assocPath from 'ramda/es/assocPath';
import { FLOW_ACTIONS } from './constants';
import { flowSetNodes } from './actions';
import { flowSetNodes, flowSetHeroes } from './actions';
import { IFlowState } from './reducer';
const setNodes = (state: IFlowState, { nodes }: ReturnType<typeof flowSetNodes>) =>
assocPath(['nodes'], nodes, state);
const setHeroes = (state: IFlowState, { heroes }: ReturnType<typeof flowSetHeroes>) =>
assocPath(['heroes'], heroes, state);
export const FLOW_HANDLERS = {
[FLOW_ACTIONS.SET_NODES]: setNodes,
[FLOW_ACTIONS.SET_HEROES]: setHeroes,
};