Skip to content

Commit

Permalink
[profile/account_manage_page] replace expanded widget with spacer
Browse files Browse the repository at this point in the history
  • Loading branch information
clangenb committed Aug 9, 2023
1 parent 155428b commit adc0d20
Showing 1 changed file with 24 additions and 27 deletions.
51 changes: 24 additions & 27 deletions app/lib/page/profile/account/account_manage_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -220,34 +220,31 @@ class _AccountManagePageState extends State<AccountManagePage> {
),
),
if (appSettingsStore.developerMode)
Expanded(
child: ListView.builder(
// Fixme: https://github.com/encointer/encointer-wallet-flutter/issues/586
itemCount: store.encointer.accountStores!.containsKey(addressSS58)
? store.encointer.accountStores![addressSS58]?.balanceEntries.length ?? 0
: 0,
itemBuilder: (BuildContext context, int index) {
final community =
store.encointer.accountStores![addressSS58]!.balanceEntries.keys.elementAt(index);
return _getBalanceEntryListTile(
community,
store.encointer.accountStores![addressSS58]!.balanceEntries[community],
addressSS58,
);
}),
)
ListView.builder(
// Fixme: https://github.com/encointer/encointer-wallet-flutter/issues/586
itemCount: store.encointer.accountStores!.containsKey(addressSS58)
? store.encointer.accountStores![addressSS58]?.balanceEntries.length ?? 0
: 0,
itemBuilder: (BuildContext context, int index) {
final community =
store.encointer.accountStores![addressSS58]!.balanceEntries.keys.elementAt(index);
return _getBalanceEntryListTile(
community,
store.encointer.accountStores![addressSS58]!.balanceEntries[community],
addressSS58,
);
})
else
Expanded(
child: ListView.builder(
itemCount: store.encointer.chosenCid != null ? 1 : 0,
itemBuilder: (BuildContext context, int index) {
return _getBalanceEntryListTile(
_appStore.encointer.chosenCid!.toFmtString(),
_appStore.encointer.communityBalanceEntry,
addressSS58,
);
}),
),
ListView.builder(
itemCount: store.encointer.chosenCid != null ? 1 : 0,
itemBuilder: (BuildContext context, int index) {
return _getBalanceEntryListTile(
_appStore.encointer.chosenCid!.toFmtString(),
_appStore.encointer.communityBalanceEntry,
addressSS58,
);
}),
const Spacer(),
DecoratedBox(
// width: double.infinity,
decoration: BoxDecoration(
Expand Down

0 comments on commit adc0d20

Please sign in to comment.