2021-03-02 07:05:47 +01:00
import ' package:flutter/services.dart ' ;
import ' package:flutter/material.dart ' ;
2021-03-08 00:32:18 +01:00
import ' package:gecko/globals.dart ' ;
2021-03-02 07:05:47 +01:00
import ' package:gecko/screens/commonElements.dart ' ;
2021-03-08 06:21:04 +01:00
import ' package:gecko/screens/onBoarding/11.dart ' ;
2021-03-02 07:05:47 +01:00
// ignore: must_be_immutable
class OnboardingStepTwelve extends StatelessWidget {
TextEditingController tplController = TextEditingController ( ) ;
2021-03-08 01:08:26 +01:00
final int progress = 9 ;
2021-03-02 07:05:47 +01:00
@ override
Widget build ( BuildContext context ) {
SystemChrome . setPreferredOrientations ( [ DeviceOrientation . portraitUp ] ) ;
CommonElements common = CommonElements ( ) ;
2021-03-08 17:23:56 +01:00
2021-03-02 07:05:47 +01:00
return Scaffold (
extendBodyBehindAppBar: true ,
body: SafeArea (
child: Column ( children: < Widget > [
2021-03-08 17:23:56 +01:00
common . onboardingProgressBar (
context , ' Ma phrase de restauration ' , progress ) ,
2021-03-02 07:05:47 +01:00
common . bubbleSpeak (
2021-04-24 20:27:18 +02:00
" Si un jour vous changez de téléphone, votre code secret sera différent, mais il vous suffira de me redonner votre phrase de restauration pour recréer votre trousseau. " ,
textKey: Key ( ' step10 ' ) ,
) ,
2021-03-02 07:05:47 +01:00
SizedBox ( height: 10 ) ,
Image . asset (
' assets/onBoarding/plusieurs-codes-secrets-un-trousseau.png ' ,
2021-03-08 00:32:18 +01:00
height: 410 * ratio ,
2021-03-02 07:05:47 +01:00
) ,
Expanded (
child: Align (
alignment: Alignment . bottomCenter ,
child: SizedBox (
width: 400 ,
height: 62 ,
child: ElevatedButton (
2021-04-24 20:27:18 +02:00
key: Key ( ' goStep11 ' ) ,
2021-03-02 07:05:47 +01:00
style: ElevatedButton . styleFrom (
elevation: 5 ,
primary: Color ( 0xffD28928 ) ,
onPrimary: Colors . white , // foreground
) ,
onPressed: ( ) {
Navigator . push (
context ,
2021-03-08 17:23:56 +01:00
FaderTransition (
page: OnboardingStepThirteen ( ) , isFast: true ) ,
2021-03-02 07:05:47 +01:00
) ;
} ,
child: Text ( " Générer le code secret " ,
style: TextStyle ( fontSize: 20 ) ) ) ,
) ) ) ,
2021-03-08 00:32:18 +01:00
SizedBox ( height: isTall ? 80 : 40 ) ,
2021-03-02 07:05:47 +01:00
] ) ,
) ) ;
}
}