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.

actions.js 601B

1234567891011121314151617181920212223242526272829303132
  1. import {
  2. HIDE_DIALOG,
  3. OPEN_DIALOG
  4. } from './actionTypes';
  5. /**
  6. * Signals Dialog to close its dialog.
  7. *
  8. * @returns {{
  9. * type: HIDE_DIALOG
  10. * }}
  11. */
  12. export function hideDialog() {
  13. return {
  14. type: HIDE_DIALOG
  15. };
  16. }
  17. /**
  18. * Signals Dialog to open dialog.
  19. *
  20. * @param {Object} component - The component to display as dialog.
  21. * @param {Object} componentProps - The properties needed for that component.
  22. * @returns {Object}
  23. */
  24. export function openDialog(component, componentProps) {
  25. return {
  26. type: OPEN_DIALOG,
  27. component,
  28. componentProps
  29. };
  30. }