Center wallet setup screen around Peya branding
This commit is contained in:
@@ -19,44 +19,59 @@ class WalletSetupScreen extends ConsumerWidget {
|
||||
@override
|
||||
Widget build(BuildContext context, WidgetRef ref) {
|
||||
final state = ref.watch(walletControllerProvider);
|
||||
final l10n = context.l10n;
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text(l10n.walletSetupTitle),
|
||||
),
|
||||
body: Padding(
|
||||
padding: const EdgeInsets.all(24),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (state.error != null)
|
||||
_ErrorBanner(message: l10n.errorMessage(state.error!)),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
l10n.walletSetupSubtitle,
|
||||
style: Theme.of(context).textTheme.titleLarge,
|
||||
body: SafeArea(
|
||||
child: Center(
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(24),
|
||||
child: ConstrainedBox(
|
||||
constraints: const BoxConstraints(maxWidth: 860),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
if (state.error != null) ...[
|
||||
_ErrorBanner(message: context.l10n.errorMessage(state.error!)),
|
||||
const SizedBox(height: 24),
|
||||
],
|
||||
Image.asset(
|
||||
'assets/logo.png',
|
||||
width: 132,
|
||||
height: 132,
|
||||
),
|
||||
const SizedBox(height: 18),
|
||||
Text(
|
||||
'Peya Wallet',
|
||||
textAlign: TextAlign.center,
|
||||
style: Theme.of(context).textTheme.headlineMedium?.copyWith(
|
||||
fontWeight: FontWeight.w800,
|
||||
letterSpacing: 0.3,
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 32),
|
||||
Wrap(
|
||||
alignment: WrapAlignment.center,
|
||||
spacing: 16,
|
||||
runSpacing: 16,
|
||||
children: [
|
||||
_ActionCard(
|
||||
title: context.l10n.openWalletAction,
|
||||
onPressed: () => _showOpenDialog(context, ref),
|
||||
),
|
||||
_ActionCard(
|
||||
title: context.l10n.restoreWalletAction,
|
||||
onPressed: () => _showRestoreDialog(context, ref),
|
||||
),
|
||||
_ActionCard(
|
||||
title: context.l10n.createWalletAction,
|
||||
onPressed: () => _showCreateDialog(context, ref),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Wrap(
|
||||
spacing: 16,
|
||||
runSpacing: 16,
|
||||
children: [
|
||||
_ActionCard(
|
||||
title: l10n.openWalletAction,
|
||||
onPressed: () => _showOpenDialog(context, ref),
|
||||
),
|
||||
_ActionCard(
|
||||
title: l10n.restoreWalletAction,
|
||||
onPressed: () => _showRestoreDialog(context, ref),
|
||||
),
|
||||
_ActionCard(
|
||||
title: l10n.createWalletAction,
|
||||
onPressed: () => _showCreateDialog(context, ref),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user