Add autofillgroup
This commit is contained in:
parent
68cd03e71c
commit
3011890831
|
@ -67,7 +67,8 @@ class AddAccountPage extends HookWidget {
|
|||
leading: const CloseButton(),
|
||||
title: const Text('Add account'),
|
||||
),
|
||||
body: ListView(
|
||||
body: AutofillGroup(
|
||||
child: ListView(
|
||||
padding: const EdgeInsets.all(15),
|
||||
children: [
|
||||
if (icon.value == null)
|
||||
|
@ -116,10 +117,13 @@ class AddAccountPage extends HookWidget {
|
|||
TextField(
|
||||
autofocus: true,
|
||||
controller: usernameController,
|
||||
autofillHints: const [AutofillHints.email, AutofillHints.username],
|
||||
autofillHints: const [
|
||||
AutofillHints.email,
|
||||
AutofillHints.username
|
||||
],
|
||||
onSubmitted: (_) => passwordFocusNode.requestFocus(),
|
||||
decoration:
|
||||
InputDecoration(labelText: L10n.of(context)!.email_or_username),
|
||||
decoration: InputDecoration(
|
||||
labelText: L10n.of(context)!.email_or_username),
|
||||
),
|
||||
const SizedBox(height: 5),
|
||||
TextField(
|
||||
|
@ -129,7 +133,8 @@ class AddAccountPage extends HookWidget {
|
|||
onSubmitted: (_) => handleSubmit?.call(),
|
||||
autofillHints: const [AutofillHints.password],
|
||||
keyboardType: TextInputType.visiblePassword,
|
||||
decoration: InputDecoration(labelText: L10n.of(context)!.password),
|
||||
decoration:
|
||||
InputDecoration(labelText: L10n.of(context)!.password),
|
||||
),
|
||||
ElevatedButton(
|
||||
onPressed: handleSubmit,
|
||||
|
@ -153,6 +158,7 @@ class AddAccountPage extends HookWidget {
|
|||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue