UX: Set autofocus for input fields and confirm on enter #1078

This commit is contained in:
Michael Mayer 2021-02-20 13:06:02 +01:00
parent c63fdb3cdb
commit 2b760e3995
6 changed files with 9 additions and 7 deletions

View file

@ -13,8 +13,7 @@
<v-flex xs12 class="pa-2">
<v-text-field
v-model="model.AccURL"
hide-details
browser-autocomplete="off"
hide-details autofocus
:label="$gettext('Service URL')"
placeholder="https://www.example.com/"
color="secondary-dark"

View file

@ -73,7 +73,7 @@
<v-autocomplete
v-model="model.SharePath"
color="secondary-dark" hide-details hide-no-data
flat
flat autofocus
browser-autocomplete="off"
hint="Folder"
:search-input.sync="search"
@ -185,7 +185,7 @@
<v-flex xs12 class="pa-2">
<v-text-field
v-model="model.AccName"
hide-details
hide-details autofocus
browser-autocomplete="off"
:label="$gettext('Name')"
placeholder=""

View file

@ -20,11 +20,12 @@
<v-layout row wrap>
<v-flex v-if="album.Type !== 'month'" xs12 pa-2>
<v-text-field v-model="model.Title"
hide-details
hide-details autofocus
:rules="[titleRule]"
:label="$gettext('Name')"
color="secondary-dark"
class="input-title"
@keyup.enter.native="confirm"
></v-text-field>
</v-flex>
<v-flex xs12 pa-2>

View file

@ -16,12 +16,14 @@
:loading="loading"
hide-details
hide-no-data
autofocus
item-text="Title"
item-value="UID"
:label="$gettext('Album Name')"
color="secondary-dark"
flat solo
class="input-album"
@keyup.enter.native="confirm"
>
</v-autocomplete>
</v-flex>

View file

@ -7,7 +7,7 @@
<v-flex xs12 class="pa-2">
<v-text-field
v-model="oldPassword"
hide-details required
hide-details required autofocus
type="password"
:disabled="busy"
browser-autocomplete="off"

View file

@ -10,7 +10,7 @@
item-key="ID"
:no-data-text="$gettext('No servers configured.')"
>
<template v-slot:items="props" class="p-account">
<template #items="props" class="p-account">
<td>
<button class="secondary-dark--text" @click.stop.prevent="edit(props.item)">
{{ props.item.AccName }}