import React from 'react'; import { Button, FormGroup, InputGroup, Intent } from '@blueprintjs/core'; import { Form, FastField, ErrorMessage, useFormikContext } from 'formik'; import { FormattedMessage as T } from 'components'; import { compose } from 'redux'; import { CLASSES } from 'common/classes'; import { inputIntent } from 'utils'; import { useAutofocus } from 'hooks'; import withDialogActions from 'containers/Dialog/withDialogActions'; /** * Payment via license form. */ function PaymentViaLicenseForm({ // #withDialogActions closeDialog, }) { // Formik context. const { isSubmitting } = useFormikContext(); const licenseNumberRef = useAutofocus(); // Handle close button click. const handleCloseBtnClick = () => { closeDialog('payment-via-voucher'); }; return (

{({ field, meta: { error, touched } }) => ( } intent={inputIntent({ error, touched })} helperText={} className={'form-group--voucher_number'} > (licenseNumberRef.current = ref)} /> )}
); } export default compose(withDialogActions)(PaymentViaLicenseForm);