aboutsummaryrefslogtreecommitdiffstats
path: root/src/features/workspaces/actions.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/features/workspaces/actions.ts')
-rw-r--r--src/features/workspaces/actions.ts30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/features/workspaces/actions.ts b/src/features/workspaces/actions.ts
new file mode 100644
index 000000000..5e7e6e721
--- /dev/null
+++ b/src/features/workspaces/actions.ts
@@ -0,0 +1,30 @@
1import PropTypes from 'prop-types';
2import Workspace from './models/Workspace';
3import { createActionsFromDefinitions } from '../../actions/lib/actions';
4
5export const workspaceActions = createActionsFromDefinitions(
6 {
7 edit: {
8 workspace: PropTypes.instanceOf(Workspace).isRequired,
9 },
10 create: {
11 name: PropTypes.string.isRequired,
12 },
13 delete: {
14 workspace: PropTypes.instanceOf(Workspace).isRequired,
15 },
16 update: {
17 workspace: PropTypes.instanceOf(Workspace).isRequired,
18 },
19 activate: {
20 workspace: PropTypes.instanceOf(Workspace).isRequired,
21 },
22 deactivate: {},
23 toggleWorkspaceDrawer: {},
24 openWorkspaceSettings: {},
25 toggleKeepAllWorkspacesLoadedSetting: {},
26 },
27 PropTypes.checkPropTypes,
28);
29
30export default workspaceActions;