Skip to content

Commit 9fc1096

Browse files
authored
bump dropdown_search to v6 (#1743)
* update dropdown search * fmt and lint
1 parent 591a77c commit 9fc1096

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

app/lib/common/components/address_input_field.dart

+5-6
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class _AddressInputFieldState extends State<AddressInputField> {
7171
);
7272
}
7373

74-
Widget _listItemBuilder(BuildContext context, AccountData account, bool isSelected) {
74+
Widget _listItemBuilder(BuildContext context, AccountData account, bool isDisabled, bool isSelected) {
7575
final address =
7676
AddressUtils.pubKeyHexToAddress(account.pubKey, prefix: widget.store.settings.currentNetwork.ss58());
7777

@@ -110,7 +110,6 @@ class _AddressInputFieldState extends State<AddressInputField> {
110110
child: DropdownSearch<AccountData>(
111111
key: const Key(EWTestKeys.transferSelectAccount),
112112
popupProps: PopupProps.modalBottomSheet(
113-
isFilterOnline: true,
114113
showSearchBox: true,
115114
showSelectedItems: true,
116115
itemBuilder: _listItemBuilder,
@@ -124,7 +123,7 @@ class _AddressInputFieldState extends State<AddressInputField> {
124123
address: address,
125124
pubKey: pubKey,
126125
);
127-
return _listItemBuilder(context, newAccount, false);
126+
return _listItemBuilder(context, newAccount, false, false);
128127
} else {
129128
return Align(
130129
alignment: Alignment.topCenter,
@@ -133,8 +132,8 @@ class _AddressInputFieldState extends State<AddressInputField> {
133132
}
134133
},
135134
),
136-
dropdownDecoratorProps: DropDownDecoratorProps(
137-
dropdownSearchDecoration: InputDecoration(
135+
decoratorProps: DropDownDecoratorProps(
136+
decoration: InputDecoration(
138137
labelText: widget.label,
139138
labelStyle: context.bodyLarge.copyWith(color: context.colorScheme.primary),
140139
contentPadding: const EdgeInsets.symmetric(vertical: 16, horizontal: 25),
@@ -146,7 +145,7 @@ class _AddressInputFieldState extends State<AddressInputField> {
146145
selectedItem: widget.initialValue,
147146
compareFn: (AccountData i, s) => i.pubKey == s.pubKey,
148147
validator: (AccountData? u) => u == null ? l10n.errorUserNameIsRequired : null,
149-
items: widget.store.settings.knownAccounts,
148+
items: (_, __) => widget.store.settings.knownAccounts,
150149
filterFn: filterByAddressOrName,
151150
onChanged: (AccountData? data) {
152151
if (widget.onChanged != null && data != null) {

app/pubspec.lock

+2-2
Original file line numberDiff line numberDiff line change
@@ -413,10 +413,10 @@ packages:
413413
dependency: "direct main"
414414
description:
415415
name: dropdown_search
416-
sha256: "55106e8290acaa97ed15bea1fdad82c3cf0c248dd410e651f5a8ac6870f783ab"
416+
sha256: "8c96aaf8d0c0d4307804b28da73866e5a0fc94fd8e6942eceab896450aaa4999"
417417
url: "https://pub.dev"
418418
source: hosted
419-
version: "5.0.6"
419+
version: "6.0.1"
420420
ed25519_edwards:
421421
dependency: transitive
422422
description:

app/pubspec.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ dependencies:
5656
permission_handler: ^11.3.1
5757
flutter_svg: ^2.0.17
5858
url_launcher: ^6.3.1
59-
dropdown_search: ^5.0.6
59+
dropdown_search: ^6.0.1
6060
provider: ^6.1.2
6161
flutter_map_marker_popup: ^7.0.0
6262
flutter_map: ^7.0.2

0 commit comments

Comments
 (0)