Skip to content

armgit / ente

Public Imported from GitHub
0

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

fix: "Important" shouldnt have 3 dot menu since no actions

AmanRajSinghMourya975d1bc40b9e
diff --git a/mobile/apps/locker/lib/ui/components/collection_list_widget.dart b/mobile/apps/locker/lib/ui/components/collection_list_widget.dart
index 68e3503b83..cc27848edd 100644
--- a/mobile/apps/locker/lib/ui/components/collection_list_widget.dart
+++ b/mobile/apps/locker/lib/ui/components/collection_list_widget.dart
@@ -32,6 +32,7 @@ class CollectionListWidget extends StatelessWidget {
Widget build(BuildContext context) {
final textTheme = getEnteTextTheme(context);
final colorScheme = getEnteColorScheme(context);
+ final bool isFavourite = collection.type == CollectionType.favorites;
final collectionRowWidget = Flexible(
flex: 6,
@@ -128,32 +129,34 @@ class CollectionListWidget extends StatelessWidget {
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
collectionRowWidget,
- Flexible(
- flex: 1,
- child: AnimatedSwitcher(
- duration: const Duration(milliseconds: 200),
- switchInCurve: Curves.easeOut,
- switchOutCurve: Curves.easeIn,
- child: isSelected
- ? IconButtonWidget(
- key: const ValueKey("selected"),
- icon: Icons.check_circle_rounded,
- iconButtonType: IconButtonType.secondary,
- iconColor: colorScheme.primary700,
- )
- : CollectionPopupMenuWidget(
- collection: collection,
- overflowActions: overflowActions,
- child: Padding(
- padding: const EdgeInsets.all(12.0),
- child: HugeIcon(
- icon: HugeIcons.strokeRoundedMoreVertical,
- color: colorScheme.textBase,
- ),
- ),
- ),
- ),
- ),
+ isFavourite
+ ? const SizedBox.shrink()
+ : Flexible(
+ flex: 1,
+ child: AnimatedSwitcher(
+ duration: const Duration(milliseconds: 200),
+ switchInCurve: Curves.easeOut,
+ switchOutCurve: Curves.easeIn,
+ child: isSelected
+ ? IconButtonWidget(
+ key: const ValueKey("selected"),
+ icon: Icons.check_circle_rounded,
+ iconButtonType: IconButtonType.secondary,
+ iconColor: colorScheme.primary700,
+ )
+ : CollectionPopupMenuWidget(
+ collection: collection,
+ overflowActions: overflowActions,
+ child: Padding(
+ padding: const EdgeInsets.all(12.0),
+ child: HugeIcon(
+ icon: HugeIcons.strokeRoundedMoreVertical,
+ color: colorScheme.textBase,
+ ),
+ ),
+ ),
+ ),
+ ),
],
),
);
diff --git a/mobile/apps/locker/lib/ui/components/collection_row_widget.dart b/mobile/apps/locker/lib/ui/components/collection_row_widget.dart
index cf5892392a..f6ef26b424 100644
--- a/mobile/apps/locker/lib/ui/components/collection_row_widget.dart
+++ b/mobile/apps/locker/lib/ui/components/collection_row_widget.dart
@@ -32,6 +32,7 @@ class CollectionRowWidget extends StatelessWidget {
final colorScheme = getEnteColorScheme(context);
final textTheme = getEnteTextTheme(context);
final collectionName = collection.name ?? context.l10n.unnamedCollection;
+ final bool isFavourite = collection.type == CollectionType.favorites;
return GestureDetector(
onTap: () {
@@ -122,17 +123,19 @@ class CollectionRowWidget extends StatelessWidget {
),
),
const SizedBox(width: 4),
- AnimatedSwitcher(
- duration: const Duration(milliseconds: 200),
- switchInCurve: Curves.easeOut,
- switchOutCurve: Curves.easeIn,
- child: isSelected
- ? const SizedBox.shrink()
- : CollectionPopupMenuWidget(
- collection: collection,
- overflowActions: overflowActions,
- ),
- ),
+ isFavourite
+ ? const SizedBox.shrink()
+ : AnimatedSwitcher(
+ duration: const Duration(milliseconds: 200),
+ switchInCurve: Curves.easeOut,
+ switchOutCurve: Curves.easeIn,
+ child: isSelected
+ ? const SizedBox.shrink()
+ : CollectionPopupMenuWidget(
+ collection: collection,
+ overflowActions: overflowActions,
+ ),
+ ),
],
),
const SizedBox(height: 4),