p5.js-web-editor/client/modules/IDE/reducers/editorHidden.js

17 lines
360 B
JavaScript
Raw Normal View History

import * as ActionTypes from '../../../constants';
const initialState = {
enableBeep: false
};
const editorHidden = (state = initialState, action) => {
switch (action.type) {
case ActionTypes.TOGGLE_BEEP:
return Object.assign({}, state, { enableBeep: !state.enableBeep });
default:
return state;
}
};
export default editorHidden;