mirror of
https://github.com/decompme/decomp.me.git
synced 2026-02-21 13:59:25 -06:00
fix new scratch form aborting submit by reloading
The default behavior of <form> when there is a <button> inside (through AsyncButon) is for the form to be submitted, and as we provided no override it effectively just refreshed the page. This aborts the actual new scratch creation request!
This commit is contained in:
@@ -166,7 +166,7 @@ export default function NewScratchForm({ serverCompilers }: {
|
||||
|
||||
const compilersTranslation = useTranslation("compilers")
|
||||
|
||||
return <form>
|
||||
return <div>
|
||||
<div>
|
||||
<p className={styles.label}>
|
||||
Platform
|
||||
@@ -272,5 +272,5 @@ export default function NewScratchForm({ serverCompilers }: {
|
||||
For more information, see our <Link href="/privacy">privacy policy</Link>.
|
||||
</p>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user