Skip to content

armgit / ente

Public Imported from GitHub
0

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

Add EmptyStateFeatureRow widget and update references for improved empty state handling

AmanRajSinghMouryac6a0469a3f6c
diff --git a/mobile/apps/photos/lib/l10n/intl_en.arb b/mobile/apps/photos/lib/l10n/intl_en.arb
index 561d6d1ecf..1508e38593 100644
--- a/mobile/apps/photos/lib/l10n/intl_en.arb
+++ b/mobile/apps/photos/lib/l10n/intl_en.arb
@@ -2947,6 +2947,16 @@
}
},
"noActivityYet": "No activity yet",
+ "nothingHereYet": "Nothing here yet",
+ "shareAnAlbumWithSomeoneYouLove": "Share an album with someone you love",
+ "seeTheLoveYourPhotosGet": "See the love your photos get",
+ "yourConversationsAttachedToTheMoment": "Your conversations, attached to the moment",
+ "stayConnectedWithThePeopleYouShareWith": "Stay connected with the people you share with",
+ "shareAnAlbum": "Share an album",
+ "seeWhatYourPeopleAreUpTo": "See what your people are up to",
+ "signUpToShareMomentsPrivately": "Sign up to share moments privately",
+ "reactToTheMomentsThatMatter": "React to the moments that matter",
+ "leaveANoteOnTheMomentsSharedWithYou": "Leave a note on the moments shared with you",
"like": "Like",
"comments": "Comments",
"commentHint": "Say something nice!",
diff --git a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/empty_state_feature_row.dart
similarity index 84%
rename from mobile/apps/photos/lib/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart
rename to mobile/apps/photos/lib/ui/tabs/albums/empty_states/empty_state_feature_row.dart
index c26b94cb63..a1e31f5474 100644
--- a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart
+++ b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/empty_state_feature_row.dart
@@ -2,8 +2,8 @@ import "package:flutter/widgets.dart";
import "package:hugeicons/hugeicons.dart";
import "package:photos/theme/ente_theme.dart";
-class AlbumsEmptyStateFeatureRow extends StatelessWidget {
- const AlbumsEmptyStateFeatureRow({
+class EmptyStateFeatureRow extends StatelessWidget {
+ const EmptyStateFeatureRow({
required this.icon,
required this.label,
super.key,
@@ -20,7 +20,7 @@ class AlbumsEmptyStateFeatureRow extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Padding(
- padding: const EdgeInsetsGeometry.all(6),
+ padding: const EdgeInsets.all(6),
child: HugeIcon(
icon: icon,
size: 20,
diff --git a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_device_select_folders_empty_state.dart b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_device_select_folders_empty_state.dart
index d04fd07b27..c900e702f8 100644
--- a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_device_select_folders_empty_state.dart
+++ b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_device_select_folders_empty_state.dart
@@ -4,7 +4,7 @@ import "package:photos/generated/l10n.dart";
import "package:photos/theme/ente_theme.dart";
import "package:photos/ui/common/backup_flow_helper.dart";
import "package:photos/ui/components/buttons/button_widget_v2.dart";
-import "package:photos/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart";
+import "package:photos/ui/tabs/albums/empty_states/empty_state_feature_row.dart";
class OnDeviceSelectFoldersEmptyState extends StatelessWidget {
const OnDeviceSelectFoldersEmptyState({
@@ -57,17 +57,17 @@ class OnDeviceSelectFoldersEmptyState extends StatelessWidget {
constraints: const BoxConstraints(maxWidth: 320),
child: Column(
children: [
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedFolder02,
label: strings.allYourDeviceAlbumsInOnePlace,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedCloudSavingDone01,
label: strings.youPickWhatGetsBackedUp,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedLockSync01,
label: strings.privateAndEndToEndEncryptedAlways,
),
diff --git a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_ente_empty_state.dart b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_ente_empty_state.dart
index c5606981a1..8abc0de1da 100644
--- a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_ente_empty_state.dart
+++ b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/on_ente_empty_state.dart
@@ -8,7 +8,7 @@ import "package:photos/services/collections_service.dart";
import "package:photos/theme/ente_theme.dart";
import "package:photos/ui/collections/album/smart_album_people.dart";
import "package:photos/ui/components/buttons/button_widget_v2.dart";
-import "package:photos/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart";
+import "package:photos/ui/tabs/albums/empty_states/empty_state_feature_row.dart";
import "package:photos/ui/viewer/gallery/collection_page.dart";
import "package:photos/utils/dialog_util.dart";
@@ -58,17 +58,17 @@ class OnEnteEmptyState extends StatelessWidget {
constraints: const BoxConstraints(maxWidth: 320),
child: Column(
children: [
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedLockSync01,
label: strings.endToEndEncryptedOnlyYourPeopleCanSeeIt,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedCloudSavingDone01,
label: strings.backedUpSafelyAcrossDevices,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedSparkles,
label: strings.smartAlbumsOrganizePhotosForYou,
),
diff --git a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/shared_empty_state.dart b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/shared_empty_state.dart
index 8015ee16d6..a7a5e04925 100644
--- a/mobile/apps/photos/lib/ui/tabs/albums/empty_states/shared_empty_state.dart
+++ b/mobile/apps/photos/lib/ui/tabs/albums/empty_states/shared_empty_state.dart
@@ -5,7 +5,7 @@ import "package:photos/service_locator.dart";
import "package:photos/services/account/user_service.dart";
import "package:photos/theme/ente_theme.dart";
import "package:photos/ui/components/buttons/button_widget_v2.dart";
-import "package:photos/ui/tabs/albums/empty_states/albums_empty_state_feature_row.dart";
+import "package:photos/ui/tabs/albums/empty_states/empty_state_feature_row.dart";
import "package:photos/utils/dialog_util.dart";
class SharedEmptyState extends StatelessWidget {
@@ -54,17 +54,17 @@ class SharedEmptyState extends StatelessWidget {
constraints: const BoxConstraints(maxWidth: 320),
child: Column(
children: [
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedUserMultiple,
label: strings.shareStorageWithUpToFiveFamilyMembers,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedLock,
label: strings.privateSpaceForEveryMember,
),
const SizedBox(height: 24),
- AlbumsEmptyStateFeatureRow(
+ EmptyStateFeatureRow(
icon: HugeIcons.strokeRoundedFavourite,
label: strings.reactAndChatOnSharedMemories,
),