mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-11-26 10:33:15 +03:00
Merge PR #1503
This commit is contained in:
commit
46b4afe030
@ -146,33 +146,16 @@ class _DeviceContent extends ConsumerWidget {
|
|||||||
final label = initialCustomization?.name;
|
final label = initialCustomization?.name;
|
||||||
String displayName = label != null ? '$label ($name)' : name;
|
String displayName = label != null ? '$label ($name)' : name;
|
||||||
|
|
||||||
return Row(
|
return Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Row(
|
||||||
children: [
|
children: [
|
||||||
Flexible(
|
Flexible(
|
||||||
child: Column(
|
child: Text(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
displayName,
|
displayName,
|
||||||
style: Theme.of(context).textTheme.titleLarge,
|
style: Theme.of(context).textTheme.titleLarge,
|
||||||
),
|
),
|
||||||
const SizedBox(
|
|
||||||
height: 12,
|
|
||||||
),
|
|
||||||
if (serial != null)
|
|
||||||
Text(
|
|
||||||
l10n.l_serial_number(serial),
|
|
||||||
style: Theme.of(context).textTheme.titleSmall?.apply(
|
|
||||||
color: Theme.of(context).colorScheme.onSurfaceVariant),
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
l10n.l_firmware_version(version),
|
|
||||||
style: Theme.of(context).textTheme.titleSmall?.apply(
|
|
||||||
color: Theme.of(context).colorScheme.onSurfaceVariant),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
if (serial != null)
|
if (serial != null)
|
||||||
Padding(
|
Padding(
|
||||||
@ -182,7 +165,8 @@ class _DeviceContent extends ConsumerWidget {
|
|||||||
onPressed: () async {
|
onPressed: () async {
|
||||||
await ref.read(withContextProvider)((context) async {
|
await ref.read(withContextProvider)((context) async {
|
||||||
await _showManageLabelDialog(
|
await _showManageLabelDialog(
|
||||||
initialCustomization ?? KeyCustomization(serial: serial),
|
initialCustomization ??
|
||||||
|
KeyCustomization(serial: serial),
|
||||||
context,
|
context,
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
@ -190,6 +174,26 @@ class _DeviceContent extends ConsumerWidget {
|
|||||||
),
|
),
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
|
),
|
||||||
|
const SizedBox(
|
||||||
|
height: 12,
|
||||||
|
),
|
||||||
|
if (serial != null)
|
||||||
|
Text(
|
||||||
|
l10n.l_serial_number(serial),
|
||||||
|
style: Theme.of(context)
|
||||||
|
.textTheme
|
||||||
|
.titleSmall
|
||||||
|
?.apply(color: Theme.of(context).colorScheme.onSurfaceVariant),
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
l10n.l_firmware_version(version),
|
||||||
|
style: Theme.of(context)
|
||||||
|
.textTheme
|
||||||
|
.titleSmall
|
||||||
|
?.apply(color: Theme.of(context).colorScheme.onSurfaceVariant),
|
||||||
|
),
|
||||||
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user