mirror of
https://github.com/wassname/talk.git
synced 2026-08-07 11:29:44 +08:00
23 lines
457 B
JavaScript
23 lines
457 B
JavaScript
import * as actions from './constants';
|
|
|
|
const initialState = {
|
|
showAddEmailDialog: true,
|
|
};
|
|
|
|
export default function reducer(state = initialState, action) {
|
|
switch (action.type) {
|
|
case actions.SHOW_ADD_EMAIL_DIALOG:
|
|
return {
|
|
...state,
|
|
showAddEmailDialog: true,
|
|
};
|
|
case actions.HIDE_ADD_EMAIL_DIALOG:
|
|
return {
|
|
...state,
|
|
showAddEmailDialog: false,
|
|
};
|
|
default:
|
|
return state;
|
|
}
|
|
}
|