Merge pull request #593 from boarwell/keyboard-focusable

Re: Make the "Create" button focusable with keyboard
This commit is contained in:
Son Nguyen Kim 2021-08-21 16:25:20 +02:00 committed by GitHub
commit d6e48ea2e4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -69,7 +69,7 @@
<div class="row mb-2">
<div class="col p-1">
<select data-width="100%"
class="mailbox-select" id="mailboxes" multiple name="mailboxes">
class="mailbox-select" id="mailboxes" multiple name="mailboxes" required>
{% for mailbox in mailboxes %}
<option value="{{ mailbox.id }}" {% if mailbox.id == current_user.default_mailbox_id %}
selected {% endif %}>
@ -94,7 +94,7 @@
<div class="row">
<div class="col p-1">
<span id="submit" class="btn btn-primary mt-1">Create</span>
<button type="submit" id="create" class="btn btn-primary mt-1">Create</button>
</div>
</div>
</form>
@ -117,7 +117,7 @@
}
})
$("#submit").on("click", async function () {
$("#create").on("click", async function () {
let that = $(this);
let mailbox_ids = $(`#mailboxes`).val();
let prefix = $('#prefix').val();