Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

reducer.web.js 848B

12345678910111213141516171819202122232425262728293031323334353637
  1. // @flow
  2. import { ReducerRegistry } from '../base/redux';
  3. import { RESET_SHARED_VIDEO_STATUS, SET_SHARED_VIDEO_STATUS, SET_DISABLE_BUTTON } from './actionTypes';
  4. const initialState = {};
  5. /**
  6. * Reduces the Redux actions of the feature features/shared-video.
  7. */
  8. ReducerRegistry.register('features/shared-video', (state = initialState, action) => {
  9. const { videoUrl, status, time, ownerId, disabled, muted } = action;
  10. switch (action.type) {
  11. case RESET_SHARED_VIDEO_STATUS:
  12. return initialState;
  13. case SET_SHARED_VIDEO_STATUS:
  14. return {
  15. ...state,
  16. muted,
  17. ownerId,
  18. status,
  19. time,
  20. videoUrl
  21. };
  22. case SET_DISABLE_BUTTON:
  23. return {
  24. ...state,
  25. disabled
  26. };
  27. default:
  28. return state;
  29. }
  30. });