mirror of
https://gitlab.com/PronounsPage/PronounsPage.git
synced 2025-09-22 12:03:25 -04:00
[login] autofocus on code
This commit is contained in:
parent
723b337624
commit
70bb9a628e
@ -46,6 +46,7 @@
|
|||||||
<input type="text" class="form-control text-center" v-model="code"
|
<input type="text" class="form-control text-center" v-model="code"
|
||||||
placeholder="000000" autofocus required minlength="0" maxlength="6"
|
placeholder="000000" autofocus required minlength="0" maxlength="6"
|
||||||
inputmode="numeric" pattern="[0-9]{6}" autocomplete="one-time-code"
|
inputmode="numeric" pattern="[0-9]{6}" autocomplete="one-time-code"
|
||||||
|
ref="code"
|
||||||
/>
|
/>
|
||||||
<div class="input-group-append">
|
<div class="input-group-append">
|
||||||
<button class="btn btn-primary">
|
<button class="btn btn-primary">
|
||||||
@ -120,6 +121,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.token = response.token;
|
this.token = response.token;
|
||||||
|
|
||||||
|
this.$nextTick(_ => {
|
||||||
|
if (this.$refs.code) {
|
||||||
|
this.$refs.code.focus();
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user