Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Delete dialog UI

vishnukvmd91648deb49a5
diff --git a/mobile/apps/locker/lib/l10n/app_en.arb b/mobile/apps/locker/lib/l10n/app_en.arb
index c43e6156fa..21a11a1773 100644
--- a/mobile/apps/locker/lib/l10n/app_en.arb
+++ b/mobile/apps/locker/lib/l10n/app_en.arb
@@ -780,6 +780,10 @@
}
}
},
+ "deleteCollectionFromEverywhere": "Also delete items from everywhere",
+ "@deleteCollectionFromEverywhere": {
+ "description": "Checkbox label asking whether to delete collection items everywhere"
+ },
"yesDeleteCollections": "Yes, delete {count, plural, =1{collection} other{collections}}",
"@yesDeleteCollections": {
"description": "Button label for confirming deletion of one or more collections",
diff --git a/mobile/apps/locker/lib/l10n/app_localizations.dart b/mobile/apps/locker/lib/l10n/app_localizations.dart
index bd17463d5e..2bf04d322e 100644
--- a/mobile/apps/locker/lib/l10n/app_localizations.dart
+++ b/mobile/apps/locker/lib/l10n/app_localizations.dart
@@ -2440,6 +2440,12 @@ abstract class AppLocalizations {
/// **'{count, plural, =1{1 item} other{{count} items}} will be deleted permanently.'**
String deleteMultipleFilesDialogBody(int count);
+ /// Checkbox label asking whether to delete collection items everywhere
+ ///
+ /// In en, this message translates to:
+ /// **'Also delete items from everywhere'**
+ String get deleteCollectionFromEverywhere;
+
/// Button label for confirming deletion of one or more collections
///
/// In en, this message translates to:
diff --git a/mobile/apps/locker/lib/l10n/app_localizations_en.dart b/mobile/apps/locker/lib/l10n/app_localizations_en.dart
index d57e3b9aa8..d232f45145 100644
--- a/mobile/apps/locker/lib/l10n/app_localizations_en.dart
+++ b/mobile/apps/locker/lib/l10n/app_localizations_en.dart
@@ -1401,6 +1401,10 @@ class AppLocalizationsEn extends AppLocalizations {
return '$_temp0 will be deleted permanently.';
}
+ @override
+ String get deleteCollectionFromEverywhere =>
+ 'Also delete items from everywhere';
+
@override
String yesDeleteCollections(int count) {
String _temp0 = intl.Intl.pluralLogic(
diff --git a/mobile/apps/locker/lib/ui/components/delete_confirmation_dialog.dart b/mobile/apps/locker/lib/ui/components/delete_confirmation_dialog.dart
index d7e6ff8038..97730c1cae 100644
--- a/mobile/apps/locker/lib/ui/components/delete_confirmation_dialog.dart
+++ b/mobile/apps/locker/lib/ui/components/delete_confirmation_dialog.dart
@@ -2,6 +2,7 @@ import "package:ente_ui/components/buttons/button_widget.dart";
import "package:ente_ui/components/buttons/models/button_result.dart";
import "package:ente_ui/theme/ente_theme.dart";
import "package:flutter/material.dart";
+import 'package:locker/l10n/l10n.dart';
class DeleteConfirmationResult {
final ButtonResult buttonResult;
@@ -122,7 +123,7 @@ class _DeleteConfirmationBottomSheetState
),
textAlign: TextAlign.center,
),
- const SizedBox(height: 12),
+ const SizedBox(height: 20),
if (widget.showDeleteFromAllCollectionsOption) ...[
GestureDetector(
onTap: () {
@@ -132,7 +133,11 @@ class _DeleteConfirmationBottomSheetState
},
child: SizedBox(
width: double.infinity,
- child: Row(
+ child: Wrap(
+ alignment: WrapAlignment.center,
+ crossAxisAlignment: WrapCrossAlignment.center,
+ spacing: 12,
+ runSpacing: 8,
children: [
Container(
width: 18,
@@ -158,12 +163,10 @@ class _DeleteConfirmationBottomSheetState
)
: null,
),
- const SizedBox(width: 12),
- Expanded(
- child: Text(
- "Also delete items present in this collection from all other collections they are part of",
- style: textTheme.small,
- ),
+ Text(
+ context.l10n.deleteCollectionFromEverywhere,
+ style: textTheme.small,
+ textAlign: TextAlign.center,
),
],
),