import { combineReducers, Action } from '@ngrx/store';
import { BranchState } from './branch.state';
import { taskCalendarReducer } from './task-calendar';
import { taskFilesReducer } from './task-files';
import { taskArticlesReducer } from './task-articles';

const _branchReducer = combineReducers<BranchState>({
  taskCalendar: taskCalendarReducer,
  taskFiles: taskFilesReducer,
  taskArticles: taskArticlesReducer,
});

export function branchReducer(state: BranchState, action: Action) {
  return _branchReducer(state, action);
}
