Style NFC Restricted page

This commit is contained in:
Dain Nilsson 2024-08-26 12:58:30 +02:00
parent f89a84011d
commit fbbd7e3850
No known key found for this signature in database
GPG Key ID: F04367096FBA95E8
8 changed files with 24 additions and 12 deletions

View File

@ -81,12 +81,13 @@ class DeviceErrorScreen extends ConsumerWidget {
'restricted-nfc' => HomeMessagePage(
centered: true,
graphic: Icon(
Symbols.warning,
Symbols.contactless,
size: 96,
color: Theme.of(context).colorScheme.error,
color: Theme.of(context).colorScheme.tertiary,
),
header: l10n.s_restricted_nfc,
message: l10n.p_restricted_nfc,
header: l10n.l_deactivate_restricted_nfc,
message: l10n.p_deactivate_restricted_nfc_desc,
footnote: l10n.p_deactivate_restricted_nfc_footer,
),
_ => HomeMessagePage(
centered: true,

View File

@ -155,6 +155,7 @@ List<String> _getDeviceStrings(
error: (error, _) => switch (error) {
'device-inaccessible' => [node.name, l10n.s_yk_inaccessible],
'unknown-device' => [l10n.s_unknown_device],
'restricted-nfc' => [l10n.s_restricted_nfc],
_ => null,
},
) ??

View File

@ -76,7 +76,7 @@ class MessagePage extends StatelessWidget {
right: 18.0,
bottom: centered && actionsBuilder == null ? 96 : 0),
child: SizedBox(
width: centered ? 250 : 350,
width: 350,
child: Column(
crossAxisAlignment: centered
? CrossAxisAlignment.center
@ -93,7 +93,7 @@ class MessagePage extends StatelessWidget {
if (message != null) ...[
const SizedBox(height: 12.0),
Container(
constraints: const BoxConstraints(maxWidth: 300),
constraints: const BoxConstraints(maxWidth: 350),
child: Text(message!,
textAlign: centered ? TextAlign.center : TextAlign.left,
style: Theme.of(context).textTheme.titleSmall?.apply(

View File

@ -168,7 +168,6 @@
"l_insert_or_tap_yk": "YubiKey anschließen oder dagegenhalten",
"l_unplug_yk": "Entfernen Sie Ihren YubiKey",
"l_reinsert_yk": "Schließen Sie Ihren YubiKey wieder an",
"p_restricted_nfc": null,
"l_place_on_nfc_reader": "Halten Sie Ihren YubiKey zum NFC-Leser",
"l_replace_yk_on_reader": "Halten Sie Ihren YubiKey wieder zum Leser",
"l_remove_yk_from_reader": "Entfernen Sie Ihren YubiKey vom NFC-Leser",
@ -231,6 +230,9 @@
"s_unknown_type": "Unbekannter Typ",
"s_unknown_device": "Unbekanntes Gerät",
"s_restricted_nfc": null,
"l_deactivate_restricted_nfc": null,
"p_deactivate_restricted_nfc_desc": null,
"p_deactivate_restricted_nfc_footer": null,
"s_unsupported_yk": "Nicht unterstützter YubiKey",
"s_yk_not_recognized": "Geräte nicht erkannt",
"p_operation_failed_try_again": null,

View File

@ -168,7 +168,6 @@
"l_insert_or_tap_yk": "Insert or tap a YubiKey",
"l_unplug_yk": "Unplug your YubiKey",
"l_reinsert_yk": "Reinsert your YubiKey",
"p_restricted_nfc": "To remove NFC restrictions, connect the YubiKey to a USB port.",
"l_place_on_nfc_reader": "Place your YubiKey on the NFC reader",
"l_replace_yk_on_reader": "Place your YubiKey back on the reader",
"l_remove_yk_from_reader": "Remove your YubiKey from the NFC reader",
@ -230,7 +229,10 @@
"l_no_yk_present": "No YubiKey present",
"s_unknown_type": "Unknown type",
"s_unknown_device": "Unrecognized device",
"s_restricted_nfc": "NFC functionality restricted",
"s_restricted_nfc": "NFC activation",
"l_deactivate_restricted_nfc": "How to activate NFC",
"p_deactivate_restricted_nfc_desc": "Connect your YubiKey to any USB power source, such as a computer, for at least 3 seconds.\n\nOnce powered, NFC will be activated and ready for use.",
"p_deactivate_restricted_nfc_footer": "Your YubiKey is equipped with Restricted NFC, a feature designed to safeguard against wireless manipulation during shipping. This means that NFC operations are temporarily disabled until you activate them.",
"s_unsupported_yk": "Unsupported YubiKey",
"s_yk_not_recognized": "Device not recognized",
"p_operation_failed_try_again": "The operation failed, please try again.",

View File

@ -168,7 +168,6 @@
"l_insert_or_tap_yk": "Insérez ou appuyez sur YubiKey",
"l_unplug_yk": "Retirez votre YubiKey",
"l_reinsert_yk": "Réinsérez votre YubiKey",
"p_restricted_nfc": null,
"l_place_on_nfc_reader": "Placez votre YubiKey sur le lecteur NFC",
"l_replace_yk_on_reader": "Replacez votre YubiKey sur le lecteur",
"l_remove_yk_from_reader": "Retirez votre YubiKey du lecteur NFC",
@ -231,6 +230,9 @@
"s_unknown_type": "Type inconnu",
"s_unknown_device": "Appareil non reconnu",
"s_restricted_nfc": null,
"l_deactivate_restricted_nfc": null,
"p_deactivate_restricted_nfc_desc": null,
"p_deactivate_restricted_nfc_footer": null,
"s_unsupported_yk": "YubiKey non prise en charge",
"s_yk_not_recognized": "Appareil non reconnu",
"p_operation_failed_try_again": "L'opération a échoué, veuillez réessayer.",

View File

@ -168,7 +168,6 @@
"l_insert_or_tap_yk": "YubiKeyを挿入またはタップしてください",
"l_unplug_yk": "YubiKeyを抜いてください",
"l_reinsert_yk": "YubiKeyを再挿入してください",
"p_restricted_nfc": null,
"l_place_on_nfc_reader": "YubiKeyをNFCリーダーに置いてください",
"l_replace_yk_on_reader": "YubiKeyをNFCリーダーに戻してください",
"l_remove_yk_from_reader": "YubiKeyをNFCリーダーから外してください",
@ -231,6 +230,9 @@
"s_unknown_type": "不明なタイプ",
"s_unknown_device": "認識されないデバイス",
"s_restricted_nfc": null,
"l_deactivate_restricted_nfc": null,
"p_deactivate_restricted_nfc_desc": null,
"p_deactivate_restricted_nfc_footer": null,
"s_unsupported_yk": "サポートされていないYubiKey",
"s_yk_not_recognized": "デバイスが認識されません",
"p_operation_failed_try_again": "操作に失敗しました。もう一度やり直してください。",

View File

@ -168,7 +168,6 @@
"l_insert_or_tap_yk": "Podłącz lub przystaw YubiKey",
"l_unplug_yk": "Odłącz klucz YubiKey",
"l_reinsert_yk": "Ponownie podłącz YubiKey",
"p_restricted_nfc": null,
"l_place_on_nfc_reader": "Przyłóż klucz YubiKey do czytnika NFC",
"l_replace_yk_on_reader": "Umieść klucz YubiKey z powrotem na czytniku",
"l_remove_yk_from_reader": "Odsuń klucz YubiKey od czytnika NFC",
@ -231,6 +230,9 @@
"s_unknown_type": "Nieznany typ",
"s_unknown_device": "Nierozpoznane urządzenie",
"s_restricted_nfc": null,
"l_deactivate_restricted_nfc": null,
"p_deactivate_restricted_nfc_desc": null,
"p_deactivate_restricted_nfc_footer": null,
"s_unsupported_yk": "Nieobsługiwany klucz YubiKey",
"s_yk_not_recognized": "Urządzenie nie rozpoznane",
"p_operation_failed_try_again": null,