diff --git a/lib/domain/profiles/profile_enums.dart b/lib/domain/profiles/profile_enums.dart index 88ae0eae..a8553edd 100644 --- a/lib/domain/profiles/profile_enums.dart +++ b/lib/domain/profiles/profile_enums.dart @@ -1,3 +1,4 @@ +import 'package:flutter/material.dart'; import 'package:hiddify/core/locale/locale.dart'; enum ProfilesSort { @@ -10,4 +11,9 @@ enum ProfilesSort { name => t.profile.sortBy.name, }; } + + IconData get icon => switch (this) { + lastUpdate => Icons.update, + name => Icons.sort_by_alpha, + }; } diff --git a/lib/features/common/profile_tile.dart b/lib/features/common/profile_tile.dart index be34b002..d2005ad6 100644 --- a/lib/features/common/profile_tile.dart +++ b/lib/features/common/profile_tile.dart @@ -162,7 +162,7 @@ class ProfileActionButton extends HookConsumerWidget { ref.read(profilesNotifierProvider.notifier).updateProfile(profile), ); }, - child: const Icon(Icons.refresh), + child: const Icon(Icons.update), ); } return ProfileActionsMenu( @@ -211,7 +211,7 @@ class ProfileActionsMenu extends HookConsumerWidget { builder: builder, menuChildren: [ MenuItemButton( - leadingIcon: const Icon(Icons.refresh), + leadingIcon: const Icon(Icons.update), child: Text(t.profile.update.buttonTxt.titleCase), onPressed: () { if (updateProfileMutation.state.isInProgress) { diff --git a/lib/features/profiles/view/profiles_modal.dart b/lib/features/profiles/view/profiles_modal.dart index 73f95b75..abc43b7b 100644 --- a/lib/features/profiles/view/profiles_modal.dart +++ b/lib/features/profiles/view/profiles_modal.dart @@ -115,6 +115,7 @@ class ProfilesSortModal extends HookConsumerWidget { } }, selected: selected, + leading: Icon(e.icon), trailing: selected ? IconButton( onPressed: () {