mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-23 11:59:30 +00:00
address book search fixes
This commit is contained in:
parent
49103c86f1
commit
8c0a6f5669
2 changed files with 26 additions and 26 deletions
|
@ -261,6 +261,7 @@ class _AddressBookViewState extends ConsumerState<AddressBookView> {
|
|||
onTap: () async {
|
||||
setState(() {
|
||||
_searchController.text = "";
|
||||
_searchTerm = "";
|
||||
});
|
||||
},
|
||||
),
|
||||
|
|
|
@ -152,12 +152,6 @@ class _DesktopAddressBook extends ConsumerState<DesktopAddressBook> {
|
|||
ref.read(addressBookServiceProvider).matches(_searchTerm, e))
|
||||
.where((element) => element.isFavorite);
|
||||
|
||||
print("=========================================================");
|
||||
print("contacts: ${contacts.length}");
|
||||
print("favorites: ${favorites.length}");
|
||||
print("allContacts: ${allContacts.length}");
|
||||
print("=========================================================");
|
||||
|
||||
return DesktopScaffold(
|
||||
appBar: DesktopAppBar(
|
||||
isCompactHeight: true,
|
||||
|
@ -222,6 +216,7 @@ class _DesktopAddressBook extends ConsumerState<DesktopAddressBook> {
|
|||
onTap: () async {
|
||||
setState(() {
|
||||
_searchController.text = "";
|
||||
_searchTerm = "";
|
||||
});
|
||||
},
|
||||
),
|
||||
|
@ -284,8 +279,18 @@ class _DesktopAddressBook extends ConsumerState<DesktopAddressBook> {
|
|||
style: STextStyles.smallMed12(context),
|
||||
),
|
||||
),
|
||||
favorites: favorites.isNotEmpty
|
||||
? RoundedWhiteContainer(
|
||||
favorites: favorites.isEmpty
|
||||
? contacts.isNotEmpty
|
||||
? null
|
||||
: RoundedWhiteContainer(
|
||||
child: Center(
|
||||
child: Text(
|
||||
"Your favorite contacts will appear here",
|
||||
style: STextStyles.itemSubtitle(context),
|
||||
),
|
||||
),
|
||||
)
|
||||
: RoundedWhiteContainer(
|
||||
padding: const EdgeInsets.all(0),
|
||||
child: Column(
|
||||
children: [
|
||||
|
@ -297,17 +302,19 @@ class _DesktopAddressBook extends ConsumerState<DesktopAddressBook> {
|
|||
),
|
||||
],
|
||||
),
|
||||
)
|
||||
),
|
||||
all: allContacts.isEmpty
|
||||
? contacts.isNotEmpty
|
||||
? null
|
||||
: RoundedWhiteContainer(
|
||||
child: Center(
|
||||
child: Text(
|
||||
"Your favorite contacts will appear here",
|
||||
"Your contacts will appear here",
|
||||
style: STextStyles.itemSubtitle(context),
|
||||
),
|
||||
),
|
||||
),
|
||||
all: allContacts.isNotEmpty
|
||||
? Column(
|
||||
)
|
||||
: Column(
|
||||
children: [
|
||||
RoundedWhiteContainer(
|
||||
padding: const EdgeInsets.all(0),
|
||||
|
@ -326,14 +333,6 @@ class _DesktopAddressBook extends ConsumerState<DesktopAddressBook> {
|
|||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
: RoundedWhiteContainer(
|
||||
child: Center(
|
||||
child: Text(
|
||||
"Your contacts will appear here",
|
||||
style: STextStyles.itemSubtitle(context),
|
||||
),
|
||||
),
|
||||
),
|
||||
details: Container(
|
||||
color: Colors.purple,
|
||||
|
|
Loading…
Reference in a new issue