1 import React from 'react'
2 import { FormContainer, FormSection, KeyConfiguration } from 'features/shared/components'
3 import { reduxForm } from 'redux-form'
4 import { withNamespaces } from 'react-i18next'
6 class NewKeyAndSign extends React.Component {
13 fields: { xpubs, quorum },
22 const promise = new Promise(function(resolve, reject) {
24 for (let i = 0; i < xpubs.length; i++) {
33 promise.then(previousPage)
39 label= { t('asset.new') }
40 onSubmit={handleSubmit}
41 submitting={submitting}
44 <FormSection title={t('form.keyAndSign')}>
48 quorumHint={t('asset.quorumHint')} />
50 <button type='button' onClick={prev}>
59 const validate = (values, props) => {
60 const errors = { xpubs:{} }
63 values.xpubs.forEach((xpub, index) => {
64 if (!values.xpubs[index].value) {
65 errors.xpubs[index] = {...errors.xpubs[index], value: t('asset.keysError')}
78 'description[].value',
83 export default withNamespaces('translations') (
88 destroyOnUnmount: false,