diff --git a/lib/widgets/data_input_dialog.dart b/lib/widgets/data_input_dialog.dart index c406d9c..ac405b9 100644 --- a/lib/widgets/data_input_dialog.dart +++ b/lib/widgets/data_input_dialog.dart @@ -6,7 +6,7 @@ Future showStringInputDialog({String? originalValue}) async { final strVal = (originalValue ?? "").obs; return await Get.dialog( AlertDialog( - title: const Text("Enter a string"), + title: const Text("Введите строку"), content: TextField( controller: TextEditingController(text: originalValue), onChanged: (value) { @@ -18,13 +18,13 @@ Future showStringInputDialog({String? originalValue}) async { onPressed: () { Get.back(result: null); }, - child: const Text("Cancel"), + child: const Text("Отменить"), ), TextButton( onPressed: () { Get.back(result: strVal.value); }, - child: const Text("OK"), + child: const Text("Ок"), ), ], ), @@ -35,7 +35,7 @@ Future showDoubleInputDialog({double? originalValue}) async { final strVal = (originalValue?.toString() ?? "").obs; return await Get.dialog( AlertDialog( - title: const Text("Enter a number"), + title: const Text("Введите плавающее число"), content: FastTextField( name: "Number", initialValue: originalValue?.toString(), @@ -43,11 +43,11 @@ Future showDoubleInputDialog({double? originalValue}) async { autovalidateMode: AutovalidateMode.onUserInteraction, validator: (value) { if (value == null || value.isEmpty) { - return "Please enter a number"; + return "Пожалуйста, введите плавающее число"; } final parsed = double.tryParse(value); if (parsed == null) { - return "Please enter a valid number"; + return "Пожалуйста, введите настоящее плавающее число"; } return null; }, @@ -60,7 +60,7 @@ Future showDoubleInputDialog({double? originalValue}) async { onPressed: () { Get.back(result: null); }, - child: const Text("Cancel"), + child: const Text("Отменить"), ), TextButton( onPressed: () { @@ -71,7 +71,7 @@ Future showDoubleInputDialog({double? originalValue}) async { Get.back(result: null); } }, - child: const Text("OK"), + child: const Text("Ок"), ), ], ), @@ -82,7 +82,7 @@ Future showIntInputDialog({int? originalValue}) async { final strVal = (originalValue?.toString() ?? "").obs; return await Get.dialog( AlertDialog( - title: const Text("Enter a number"), + title: const Text("Введите целое число"), content: FastTextField( name: "Number", initialValue: originalValue?.toString(), @@ -90,11 +90,11 @@ Future showIntInputDialog({int? originalValue}) async { autovalidateMode: AutovalidateMode.onUserInteraction, validator: (value) { if (value == null || value.isEmpty) { - return "Please enter a number"; + return "Пожалуйста, введите целое число"; } final parsed = int.tryParse(value); if (parsed == null) { - return "Please enter a valid number"; + return "Пожалуйста, введите настоящее целое число"; } return null; }, @@ -107,7 +107,7 @@ Future showIntInputDialog({int? originalValue}) async { onPressed: () { Get.back(result: null); }, - child: const Text("Cancel"), + child: const Text("Отменить"), ), TextButton( onPressed: () { @@ -118,7 +118,7 @@ Future showIntInputDialog({int? originalValue}) async { Get.back(result: null); } }, - child: const Text("OK"), + child: const Text("Ок"), ), ], ),