mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-12-23 18:22:39 +03:00
Small fixup
This commit is contained in:
parent
7d26c4d409
commit
5d0afa3bfb
@ -124,7 +124,7 @@ class _ListScreenState extends ConsumerState<ListScreen> {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
icon: const Icon(Icons.edit_outlined),
|
icon: const Icon(Icons.edit_outlined),
|
||||||
color: Colors.white,
|
color: darkMode ? Colors.white : Colors.black,
|
||||||
),
|
),
|
||||||
]),
|
]),
|
||||||
title: Text(getTitle(cred),
|
title: Text(getTitle(cred),
|
||||||
@ -132,30 +132,25 @@ class _ListScreenState extends ConsumerState<ListScreen> {
|
|||||||
|
|
||||||
value: isUnique(cred) ? (checkedCreds[cred] ?? true) : false,
|
value: isUnique(cred) ? (checkedCreds[cred] ?? true) : false,
|
||||||
enabled: isUnique(cred),
|
enabled: isUnique(cred),
|
||||||
subtitle: cred.issuer != null
|
subtitle: cred.issuer != null || !isUnique(cred)
|
||||||
? Column(
|
? Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.stretch,
|
crossAxisAlignment: CrossAxisAlignment.stretch,
|
||||||
children: [
|
children: [
|
||||||
|
if (cred.issuer != null)
|
||||||
Text(cred.name,
|
Text(cred.name,
|
||||||
overflow: TextOverflow.fade,
|
overflow: TextOverflow.fade,
|
||||||
maxLines: 1,
|
maxLines: 1,
|
||||||
softWrap: false),
|
softWrap: false),
|
||||||
isUnique(cred)
|
if (!isUnique(cred))
|
||||||
? Text('')
|
Text(
|
||||||
: Text(
|
|
||||||
l10n.l_name_already_exists,
|
l10n.l_name_already_exists,
|
||||||
style: TextStyle(
|
style: const TextStyle(
|
||||||
color: primaryRed,
|
color: primaryRed,
|
||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
])
|
])
|
||||||
: isUnique(cred)
|
: null,
|
||||||
? null
|
|
||||||
: Text(
|
|
||||||
l10n.l_name_already_exists,
|
|
||||||
style: TextStyle(color: primaryRed, fontSize: 12),
|
|
||||||
),
|
|
||||||
onChanged: (bool? value) {
|
onChanged: (bool? value) {
|
||||||
setState(() {
|
setState(() {
|
||||||
checkedCreds[cred] = value!;
|
checkedCreds[cred] = value!;
|
||||||
|
Loading…
Reference in New Issue
Block a user