summaryrefslogtreecommitdiff
path: root/frontend/views/index/graph.reducer.js
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/views/index/graph.reducer.js')
-rw-r--r--frontend/views/index/graph.reducer.js21
1 files changed, 20 insertions, 1 deletions
diff --git a/frontend/views/index/graph.reducer.js b/frontend/views/index/graph.reducer.js
index 7e573e1..e0ded41 100644
--- a/frontend/views/index/graph.reducer.js
+++ b/frontend/views/index/graph.reducer.js
@@ -5,7 +5,8 @@ import { crudState, crudReducer } from '../../api/crud.reducer'
const initialState = crudState('graph', {
editor: {
- addingPage: true,
+ addingPage: false,
+ editingPage: false,
},
options: {
}
@@ -35,6 +36,24 @@ export default function graphReducer(state = initialState, action) {
}
}
+ case types.graph.show_edit_page_form:
+ return {
+ ...state,
+ editor: {
+ ...state.editor,
+ addingPage: true,
+ }
+ }
+
+ case types.graph.hide_edit_page_form:
+ return {
+ ...state,
+ editor: {
+ ...state.editor,
+ addingPage: false,
+ }
+ }
+
default:
return state
}