mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Add auto-submit logic
This commit is contained in:
1 parent
faad1454a0
commit
fa1050d02d
1 file changed
+6
@@ -20,6 +20,12 @@
|
||||
defaultValue: value.split(''),
|
||||
onValueChange: ({ next }) => {
|
||||
value = next.join('');
|
||||
|
||||
if (value.length === 6) {
|
||||
const firstInputElement = element.querySelector('input');
|
||||
firstInputElement?.form.requestSubmit();
|
||||
}
|
||||
|
||||
return next;
|
||||
}
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user