@@ -3,7 +3,6 @@ import 'package:bb_mobile/core/utils/build_context_x.dart';
33import 'package:bb_mobile/core/widgets/bip85_derivation_widget.dart' ;
44import 'package:bb_mobile/core/widgets/buttons/button.dart' ;
55import 'package:bb_mobile/core/widgets/loading/fading_linear_progress.dart' ;
6- import 'package:bb_mobile/core/widgets/scrollable_column.dart' ;
76import 'package:bb_mobile/features/bip85_entropy/presentation/cubit.dart' ;
87import 'package:bb_mobile/features/bip85_entropy/presentation/state.dart' ;
98import 'package:flutter/material.dart' ;
@@ -23,9 +22,11 @@ class Bip85HomePage extends StatelessWidget {
2322
2423 return Padding (
2524 padding: const EdgeInsets .symmetric (vertical: 16 ),
26- child: ScrollableColumn (
25+ child: Column (
2726 children: [
28- FadingLinearProgress (trigger: state.xprvBase58.isEmpty),
27+ FadingLinearProgress (
28+ trigger: state.xprvBase58.isEmpty || state.isLoading,
29+ ),
2930 Container (
3031 margin: const EdgeInsets .all (16 ),
3132 padding: const EdgeInsets .all (12 ),
@@ -48,36 +49,44 @@ class Bip85HomePage extends StatelessWidget {
4849 ),
4950 const Gap (16 ),
5051 if (state.derivations.isNotEmpty && state.xprvBase58.isNotEmpty)
51- ...List .generate (state.derivations.length, (index) {
52- final derivation = state.derivations[index];
53- return Padding (
54- padding: const EdgeInsets .symmetric (vertical: 2 ),
55- child: Bip85DerivationWidget (
56- xprvBase58: state.xprvBase58,
57- derivation: derivation,
58- onAliasChanged: cubit.aliasDerivation,
59- onDerivationRevoked: cubit.revokeDerivation,
60- onDerivationActivated: cubit.activateDerivation,
61- ),
62- );
63- }),
64- const Gap (16 ),
65- Row (
66- mainAxisAlignment: .spaceBetween,
67- children: [
68- BBButton .small (
69- onPressed: () => cubit.deriveNextMnemonic (),
70- label: context.loc.bip85NextMnemonic,
71- bgColor: context.appColors.onSurface,
72- textColor: context.appColors.surface,
52+ Expanded (
53+ child: ListView .builder (
54+ itemCount: state.derivations.length,
55+ itemBuilder: (context, index) {
56+ final derivation = state.derivations[index];
57+ return Padding (
58+ padding: const EdgeInsets .all (8 ),
59+ child: Bip85DerivationWidget (
60+ xprvBase58: state.xprvBase58,
61+ derivation: derivation,
62+ onAliasChanged: cubit.aliasDerivation,
63+ onDerivationRevoked: cubit.revokeDerivation,
64+ onDerivationActivated: cubit.activateDerivation,
65+ ),
66+ );
67+ },
7368 ),
74- BBButton .small (
75- onPressed: () => cubit.deriveNextHex (),
76- label: context.loc.bip85NextHex,
77- bgColor: context.appColors.onSurface,
78- textColor: context.appColors.surface,
79- ),
80- ],
69+ ),
70+ const Gap (16 ),
71+ Padding (
72+ padding: const EdgeInsets .symmetric (horizontal: 16 ),
73+ child: Row (
74+ mainAxisAlignment: .spaceBetween,
75+ children: [
76+ BBButton .small (
77+ onPressed: () => cubit.deriveNextMnemonic (),
78+ label: context.loc.bip85NextMnemonic,
79+ bgColor: context.appColors.onSurface,
80+ textColor: context.appColors.surface,
81+ ),
82+ BBButton .small (
83+ onPressed: () => cubit.deriveNextHex (),
84+ label: context.loc.bip85NextHex,
85+ bgColor: context.appColors.onSurface,
86+ textColor: context.appColors.surface,
87+ ),
88+ ],
89+ ),
8190 ),
8291 ],
8392 ),
0 commit comments