1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 01:36:22 +00:00

foldable SideNav

This commit is contained in:
Rokt33r
2016-05-12 19:53:21 +09:00
parent a3d5f23861
commit 365d7a1afd
8 changed files with 361 additions and 58 deletions

View File

@@ -110,8 +110,22 @@ function repositories (state = initialRepositories, action) {
return state
}
const defaultStatus = {
sideNavExpand: false
}
function status (state = defaultStatus, action) {
switch (action.type) {
case 'TOGGLE_SIDENAV':
state.sideNavExpand = !state.sideNavExpand
return Object.assign({}, state)
}
return state
}
let reducer = combineReducers({
repositories,
status,
routing: routerReducer
})