mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
19 lines
428 B
TypeScript
19 lines
428 B
TypeScript
import React from 'react';
|
|
import { Form } from 'react-final-form'
|
|
|
|
import { InputAction } from 'components';
|
|
|
|
const SayMessage = ({ onSubmit }) => (
|
|
<Form onSubmit={onSubmit}>
|
|
{({ handleSubmit, form }) => (
|
|
<form onSubmit={e => {
|
|
handleSubmit(e)
|
|
form.restart()
|
|
}}>
|
|
<InputAction action="Send" label="Chat" name="message" />
|
|
</form>
|
|
)}
|
|
</Form>
|
|
);
|
|
|
|
export default SayMessage;
|