summaryrefslogtreecommitdiff
path: root/frontend/app/views/page/page.reducer.js
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2021-03-20 19:24:13 +0100
committerJules Laplace <julescarbon@gmail.com>2021-03-20 19:24:13 +0100
commit50d5c3c2f10725af8ebb6db47c209f7000abc8f4 (patch)
tree3324d485ef7684189c50cfeb6e05ee0c7397601f /frontend/app/views/page/page.reducer.js
parentd9ee2c97882ea5ace9c28ac6560ffa240daf9345 (diff)
remove foreignkey constraint on target_page_id. toggle popups. show list of popups, if a tile link is open/close popup
Diffstat (limited to 'frontend/app/views/page/page.reducer.js')
-rw-r--r--frontend/app/views/page/page.reducer.js12
1 files changed, 11 insertions, 1 deletions
diff --git a/frontend/app/views/page/page.reducer.js b/frontend/app/views/page/page.reducer.js
index b0c4553..a1f281a 100644
--- a/frontend/app/views/page/page.reducer.js
+++ b/frontend/app/views/page/page.reducer.js
@@ -11,6 +11,7 @@ const initialState = crudState('page', {
tileList: false,
showingPopups: true,
sidebarOnRight: true,
+ popups: {},
},
options: {
}
@@ -202,7 +203,16 @@ export default function pageReducer(state = initialState, action) {
...state,
editor: {
...state.editor,
- togglePopups: !state.editor.togglePopups,
+ showingPopups: !state.editor.showingPopups,
+ }
+ }
+
+ case types.page.load_popups:
+ return {
+ ...state,
+ editor: {
+ ...state.editor,
+ popups: action.popups,
}
}