74 lines
2.4 KiB
Dart
74 lines
2.4 KiB
Dart
import 'package:flutter/material.dart';
|
|
|
|
import 'package:mobdr/ui/authentication/signin.dart';
|
|
import 'package:mobdr/config/constant.dart';
|
|
import 'package:mobdr/library/flutter_overboard/overboard.dart';
|
|
import 'package:mobdr/library/flutter_overboard/page_model.dart';
|
|
|
|
class OnBoardingPage extends StatefulWidget {
|
|
@override
|
|
_OnBoardingPageState createState() => _OnBoardingPageState();
|
|
}
|
|
|
|
class _OnBoardingPageState extends State<OnBoardingPage> {
|
|
// create each page of onBoard here
|
|
final _pageList = [
|
|
PageModel(
|
|
color: Colors.white,
|
|
imageFromUrl: GLOBAL_IMAGES_URL + '/onboarding-calendar.png',
|
|
title: 'MP4 Calendar',
|
|
body: 'Plan your monthly visits',
|
|
doAnimateImage: true),
|
|
PageModel(
|
|
color: Colors.white,
|
|
imageFromUrl: GLOBAL_IMAGES_URL + '/onboarding-photos.png',
|
|
title: 'Take Photos',
|
|
body: 'Take all your photos of your visit',
|
|
doAnimateImage: true),
|
|
PageModel(
|
|
color: Colors.white,
|
|
imageFromUrl: GLOBAL_IMAGES_URL + '/onboarding-photo.png',
|
|
title: 'Edit Photo',
|
|
body: 'Position tags, adjust visibility, specify competitor',
|
|
doAnimateImage: true),
|
|
PageModel(
|
|
color: Colors.white,
|
|
imageFromUrl: GLOBAL_IMAGES_URL + '/onboarding-synchro.png',
|
|
title: 'MP4 synchronization',
|
|
body: 'Synchronize your data quickly and easily with MP4 :)',
|
|
doAnimateImage: true),
|
|
PageModel(
|
|
color: Colors.white,
|
|
imageFromUrl: GLOBAL_IMAGES_URL + '/onboarding-visite.png',
|
|
title: 'MP4 Visit',
|
|
body: 'All your photos will appear in your MP4 visit !',
|
|
doAnimateImage: true),
|
|
];
|
|
|
|
@override
|
|
void initState() {
|
|
super.initState();
|
|
}
|
|
|
|
@override
|
|
void dispose() {
|
|
super.dispose();
|
|
}
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
body: OverBoard(
|
|
pages: _pageList,
|
|
showBullets: true,
|
|
finishCallback: () {
|
|
// after you click finish, direct to signin page
|
|
// Adjust with your need using push replacement or push remove until
|
|
//Navigator.of(context).pushAndRemoveUntil(MaterialPageRoute(builder: (context) => SigninPage()), (Route<dynamic> route) => false);
|
|
Navigator.pushReplacement(
|
|
context, MaterialPageRoute(builder: (context) => SigninPage()));
|
|
},
|
|
));
|
|
}
|
|
}
|