Merge branch '13540-add-possibility-to-open-files-in-third-party-apps'
[arvados-workbench2.git] / src / views-components / dialog-forms / create-ssh-key-dialog.ts
1 // Copyright (C) The Arvados Authors. All rights reserved.
2 //
3 // SPDX-License-Identifier: AGPL-3.0
4
5 import { compose } from "redux";
6 import { reduxForm } from 'redux-form';
7 import { withDialog } from "~/store/dialog/with-dialog";
8 import { SSH_KEY_CREATE_FORM_NAME, createSshKey, SshKeyCreateFormDialogData } from '~/store/auth/auth-action';
9 import { DialogSshKeyCreate } from '~/views-components/dialog-create/dialog-ssh-key-create';
10
11 export const CreateSshKeyDialog = compose(
12     withDialog(SSH_KEY_CREATE_FORM_NAME),
13     reduxForm<SshKeyCreateFormDialogData>({
14         form: SSH_KEY_CREATE_FORM_NAME,
15         onSubmit: (data, dispatch) => {
16             dispatch(createSshKey(data));
17         }
18     })
19 )(DialogSshKeyCreate);