Skip to content

Commit

Permalink
fix(#60):Correção do erro na página de recurar conta
Browse files Browse the repository at this point in the history
Co-authored-by: zDrNz <[email protected]>
  • Loading branch information
2 people authored and GabrielCostaDeOliveira committed Dec 13, 2024
1 parent 4a9c766 commit 23823a8
Showing 1 changed file with 47 additions and 45 deletions.
92 changes: 47 additions & 45 deletions lib/ui/recover_account/view/RecoverAccount.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,55 +9,57 @@ class RecoverAccount extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
body: ChangeNotifierProvider(
create: (context) => RecoverAccountViewModel(context),
child: page(context),
));
body: ChangeNotifierProvider(
create: (context) => RecoverAccountViewModel(context),
builder: (context, child) {
return page(context);
}),
);
}
}

Widget page(BuildContext context) {
RecoverAccountViewModel viewModel =
Provider.of<RecoverAccountViewModel>(context);
Widget page(BuildContext context) {
RecoverAccountViewModel viewModel =
Provider.of<RecoverAccountViewModel>(context);

return SingleChildScrollView(
child: Center(
child: Column(
children: <Widget>[
const SizedBox(height: 80),
const TitleSlogan(),
const Padding(
padding: EdgeInsets.only(top: 70, left: 20, right: 20),
child: Text(
'Coloque o seu e-mail no campo abaixo e clique em enviar. Logo em seguida, você receberá no seu e-mail as instruções para trocar a sua senha.',
),
return SingleChildScrollView(
child: Center(
child: Column(
children: <Widget>[
const SizedBox(height: 80),
const TitleSlogan(),
const Padding(
padding: EdgeInsets.only(top: 70, left: 20, right: 20),
child: Text(
'Coloque o seu e-mail no campo abaixo e clique em enviar. Logo em seguida, você receberá no seu e-mail as instruções para trocar a sua senha.',
),
Form(
key: viewModel.formKey,
child: Column(children: <Widget>[
TextEmail(
padding:
const EdgeInsets.only(top: 24, left: 20, right: 20),
controller: viewModel.emailController),
])),
Padding(
padding: const EdgeInsets.only(top: 80),
child: SizedBox(
width: 291,
height: 64,
child: ElevatedButton(
onPressed: () {}, child: const Text('Enviar')),
),
),
Form(
key: viewModel.formKey,
child: Column(children: <Widget>[
TextEmail(
padding:
const EdgeInsets.only(top: 24, left: 20, right: 20),
controller: viewModel.emailController),
])),
Padding(
padding: const EdgeInsets.only(top: 80),
child: SizedBox(
width: 291,
height: 64,
child:
ElevatedButton(onPressed: () {}, child: const Text('Enviar')),
),
TextAndLink(
text: 'Já tem uma conta?',
link: ' Click aqui',
action: () {
Navigator.of(context).pop();
},
)
],
),
),
TextAndLink(
text: 'Já tem uma conta?',
link: ' Click aqui',
action: () {
Navigator.of(context).pop();
},
)
],
),
);
}
),
);
}

0 comments on commit 23823a8

Please sign in to comment.