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.

middleware.ts 547B

123456789101112131415161718192021
  1. import MiddlewareRegistry from '../base/redux/MiddlewareRegistry';
  2. import { OPEN_KEYBOARD_SHORTCUTS_DIALOG } from './actionTypes';
  3. /**
  4. * Implements the middleware of the feature keyboard-shortcuts.
  5. *
  6. * @param {Store} store - The redux store.
  7. * @returns {Function}
  8. */
  9. MiddlewareRegistry.register(_store => next => action => {
  10. switch (action.type) {
  11. case OPEN_KEYBOARD_SHORTCUTS_DIALOG:
  12. if (typeof APP === 'object') {
  13. APP.keyboardshortcut.openDialog();
  14. }
  15. break;
  16. }
  17. return next(action);
  18. });