Skip to content

armgit / ente

Public Imported from GitHub
0

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

Remove item count

vishnukvmd9dcced8c1ff0
diff --git a/mobile/apps/locker/lib/ui/collections/section_title.dart b/mobile/apps/locker/lib/ui/collections/section_title.dart
index c0c559c128..5c7594038f 100644
--- a/mobile/apps/locker/lib/ui/collections/section_title.dart
+++ b/mobile/apps/locker/lib/ui/collections/section_title.dart
@@ -49,6 +49,7 @@ class SectionOptions extends StatelessWidget {
@override
Widget build(BuildContext context) {
if (trailingWidget != null) {
+ final hasBody = body != null && body!.isNotEmpty;
return GestureDetector(
behavior: HitTestBehavior.opaque,
onTap: onTap,
@@ -62,10 +63,11 @@ class SectionOptions extends StatelessWidget {
trailingWidget!,
],
),
- Text(
- body ?? "",
- style: getEnteTextTheme(context).bodyMuted,
- ),
+ if (hasBody)
+ Text(
+ body!,
+ style: getEnteTextTheme(context).bodyMuted,
+ ),
],
),
);
diff --git a/mobile/apps/locker/lib/ui/components/recents_section_widget.dart b/mobile/apps/locker/lib/ui/components/recents_section_widget.dart
index 09d6477080..bde99a1a29 100644
--- a/mobile/apps/locker/lib/ui/components/recents_section_widget.dart
+++ b/mobile/apps/locker/lib/ui/components/recents_section_widget.dart
@@ -99,7 +99,6 @@ class _RecentsSectionWidgetState extends State<RecentsSectionWidget> {
Widget _buildRecentsHeader() {
final colorScheme = getEnteColorScheme(context);
return SectionOptions(
- body: context.l10n.items(_displayedFiles.length),
SectionTitle(title: context.l10n.recents),
trailingWidget: GestureDetector(
onTap: () {
diff --git a/mobile/apps/locker/lib/ui/pages/home_page.dart b/mobile/apps/locker/lib/ui/pages/home_page.dart
index 843c54c20b..b0d384319f 100644
--- a/mobile/apps/locker/lib/ui/pages/home_page.dart
+++ b/mobile/apps/locker/lib/ui/pages/home_page.dart
@@ -720,6 +720,7 @@ class _HomePageState extends UploaderPageState<HomePage>
final colorScheme = getEnteColorScheme(context);
return [
SectionOptions(
+ SectionTitle(title: title),
onTap: () {
Navigator.of(context).push(
MaterialPageRoute(
@@ -730,15 +731,13 @@ class _HomePageState extends UploaderPageState<HomePage>
),
);
},
- body: context.l10n.items(collections.length),
- SectionTitle(title: title),
trailingWidget: IconButtonWidget(
icon: Icons.chevron_right,
iconButtonType: IconButtonType.secondary,
iconColor: colorScheme.textBase,
),
),
- const SizedBox(height: 24),
+ const SizedBox(height: 12),
CollectionFlexGridViewWidget(
collections: collections,
),