Feat: Ajuste na responsividade da tela de Welcome, Login, Registe e Forgot Password
This commit is contained in:
parent
4497df1b04
commit
c22e1bff5e
|
@ -1,7 +1,8 @@
|
|||
{
|
||||
"editor.quickSuggestions": {
|
||||
"comments": "off",
|
||||
"strings": "off",
|
||||
"other": "off"
|
||||
}
|
||||
}
|
||||
"editor.quickSuggestions": {
|
||||
"comments": "off",
|
||||
"strings": "off",
|
||||
"other": "off"
|
||||
},
|
||||
"java.configuration.updateBuildConfiguration": "automatic"
|
||||
}
|
||||
|
|
|
@ -57,12 +57,12 @@ android {
|
|||
|
||||
compileOptions {
|
||||
coreLibraryDesugaringEnabled true
|
||||
sourceCompatibility JavaVersion.VERSION_18
|
||||
targetCompatibility JavaVersion.VERSION_18
|
||||
sourceCompatibility JavaVersion.VERSION_11
|
||||
targetCompatibility JavaVersion.VERSION_11
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = "18"
|
||||
jvmTarget = "11"
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
import 'package:easy_debounce/easy_debounce.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
|
@ -53,173 +52,103 @@ class _ForgotPasswordTemplateComponentWidgetState
|
|||
Widget build(BuildContext context) {
|
||||
return Align(
|
||||
alignment: const AlignmentDirectional(0.0, 1.0),
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
height: 300.0,
|
||||
constraints: const BoxConstraints(
|
||||
maxWidth: 570.0,
|
||||
),
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(0.0),
|
||||
bottomRight: Radius.circular(0.0),
|
||||
topLeft: Radius.circular(15.0),
|
||||
topRight: Radius.circular(15.0),
|
||||
child: SingleChildScrollView(
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
constraints: const BoxConstraints(
|
||||
maxWidth: 570.0,
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (responsiveVisibility(
|
||||
context: context,
|
||||
phone: false,
|
||||
tablet: false,
|
||||
))
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(16.0, 0.0, 16.0, 8.0),
|
||||
child: InkWell(
|
||||
key: const ValueKey<String>('BackButton'),
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.safePop();
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 12.0, 0.0, 12.0),
|
||||
child: Icon(
|
||||
Icons.arrow_back_rounded,
|
||||
color: Color(0xFF15161E),
|
||||
size: 24.0,
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(12.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
'',
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterFlowTheme.of(context).primaryBackground,
|
||||
borderRadius: const BorderRadius.only(
|
||||
bottomLeft: Radius.circular(0.0),
|
||||
bottomRight: Radius.circular(0.0),
|
||||
topLeft: Radius.circular(15.0),
|
||||
topRight: Radius.circular(15.0),
|
||||
),
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(0, 25, 0, 25),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (responsiveVisibility(
|
||||
context: context,
|
||||
phone: false,
|
||||
tablet: false,
|
||||
))
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 16.0, 8.0),
|
||||
child: InkWell(
|
||||
key: const ValueKey<String>('BackButton'),
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.safePop();
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 12.0, 0.0, 12.0),
|
||||
child: Icon(
|
||||
Icons.arrow_back_rounded,
|
||||
color: Color(0xFF15161E),
|
||||
size: 24.0,
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
12.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
'',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: const Color(0xFF15161E),
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey('Plus Jakarta Sans'),
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(16.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context)
|
||||
.getText('xxm3ajsy' /* ESQUECEU SUA SENHA? */),
|
||||
style: FlutterFlowTheme.of(context).headlineMedium.override(
|
||||
fontFamily: 'Outfit',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 24.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts:
|
||||
GoogleFonts.asMap().containsKey('Outfit'),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(16.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText('xxm3ajsy' /* ESQUECEU SUA SENHA? */),
|
||||
style: FlutterFlowTheme.of(context).headlineMedium.override(
|
||||
fontFamily: 'Outfit',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 24.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey('Outfit'),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(16.0, 4.0, 16.0, 4.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText('wu2f7yzo' /* Não se preucupe nós vamos te a... */),
|
||||
style: FlutterFlowTheme.of(context).labelMedium.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts:
|
||||
GoogleFonts.asMap().containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
),
|
||||
Form(
|
||||
key: _model.formKey,
|
||||
autovalidateMode: AutovalidateMode.onUserInteraction,
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(16.0, 12.0, 16.0, 0.0),
|
||||
child: SizedBox(
|
||||
width: double.infinity,
|
||||
child: TextFormField(
|
||||
key: const ValueKey<String>('recoveryTextFormField'),
|
||||
controller: _model.emailAddressTextController,
|
||||
focusNode: _model.emailAddressFocusNode,
|
||||
onChanged: (_) => EasyDebounce.debounce(
|
||||
'_model.emailAddressTextController',
|
||||
const Duration(milliseconds: 500),
|
||||
() => setState(() {}),
|
||||
),
|
||||
autofocus: true,
|
||||
autofillHints: const [AutofillHints.email],
|
||||
obscureText: false,
|
||||
decoration: InputDecoration(
|
||||
isDense: true,
|
||||
labelText: FFLocalizations.of(context).getText('mtz8l7ft' /* E-mail */),
|
||||
labelStyle: FlutterFlowTheme.of(context).labelMedium.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderSide: const BorderSide(
|
||||
color: Colors.black,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).error,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).error,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
contentPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
24.0, 24.0, 20.0, 24.0),
|
||||
suffixIcon: Icon(
|
||||
Icons.email,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
size: 22.0,
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 4.0, 16.0, 4.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'wu2f7yzo' /* Não se preucupe nós vamos te a... */),
|
||||
style: FlutterFlowTheme.of(context).labelMedium.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 14.0,
|
||||
|
@ -228,62 +157,147 @@ class _ForgotPasswordTemplateComponentWidgetState
|
|||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
maxLines: null,
|
||||
keyboardType: TextInputType.emailAddress,
|
||||
cursorColor: FlutterFlowTheme.of(context).primary,
|
||||
validator: _model.emailAddressTextControllerValidator
|
||||
.asValidator(context),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0.0, 24.0, 0.0, 0.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('SendButtonWidget'),
|
||||
onPressed: (_model.emailAddressTextController.text == '' ||
|
||||
!ValidatorUtil.isValidEmail(
|
||||
_model.emailAddressTextController.text))
|
||||
? null
|
||||
: () async => AuthenticationService.forgotPassword(context, _model.emailAddressTextController.text),
|
||||
|
||||
|
||||
text: FFLocalizations.of(context).getText(
|
||||
'74rnd5bu' /* Enviar */,
|
||||
),
|
||||
options: FFButtonOptions(
|
||||
width: 270.0,
|
||||
height: 50.0,
|
||||
Form(
|
||||
key: _model.formKey,
|
||||
autovalidateMode: AutovalidateMode.onUserInteraction,
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
textStyle: FlutterFlowTheme.of(context).titleSmall.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
16.0, 12.0, 16.0, 0.0),
|
||||
child: SizedBox(
|
||||
width: double.infinity,
|
||||
child: TextFormField(
|
||||
key: const ValueKey<String>('recoveryTextFormField'),
|
||||
controller: _model.emailAddressTextController,
|
||||
focusNode: _model.emailAddressFocusNode,
|
||||
onChanged: (_) => EasyDebounce.debounce(
|
||||
'_model.emailAddressTextController',
|
||||
const Duration(milliseconds: 500),
|
||||
() => setState(() {}),
|
||||
),
|
||||
elevation: 3.0,
|
||||
borderSide: const BorderSide(
|
||||
color: Colors.transparent,
|
||||
width: 1.0,
|
||||
autofocus: true,
|
||||
autofillHints: const [AutofillHints.email],
|
||||
obscureText: false,
|
||||
decoration: InputDecoration(
|
||||
isDense: true,
|
||||
labelText: FFLocalizations.of(context)
|
||||
.getText('mtz8l7ft' /* E-mail */),
|
||||
labelStyle:
|
||||
FlutterFlowTheme.of(context).labelMedium.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderSide: const BorderSide(
|
||||
color: Colors.black,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
errorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).error,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
focusedErrorBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(
|
||||
color: FlutterFlowTheme.of(context).error,
|
||||
width: 2.00,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
),
|
||||
contentPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
24.0, 24.0, 20.0, 24.0),
|
||||
suffixIcon: Icon(
|
||||
Icons.email,
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
size: 22.0,
|
||||
),
|
||||
),
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 14.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
maxLines: null,
|
||||
keyboardType: TextInputType.emailAddress,
|
||||
cursorColor: FlutterFlowTheme.of(context).primary,
|
||||
validator: _model.emailAddressTextControllerValidator
|
||||
.asValidator(context),
|
||||
),
|
||||
),
|
||||
disabledColor: FlutterFlowTheme.of(context).customColor5,
|
||||
disabledTextColor: Colors.white,
|
||||
),
|
||||
showLoadingIndicator: true,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 24.0, 0.0, 0.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('SendButtonWidget'),
|
||||
onPressed: (_model.emailAddressTextController.text ==
|
||||
'' ||
|
||||
!ValidatorUtil.isValidEmail(
|
||||
_model.emailAddressTextController.text))
|
||||
? null
|
||||
: () async => AuthenticationService.forgotPassword(
|
||||
context, _model.emailAddressTextController.text),
|
||||
text: FFLocalizations.of(context).getText(
|
||||
'74rnd5bu' /* Enviar */,
|
||||
),
|
||||
options: FFButtonOptions(
|
||||
width: 270.0,
|
||||
height: 50.0,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 0.0),
|
||||
color: FlutterFlowTheme.of(context).primary,
|
||||
textStyle:
|
||||
FlutterFlowTheme.of(context).titleSmall.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
elevation: 3.0,
|
||||
borderSide: const BorderSide(
|
||||
color: Colors.transparent,
|
||||
width: 1.0,
|
||||
),
|
||||
disabledColor:
|
||||
FlutterFlowTheme.of(context).customColor5,
|
||||
disabledTextColor: Colors.white,
|
||||
),
|
||||
showLoadingIndicator: true,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -17,12 +17,16 @@ import 'sign_up_template_component_model.dart';
|
|||
export 'sign_up_template_component_model.dart';
|
||||
|
||||
class SignUpTemplateComponentWidget extends StatefulWidget {
|
||||
const SignUpTemplateComponentWidget({super.key, required this.toggleSignInPage});
|
||||
const SignUpTemplateComponentWidget(
|
||||
{super.key, required this.toggleSignInPage});
|
||||
final Future Function()? toggleSignInPage;
|
||||
@override State<SignUpTemplateComponentWidget> createState() => _SignUpTemplateComponentWidgetState();
|
||||
@override
|
||||
State<SignUpTemplateComponentWidget> createState() =>
|
||||
_SignUpTemplateComponentWidgetState();
|
||||
}
|
||||
|
||||
class _SignUpTemplateComponentWidgetState extends State<SignUpTemplateComponentWidget> with TickerProviderStateMixin {
|
||||
class _SignUpTemplateComponentWidgetState
|
||||
extends State<SignUpTemplateComponentWidget> with TickerProviderStateMixin {
|
||||
late SignUpTemplateComponentModel _model;
|
||||
final animationsMap = <String, AnimationInfo>{};
|
||||
|
||||
|
@ -137,48 +141,30 @@ class _SignUpTemplateComponentWidgetState extends State<SignUpTemplateComponentW
|
|||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(4.0),
|
||||
child: Container(
|
||||
width: 669.0,
|
||||
height: 112.0,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(16.0),
|
||||
),
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(20.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Expanded(
|
||||
child: Align(
|
||||
alignment:
|
||||
const AlignmentDirectional(0.0, -1.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(4.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'49609olv' /* INSIRA SEU EMAIL E SENHA, VAMO... */,
|
||||
),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.displaySmall
|
||||
.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
fontSize: screenWidth * 0.06,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey(
|
||||
'Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
padding: const EdgeInsets.all(20.0),
|
||||
child: Expanded(
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(0.0, -1.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(4.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'49609olv' /* INSIRA SEU EMAIL E SENHA, VAMO... */,
|
||||
),
|
||||
],
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.displaySmall
|
||||
.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primaryText,
|
||||
fontSize: screenWidth * 0.06,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
@ -628,7 +614,9 @@ class _SignUpTemplateComponentWidgetState extends State<SignUpTemplateComponentW
|
|||
context)
|
||||
.primaryBackground,
|
||||
suffixIcon: InkWell(
|
||||
key: const ValueKey<String>('passwordVisibilitySuffixIcon'),
|
||||
key: const ValueKey<
|
||||
String>(
|
||||
'passwordVisibilitySuffixIcon'),
|
||||
onTap: () => setState(
|
||||
() => _model
|
||||
.passwordRegisterFormVisibility =
|
||||
|
@ -683,24 +671,40 @@ class _SignUpTemplateComponentWidgetState extends State<SignUpTemplateComponentW
|
|||
padding: const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 0.0, 0.0, 16.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('SubmitButtonWidget'),
|
||||
key: const ValueKey<String>(
|
||||
'SubmitButtonWidget'),
|
||||
onPressed: isFormInvalid()
|
||||
? null
|
||||
: () async {
|
||||
var shouldSetState = false;
|
||||
_model.register = await AuthenticationService.signUp(context,
|
||||
email: _model.emailRegisterFormTextController.text,
|
||||
name: _model.nameRegisterFormTextController.text,
|
||||
passwd: _model.passwordRegisterFormTextController.text,
|
||||
device: StorageUtil().deviceType,
|
||||
_model.register =
|
||||
await AuthenticationService
|
||||
.signUp(
|
||||
context,
|
||||
email: _model
|
||||
.emailRegisterFormTextController
|
||||
.text,
|
||||
name: _model
|
||||
.nameRegisterFormTextController
|
||||
.text,
|
||||
passwd: _model
|
||||
.passwordRegisterFormTextController
|
||||
.text,
|
||||
device: StorageUtil()
|
||||
.deviceType,
|
||||
);
|
||||
shouldSetState = true;
|
||||
if (_model.register == true) await widget.toggleSignInPage?.call();
|
||||
if (_model.register == true)
|
||||
await widget
|
||||
.toggleSignInPage
|
||||
?.call();
|
||||
else {
|
||||
if (shouldSetState) setState(() {});
|
||||
if (shouldSetState)
|
||||
setState(() {});
|
||||
return;
|
||||
}
|
||||
if (shouldSetState) setState(() {});
|
||||
if (shouldSetState)
|
||||
setState(() {});
|
||||
},
|
||||
text: FFLocalizations.of(context)
|
||||
.getText(
|
||||
|
@ -755,12 +759,15 @@ class _SignUpTemplateComponentWidgetState extends State<SignUpTemplateComponentW
|
|||
padding: const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 12.0, 0.0, 12.0),
|
||||
child: InkWell(
|
||||
key: const ValueKey<String>('toggleSignInPage'),
|
||||
key: const ValueKey<String>(
|
||||
'toggleSignInPage'),
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async => await widget.toggleSignInPage?.call(),
|
||||
onTap: () async => await widget
|
||||
.toggleSignInPage
|
||||
?.call(),
|
||||
child: RichText(
|
||||
textScaler: MediaQuery.of(context)
|
||||
.textScaler,
|
||||
|
|
|
@ -26,7 +26,9 @@ class WelcomeTemplateComponentWidget extends StatefulWidget {
|
|||
_WelcomeTemplateComponentWidgetState();
|
||||
}
|
||||
|
||||
class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponentWidget> with TickerProviderStateMixin {
|
||||
class _WelcomeTemplateComponentWidgetState
|
||||
extends State<WelcomeTemplateComponentWidget>
|
||||
with TickerProviderStateMixin {
|
||||
late WelcomeTemplateComponentModel _model;
|
||||
final animationsMap = <String, AnimationInfo>{};
|
||||
|
||||
|
@ -41,39 +43,38 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
super.initState();
|
||||
_model = createModel(context, () => WelcomeTemplateComponentModel());
|
||||
|
||||
animationsMap.addAll(
|
||||
<String, AnimationInfo>{
|
||||
'containerOnPageLoadAnimation': AnimationInfo(
|
||||
trigger: AnimationTrigger.onPageLoad,
|
||||
effectsBuilder: () => [
|
||||
VisibilityEffect(duration: 1.ms),
|
||||
FadeEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: 0.0,
|
||||
end: 1.0,
|
||||
),
|
||||
MoveEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(0.0, 140.0),
|
||||
end: const Offset(0.0, 0.0),
|
||||
),
|
||||
ScaleEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(0.9, 0.9),
|
||||
end: const Offset(1.0, 1.0),
|
||||
),
|
||||
TiltEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(-0.349, 0),
|
||||
end: const Offset(0, 0),
|
||||
animationsMap.addAll(<String, AnimationInfo>{
|
||||
'containerOnPageLoadAnimation': AnimationInfo(
|
||||
trigger: AnimationTrigger.onPageLoad,
|
||||
effectsBuilder: () => [
|
||||
VisibilityEffect(duration: 1.ms),
|
||||
FadeEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: 0.0,
|
||||
end: 1.0,
|
||||
),
|
||||
MoveEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(0.0, 140.0),
|
||||
end: const Offset(0.0, 0.0),
|
||||
),
|
||||
ScaleEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(0.9, 0.9),
|
||||
end: const Offset(1.0, 1.0),
|
||||
),
|
||||
TiltEffect(
|
||||
curve: Curves.easeInOut,
|
||||
delay: 0.0.ms,
|
||||
duration: 300.0.ms,
|
||||
begin: const Offset(-0.349, 0),
|
||||
end: const Offset(0, 0),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
@ -95,66 +96,56 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||
children: [
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: SafeArea(
|
||||
child: Container(
|
||||
width: 648.0,
|
||||
height: 208.0,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(16.0),
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(14.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text(
|
||||
FFLocalizations.of(context)
|
||||
.getText('dsc9tuc8' /* UMA EXPERIÊCIA COMPLETA */),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context).displaySmall.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
fontSize: 24.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w600,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(14.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text( FFLocalizations.of(context).getText('dsc9tuc8' /* UMA EXPERIÊCIA COMPLETA */),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.displaySmall
|
||||
.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).accent1,
|
||||
fontSize: 24.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w600,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, -1.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'5bgqn16z' /* COM CONFORTO ONDE VOCÊ ESTIVER... */),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context).displaySmall.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 15.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w600,
|
||||
useGoogleFonts: GoogleFonts.asMap()
|
||||
.containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
Align(
|
||||
alignment: const AlignmentDirectional(0.0, -1.0),
|
||||
child: Text(FFLocalizations.of(context).getText('5bgqn16z' /* COM CONFORTO ONDE VOCÊ ESTIVER... */),
|
||||
textAlign: TextAlign.start,
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.displaySmall
|
||||
.override(
|
||||
fontFamily: 'Plus Jakarta Sans',
|
||||
color: FlutterFlowTheme.of(context).primaryText,
|
||||
fontSize: 15.0,
|
||||
letterSpacing: 0.0,
|
||||
fontWeight: FontWeight.w600,
|
||||
useGoogleFonts: GoogleFonts.asMap().containsKey('Plus Jakarta Sans'),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 284.0,
|
||||
height: 200.0,
|
||||
decoration: const BoxDecoration(),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(0.0),
|
||||
child: const AtomImageSvgTheme(filename: 'welcome', width: 600, height: double.infinity),
|
||||
Padding(
|
||||
padding: const EdgeInsets.fromLTRB(0, 25, 0, 0),
|
||||
child: Container(
|
||||
width: 284.0,
|
||||
height: 200.0,
|
||||
decoration: const BoxDecoration(),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(0.0),
|
||||
child: const AtomImageSvgTheme(
|
||||
filename: 'welcome', width: 600, height: double.infinity),
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
|
@ -171,7 +162,7 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
BoxShadow(
|
||||
blurRadius: 0.0,
|
||||
color: Colors.transparent,
|
||||
offset: Offset(0.0,0.0),
|
||||
offset: Offset(0.0, 0.0),
|
||||
)
|
||||
],
|
||||
borderRadius: BorderRadius.circular(12.0),
|
||||
|
@ -187,23 +178,33 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
children: [
|
||||
Builder(
|
||||
builder: (context) {
|
||||
if (MediaQuery.sizeOf(context).width < kBreakpointSmall ? true : false) {
|
||||
if (MediaQuery.sizeOf(context).width <
|
||||
kBreakpointSmall
|
||||
? true
|
||||
: false) {
|
||||
return Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 16.0),
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 0.0, 0.0, 16.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('toggleSignInPage'),
|
||||
key: const ValueKey<String>(
|
||||
'toggleSignInPage'),
|
||||
onPressed: () async {
|
||||
await widget.toggleSignInPage?.call();
|
||||
},
|
||||
text: FFLocalizations.of(context).getText( 'dynet730' /* Entrar */),
|
||||
text: FFLocalizations.of(context)
|
||||
.getText('dynet730' /* Entrar */),
|
||||
options: FFButtonOptions(
|
||||
width: double.infinity,
|
||||
height: 44.0,
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding: const EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
padding: const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
iconPadding:
|
||||
const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
color: FlutterFlowTheme.of(context)
|
||||
.primary,
|
||||
textStyle: FlutterFlowTheme.of(
|
||||
|
@ -297,10 +298,9 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
padding: const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 0.0, 0.0, 16.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('toggleSignInPage'),
|
||||
|
||||
key: const ValueKey<String>(
|
||||
'toggleSignInPage'),
|
||||
onPressed: () async {
|
||||
|
||||
await widget.toggleSignInPage
|
||||
?.call();
|
||||
},
|
||||
|
@ -353,7 +353,8 @@ class _WelcomeTemplateComponentWidgetState extends State<WelcomeTemplateComponen
|
|||
padding: const EdgeInsetsDirectional
|
||||
.fromSTEB(0.0, 0.0, 0.0, 16.0),
|
||||
child: FFButtonWidget(
|
||||
key: const ValueKey<String>('toggleSignUpPage'),
|
||||
key: const ValueKey<String>(
|
||||
'toggleSignUpPage'),
|
||||
onPressed: () async {
|
||||
await widget.toggleSignUpPage
|
||||
?.call();
|
||||
|
|
|
@ -117,7 +117,7 @@ class App extends StatefulWidget {
|
|||
context.findAncestorStateOfType<_AppState>()!;
|
||||
}
|
||||
|
||||
class _AppState extends State<App> with WidgetsBindingObserver {
|
||||
class _AppState extends State<App> with WidgetsBindingObserver {
|
||||
Locale? _locale = FFLocalizations.getStoredLocale();
|
||||
ThemeMode _themeMode = FlutterFlowTheme.themeMode;
|
||||
late AppStateNotifier _appStateNotifier;
|
||||
|
@ -180,6 +180,7 @@ class _AppState extends State<App> with WidgetsBindingObserver {
|
|||
const Breakpoint(start: 1921, end: 2560, name: HD4K),
|
||||
const Breakpoint(start: 2561, end: double.infinity, name: ULTRAWIDE),
|
||||
];
|
||||
|
||||
return ResponsiveBreakpoints.builder(
|
||||
child: BouncingScrollWrapper.builder(context, widget!),
|
||||
breakpoints: breakpoints,
|
||||
|
@ -264,7 +265,8 @@ class _AppState extends State<App> with WidgetsBindingObserver {
|
|||
});
|
||||
}
|
||||
|
||||
@override void initState() {
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
WidgetsBinding.instance.addObserver(this);
|
||||
|
||||
|
@ -280,18 +282,21 @@ class _AppState extends State<App> with WidgetsBindingObserver {
|
|||
WidgetsBinding.instance.addPersistentFrameCallback((_) => initDeepLinks());
|
||||
}
|
||||
|
||||
@override void dispose() {
|
||||
@override
|
||||
void dispose() {
|
||||
WidgetsBinding.instance.removeObserver(this);
|
||||
_linkSubscription?.cancel();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override void didChangeAppLifecycleState(AppLifecycleState state) async {
|
||||
@override
|
||||
void didChangeAppLifecycleState(AppLifecycleState state) async {
|
||||
bool initialize = await StorageUtil().ensureInitialization();
|
||||
if(initialize) await LocalizationService.processLocals(context);
|
||||
if (initialize) await LocalizationService.processLocals(context);
|
||||
}
|
||||
|
||||
@override Widget build(BuildContext context) {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp.router(
|
||||
key: navigatorKey,
|
||||
title: 'FRE ACCESS HUB',
|
||||
|
|
|
@ -0,0 +1,31 @@
|
|||
import 'package:flutter/material.dart';
|
||||
|
||||
class TextUtil extends StatelessWidget {
|
||||
final String text;
|
||||
final TextStyle? style;
|
||||
final TextAlign? textAlign;
|
||||
|
||||
const TextUtil({
|
||||
Key? key,
|
||||
required this.text,
|
||||
this.style,
|
||||
this.textAlign,
|
||||
}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
var textScale = MediaQuery.textScalerOf(context);
|
||||
var scaledTextSize = textScale.scale(style?.fontSize ?? 14);
|
||||
double limitedTextSize = scaledTextSize > (style?.fontSize ?? 14) * 2
|
||||
? (style?.fontSize ?? 14) * 2
|
||||
: scaledTextSize;
|
||||
|
||||
return Text(
|
||||
text,
|
||||
style: style?.copyWith(
|
||||
fontSize: limitedTextSize,
|
||||
),
|
||||
textAlign: textAlign ?? TextAlign.start,
|
||||
);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue