You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

reducer.js 428B

1234567891011121314151617181920212223
  1. // @flow
  2. import { ReducerRegistry } from '../redux';
  3. import { SET_AUDIO_ONLY } from './actionTypes';
  4. const DEFAULT_STATE = {
  5. enabled: false
  6. };
  7. ReducerRegistry.register('features/base/audio-only', (state = DEFAULT_STATE, action) => {
  8. switch (action.type) {
  9. case SET_AUDIO_ONLY:
  10. return {
  11. ...state,
  12. enabled: action.audioOnly
  13. };
  14. default:
  15. return state;
  16. }
  17. });