mirror of
https://github.com/cgzirim/seek-tune.git
synced 2025-12-18 09:24:19 +00:00
Submit form when enter key is clicked
This commit is contained in:
parent
d569471334
commit
1006112acb
1 changed files with 2 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ const Form = ({ socket }) => {
|
||||||
const { spotifyUrl } = formState;
|
const { spotifyUrl } = formState;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<form className={styles.Form}>
|
<form className={styles.Form} onSubmit={submitForm}>
|
||||||
<div style={{ flexGrow: 1 }}>
|
<div style={{ flexGrow: 1 }}>
|
||||||
<div>Add songs to the server</div>
|
<div>Add songs to the server</div>
|
||||||
<input
|
<input
|
||||||
|
|
@ -48,7 +48,7 @@ const Form = ({ socket }) => {
|
||||||
onChange={handleChange}
|
onChange={handleChange}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<input type="button" value="Submit" onClick={submitForm} />
|
<input type="submit" value="Submit" onClick={submitForm} />
|
||||||
</form>
|
</form>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue