diff --git a/assets/Corporate.png b/assets/Corporate.png new file mode 100644 index 0000000..73be592 Binary files /dev/null and b/assets/Corporate.png differ diff --git a/assets/Corporate.svg b/assets/Corporate.svg new file mode 100644 index 0000000..9429bd2 --- /dev/null +++ b/assets/Corporate.svg @@ -0,0 +1 @@ +Corporate \ No newline at end of file diff --git a/assets/DKV.png b/assets/DKV.png new file mode 100644 index 0000000..3f6e73d Binary files /dev/null and b/assets/DKV.png differ diff --git a/assets/DKV.svg b/assets/DKV.svg new file mode 100644 index 0000000..b94e6e6 --- /dev/null +++ b/assets/DKV.svg @@ -0,0 +1 @@ +DKV \ No newline at end of file diff --git a/assets/Fashion.png b/assets/Fashion.png new file mode 100644 index 0000000..9bb179c Binary files /dev/null and b/assets/Fashion.png differ diff --git a/assets/Fashion.svg b/assets/Fashion.svg new file mode 100644 index 0000000..fac6455 --- /dev/null +++ b/assets/Fashion.svg @@ -0,0 +1 @@ +Fashion \ No newline at end of file diff --git a/assets/Goverment.png b/assets/Goverment.png new file mode 100644 index 0000000..ad8b084 Binary files /dev/null and b/assets/Goverment.png differ diff --git a/assets/Goverment.svg b/assets/Goverment.svg new file mode 100644 index 0000000..3cc9d7c --- /dev/null +++ b/assets/Goverment.svg @@ -0,0 +1 @@ +Goverment \ No newline at end of file diff --git a/assets/IT.png b/assets/IT.png new file mode 100644 index 0000000..0682e10 Binary files /dev/null and b/assets/IT.png differ diff --git a/assets/IT.svg b/assets/IT.svg new file mode 100644 index 0000000..44698f1 --- /dev/null +++ b/assets/IT.svg @@ -0,0 +1 @@ +IT \ No newline at end of file diff --git a/assets/Startup.png b/assets/Startup.png new file mode 100644 index 0000000..45d8716 Binary files /dev/null and b/assets/Startup.png differ diff --git a/assets/Startup.svg b/assets/Startup.svg new file mode 100644 index 0000000..703c0e2 --- /dev/null +++ b/assets/Startup.svg @@ -0,0 +1 @@ +Startup \ No newline at end of file diff --git a/assets/Transport.png b/assets/Transport.png new file mode 100644 index 0000000..a9b0ddd Binary files /dev/null and b/assets/Transport.png differ diff --git a/assets/Transport.svg b/assets/Transport.svg new file mode 100644 index 0000000..25708ba --- /dev/null +++ b/assets/Transport.svg @@ -0,0 +1 @@ +Transport \ No newline at end of file diff --git a/assets/dog.svg b/assets/dog.svg new file mode 100644 index 0000000..ccb66c6 --- /dev/null +++ b/assets/dog.svg @@ -0,0 +1,202 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assets/dream-cast.svg b/assets/dream-cast.svg new file mode 100644 index 0000000..091b7ce --- /dev/null +++ b/assets/dream-cast.svg @@ -0,0 +1 @@ +podcast 4 \ No newline at end of file diff --git a/assets/driver.svg b/assets/driver.svg new file mode 100644 index 0000000..1b1d8ae --- /dev/null +++ b/assets/driver.svg @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/assets/employer-1.png b/assets/employer-1.png new file mode 100644 index 0000000..cbe028c Binary files /dev/null and b/assets/employer-1.png differ diff --git a/assets/employer-2.png b/assets/employer-2.png new file mode 100644 index 0000000..2e3e9f9 Binary files /dev/null and b/assets/employer-2.png differ diff --git a/assets/employer-3.png b/assets/employer-3.png new file mode 100644 index 0000000..b245bb5 Binary files /dev/null and b/assets/employer-3.png differ diff --git a/assets/f&b.png b/assets/f&b.png new file mode 100644 index 0000000..8356e7f Binary files /dev/null and b/assets/f&b.png differ diff --git a/assets/f&b.svg b/assets/f&b.svg new file mode 100644 index 0000000..e755dcc --- /dev/null +++ b/assets/f&b.svg @@ -0,0 +1 @@ +f&amp;b \ No newline at end of file diff --git a/assets/ketapang.svg b/assets/ketapang.svg new file mode 100644 index 0000000..4b225ec --- /dev/null +++ b/assets/ketapang.svg @@ -0,0 +1 @@ +ketapang \ No newline at end of file diff --git a/assets/logo.png b/assets/logo.png index 119e397..5b9bb9b 100644 Binary files a/assets/logo.png and b/assets/logo.png differ diff --git a/assets/logo.svg b/assets/logo.svg new file mode 100644 index 0000000..ad12219 --- /dev/null +++ b/assets/logo.svg @@ -0,0 +1,124 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +dreamjob +tag tag + diff --git a/assets/logo_vertical.png b/assets/logo_vertical.png index 34fe5be..f8b6369 100644 Binary files a/assets/logo_vertical.png and b/assets/logo_vertical.png differ diff --git a/assets/logo_vertical2.png b/assets/logo_vertical2.png new file mode 100644 index 0000000..7521448 Binary files /dev/null and b/assets/logo_vertical2.png differ diff --git a/assets/market-2.png b/assets/market-2.png new file mode 100644 index 0000000..a268eb9 Binary files /dev/null and b/assets/market-2.png differ diff --git a/assets/market-2.svg b/assets/market-2.svg new file mode 100644 index 0000000..e4babff --- /dev/null +++ b/assets/market-2.svg @@ -0,0 +1 @@ +market-2 \ No newline at end of file diff --git a/assets/market.png b/assets/market.png new file mode 100644 index 0000000..4259dd8 Binary files /dev/null and b/assets/market.png differ diff --git a/assets/market.svg b/assets/market.svg new file mode 100644 index 0000000..2216d1e --- /dev/null +++ b/assets/market.svg @@ -0,0 +1 @@ +market \ No newline at end of file diff --git a/assets/others.png b/assets/others.png new file mode 100644 index 0000000..ae3d9be Binary files /dev/null and b/assets/others.png differ diff --git a/assets/others.svg b/assets/others.svg new file mode 100644 index 0000000..f538fd5 --- /dev/null +++ b/assets/others.svg @@ -0,0 +1 @@ +others \ No newline at end of file diff --git a/assets/otp.png b/assets/otp.png new file mode 100644 index 0000000..9d84ae4 Binary files /dev/null and b/assets/otp.png differ diff --git a/assets/seeker-1.png b/assets/seeker-1.png new file mode 100644 index 0000000..3d6442d Binary files /dev/null and b/assets/seeker-1.png differ diff --git a/assets/seeker-2.png b/assets/seeker-2.png new file mode 100644 index 0000000..9fa4bc3 Binary files /dev/null and b/assets/seeker-2.png differ diff --git a/assets/seeker-3.png b/assets/seeker-3.png new file mode 100644 index 0000000..55d73c5 Binary files /dev/null and b/assets/seeker-3.png differ diff --git a/assets/vector-5.svg b/assets/vector-5.svg new file mode 100644 index 0000000..7a132dc --- /dev/null +++ b/assets/vector-5.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/fonts/Roboto-Regular.ttf b/fonts/Roboto-Regular.ttf new file mode 100644 index 0000000..2b6392f Binary files /dev/null and b/fonts/Roboto-Regular.ttf differ diff --git a/lib/employer_app.dart b/lib/employer_app.dart deleted file mode 100644 index f40b7dc..0000000 --- a/lib/employer_app.dart +++ /dev/null @@ -1,64 +0,0 @@ -// import 'package:flutter/material.dart'; -// import 'package:provider/provider.dart'; -// import 'package:space/app.dart'; -// import 'package:space/main.dart'; -// import 'package:space/navigator_employer.dart'; -// import 'package:space/src/core/models/auth.dart'; - -// import 'package:space/src/core/models/jobs.dart'; -// import 'package:space/src/core/models/save.dart'; -// import 'package:space/src/ui/auth/employer/home_employer.dart'; -// import 'package:space/src/ui/employer/employer_edit_post.dart'; -// import 'package:space/src/ui/employer/employer_tabs.dart'; -// import 'package:space/src/ui/employer/employer_post_a_job.dart'; -// import 'package:space/src/ui/screens/splash_screen.dart'; - -// import 'package:space/src/ui/theme/theme.dart'; - -// void main() => runApp(EmployerApp()); - -// class EmployerApp extends StatelessWidget { -// @override -// Widget build(BuildContext context) { -// final theme = buildTheme(); -// return MultiProvider( -// providers: [ -// ChangeNotifierProvider.value( -// value: Auth(), -// ), -// ChangeNotifierProxyProvider( -// builder: (ctx, auth, previousJobs) =>Jobs( -// auth.token, -// auth.userId, -// previousJobs == null ? [] : previousJobs.posts, -// ), -// ), -// ChangeNotifierProvider.value( -// value: Save(), -// ) -// ], -// child: Consumer( -// builder: (ctx, auth, _) => MaterialApp( -// debugShowCheckedModeBanner: false, -// theme: theme, -// home: auth.isAuth -// ? EmployerNavigator() -// : FutureBuilder( -// future: auth.tryAutoLogin(), -// builder: (ctx, authResultSnapshot) => -// authResultSnapshot.connectionState == -// ConnectionState.waiting -// ? SplashScreen() -// : DreamApp(), -// ), -// routes: { -// HomePageEmployer.routeName: (ctx) => HomePageEmployer(), -// EmployerTabs.routeName: (ctx) => EmployerTabs(), -// PostaJob.routeName: (ctx) => PostaJob(), -// EditPost.routeName: (ctx) => EditPost(), -// }, -// ), -// ), -// ); -// } -// } diff --git a/lib/main.dart b/lib/main.dart index 141d390..84be004 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,14 +1,19 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; +import 'package:space/navigator_employer.dart'; import 'package:space/navigator_seeker.dart'; +import 'package:space/src/app.dart'; import 'package:space/src/core/models/apply.dart'; import 'package:space/src/core/models/auth.dart'; import 'package:space/src/core/models/cart.dart'; import 'package:space/src/core/models/jobs.dart'; +import 'package:space/src/core/models/save.dart'; import 'package:space/src/ui/auth/employer/home_employer.dart'; import 'package:space/src/ui/auth/employer/login_signup_employer.dart'; +import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; import 'package:space/src/ui/auth/seeker/home_seeker.dart'; +import 'package:space/src/ui/auth/seeker/ui_get_started_seeker.dart'; import 'package:space/src/ui/employer/layout/employer_edit_post.dart'; import 'package:space/src/ui/employer/screens/employer_posted_screen.dart'; import 'package:space/src/ui/employer/screens/employer_tabs.dart'; @@ -28,59 +33,44 @@ class DreamJobApp extends StatelessWidget { final theme = buildTheme(); return MultiProvider( providers: [ - ChangeNotifierProvider.value( - value: Auth(), - ), - ChangeNotifierProxyProvider( - builder: (ctx, auth, previousJobs) => Jobs( - auth.token, - auth.userId, - previousJobs == null ? [] : previousJobs.posts, - ), - ), // ChangeNotifierProvider.value( - // value: Save(), - // ) - ChangeNotifierProxyProvider( - builder: (ctx, auth, previousApplys) => Applys( - auth.token, - auth.userId, - previousApplys == null ? [] : previousApplys.applys, - ), + // value: Auth(), + // ), + ChangeNotifierProvider.value( + value: Jobs(), ), ChangeNotifierProvider.value( - value: Cart(), + value: Save(), ), + // ChangeNotifierProxyProvider( + // builder: (ctx, auth, previousApplys) => Applys( + // auth.token, + // auth.userId, + // previousApplys == null ? [] : previousApplys.applys, + // ), + // ), ], - child: Consumer( - builder: (ctx, auth, _) => MaterialApp( + child: MaterialApp( debugShowCheckedModeBanner: false, theme: theme, - home: auth.isAuth - ? SeekerNavigator() - : FutureBuilder( - future: auth.tryAutoLogin(), - builder: (ctx, authResultSnapshot) => - authResultSnapshot.connectionState == - ConnectionState.waiting - ? SplashScreen() - : LoginSignUpEmployer(), - ), + home: DreamApp(), routes: { HomePageEmployer.routeName: (ctx) => HomePageEmployer(), EmployerTabs.routeName: (ctx) => EmployerTabs(), EmployerPostScreen.routeName: (ctx) => EmployerPostScreen(), EditPost.routeName: (ctx) => EditPost(), + EmployerNavigator.routeName: (ctx) => EmployerNavigator(), + UiGetStartedEmployer.routeName: (ctx) => UiGetStartedEmployer(), HomePageSeeker.routeName: (ctx) => HomePageSeeker(), JobDetails.routeName: (ctx) => JobDetails(), // SaveScreen.routeName: (ctx) => SaveScreen(), SeekerTabs.routeName: (ctx) => SeekerTabs(), - CartScreen.routeName: (ctx) => CartScreen(), - ApplysScreen.routeName: (ctx) => ApplysScreen(), + // // ApplysScreen.routeName: (ctx) => ApplysScreen(), + SeekerNavigator.routeName: (ctx) => SeekerNavigator(), + UiGetStartedSeeker.routeName: (ctx) => UiGetStartedSeeker(), }, ), - ), ); } } diff --git a/lib/navigator_employer.dart b/lib/navigator_employer.dart index d284d27..1064f31 100644 --- a/lib/navigator_employer.dart +++ b/lib/navigator_employer.dart @@ -5,9 +5,12 @@ import 'package:material_design_icons_flutter/material_design_icons_flutter.dart import 'package:space/src/ui/auth/employer/home_employer.dart'; import 'package:space/src/ui/chat/inbox_ui_list.dart'; import 'package:space/src/ui/components/landing_404_page.dart'; +import 'package:space/src/ui/components/notification.dart'; +import 'package:space/src/ui/employer/layout/employer_edit_post.dart'; import 'package:space/src/ui/employer/screens/employer_tabs.dart'; class EmployerNavigator extends StatefulWidget { + static const routeName = '/employer-navigator'; @override _EmployerNavigatorState createState() => _EmployerNavigatorState(); } @@ -24,9 +27,9 @@ class _EmployerNavigatorState extends State { final List _children = [ HomePageEmployer(), EmployerTabs(), - LandingErrorPage(), - InboxUiList(), + EditPost(), InboxUiList(), + NotificationUi(), ]; @override Widget build(BuildContext context) { @@ -62,8 +65,8 @@ class _EmployerNavigatorState extends State { fontStyle: FontStyle.normal)), ), BottomNavigationBarItem( - icon: Icon(MdiIcons.accountSearchOutline, size: 24), - title: Text('SEARCH', + icon: Icon(MdiIcons.plusCircleOutline, size: 24), + title: Text('POST JOB', style: TextStyle( fontFamily: 'VarelaRound', fontSize: 8, @@ -90,7 +93,7 @@ class _EmployerNavigatorState extends State { ), ], currentIndex: _selectedIndex, - selectedItemColor: Color(0xff4d4d4d), + selectedItemColor: Colors.amber, onTap: _onItemTapped, ), ); diff --git a/lib/navigator_seeker.dart b/lib/navigator_seeker.dart index 9ddb0d3..07bc592 100644 --- a/lib/navigator_seeker.dart +++ b/lib/navigator_seeker.dart @@ -4,10 +4,13 @@ import 'package:flutter/services.dart'; import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; import 'package:space/src/ui/auth/seeker/home_seeker.dart'; import 'package:space/src/ui/chat/inbox_ui_list.dart'; +import 'package:space/src/ui/components/notification.dart'; import 'package:space/src/ui/seeker/layout/job_search.dart'; import 'package:space/src/ui/seeker/screens/seeker_tabs.dart'; class SeekerNavigator extends StatefulWidget { + static const routeName = '/seeker-navigator'; + @override _SeekerNavigatorState createState() => _SeekerNavigatorState(); } @@ -26,7 +29,7 @@ class _SeekerNavigatorState extends State { SeekerTabs(), JobSearch(), InboxUiList(), - InboxUiList(), + NotificationUi(), ]; @override Widget build(BuildContext context) { diff --git a/lib/src/app.dart b/lib/src/app.dart index 924e15c..056a863 100644 --- a/lib/src/app.dart +++ b/lib/src/app.dart @@ -1,120 +1,119 @@ -// import 'package:flutter/material.dart'; -// import 'package:flutter/services.dart'; -// import 'package:space/employer_app.dart'; -// import 'package:space/seeker_app.dart'; -// import 'package:space/src/ui/auth/employer/login_signup_employer.dart'; -// import 'package:space/src/ui/auth/seeker/login_signup_seeker.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/services.dart'; +import 'package:space/seeker_app.dart'; +import 'package:space/src/ui/auth/employer/login_signup_employer.dart'; +import 'package:space/src/ui/auth/seeker/login_signup_seeker.dart'; -// class DreamApp extends StatelessWidget { -// @override -// Widget build(BuildContext context) { -// SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle( -// statusBarColor: Colors.transparent, -// statusBarBrightness: Brightness.light, -// statusBarIconBrightness: Brightness.light, -// systemNavigationBarIconBrightness: Brightness.light, -// systemNavigationBarColor: Colors.black, -// )); -// return Material( -// child: Container( -// decoration: BoxDecoration( -// image: DecorationImage( -// fit: BoxFit.cover, -// image: AssetImage('assets/vector-5.png', ), -// ), -// ), -// child: Stack(children: [ -// Padding( -// padding: EdgeInsets.only(top: 50, right: 30), -// child: Stack( -// alignment: Alignment.topRight, -// children: [ -// Align( -// alignment: Alignment.topRight, -// child: Image.asset('assets/vector-11.png', scale: 1.4,)), -// Align( -// alignment: Alignment(0.6, -0.8), -// child: Image.asset('assets/vector-12.png', scale: 1.5,)), -// Align( -// alignment: Alignment(0.7, -0.5), -// child: Image.asset('assets/vector-13.png', scale: 1.5,)), -// Align( -// alignment: Alignment(0.2, -0.4), -// child: Image.asset('assets/vector-14.png', scale: 1.5,)), -// ], -// ), -// ), -// Stack( -// children:[ -// Align( -// alignment: Alignment(-0.8, 0.2), -// child: Image.asset('assets/vector-16.png', scale: 1.5,)), -// Align( -// alignment: Alignment(-0.4, -0), -// child: Image.asset('assets/vector-15.png', scale: 1.5,)), -// ], -// ), -// Padding( -// padding: EdgeInsets.only(bottom: 20), -// child: Align( -// alignment: Alignment.bottomCenter, -// child: Column( -// mainAxisAlignment: MainAxisAlignment.end, -// children: [ -// MaterialButton( -// shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), -// color: Color(0xff22c0e8), -// minWidth: 220, -// onPressed: () { -// Navigator.push( -// context, -// MaterialPageRoute(builder: (context) => LoginSignUpSeeker()), -// ); -// }, -// child: -// Text("Look for Jobs", -// textAlign: TextAlign.center, -// style: TextStyle( -// color: Colors.white, fontSize: 13)), -// ), -// MaterialButton( -// shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), -// color: Color(0xff57b22f), -// minWidth: 220, -// onPressed: () { -// Navigator.push( -// context, -// MaterialPageRoute(builder: (context) => LoginSignUpEmployer()) -// ); -// }, -// child: -// Text("Look for Employees", -// textAlign: TextAlign.center, -// style: TextStyle( -// color: Colors.white, fontSize: 13)), -// ), -// SizedBox(height: 20), -// Column( -// children: [ -// Text("Copyright © 2019 by Dreamjob", -// textAlign: TextAlign.center, -// style: TextStyle( -// color: Colors.white, fontSize: 10) -// ), -// Text("www.dreamjob.co.id", -// textAlign: TextAlign.center, -// style: TextStyle( -// color: Colors.cyan[400], fontSize: 10)), -// ], -// ), -// ], -// ), -// ), -// ), -// ], -// ), -// ), -// ); -// } -// } +class DreamApp extends StatelessWidget { + @override + Widget build(BuildContext context) { + SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle( + statusBarColor: Colors.transparent, + statusBarBrightness: Brightness.light, + statusBarIconBrightness: Brightness.light, + systemNavigationBarIconBrightness: Brightness.light, + systemNavigationBarColor: Colors.black, + )); + return Material( + child: Container( + decoration: BoxDecoration( + image: DecorationImage( + fit: BoxFit.cover, + image: AssetImage('assets/vector-5.png', ), + ), + ), + child: Stack(children: [ + Padding( + padding: EdgeInsets.only(top: 50, right: 30), + child: Stack( + alignment: Alignment.topRight, + children: [ + Align( + alignment: Alignment.topRight, + child: Image.asset('assets/vector-11.png', scale: 1.4,)), + Align( + alignment: Alignment(0.6, -0.8), + child: Image.asset('assets/vector-12.png', scale: 1.5,)), + Align( + alignment: Alignment(0.7, -0.5), + child: Image.asset('assets/vector-13.png', scale: 1.5,)), + Align( + alignment: Alignment(0.2, -0.4), + child: Image.asset('assets/vector-14.png', scale: 1.5,)), + ], + ), + ), + Stack( + children:[ + Align( + alignment: Alignment(-0.8, 0.2), + child: Image.asset('assets/vector-16.png', scale: 1.5,)), + Align( + alignment: Alignment(-0.4, -0), + child: Image.asset('assets/vector-15.png', scale: 1.5,)), + ], + ), + Padding( + padding: EdgeInsets.only(bottom: 20), + child: Align( + alignment: Alignment.bottomCenter, + child: Column( + mainAxisAlignment: MainAxisAlignment.end, + children: [ + MaterialButton( + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), + color: Color(0xff22c0e8), + minWidth: 220, + onPressed: () { + Navigator.push( + context, + MaterialPageRoute(builder: (context) => LoginSignUpSeeker()), + ); + }, + child: + Text("Look for Jobs", + textAlign: TextAlign.center, + style: TextStyle( + color: Colors.white, fontSize: 13)), + ), + MaterialButton( + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), + color: Color(0xff57b22f), + minWidth: 220, + onPressed: () { + Navigator.push( + context, + MaterialPageRoute(builder: (context) => LoginSignUpEmployer()) + ); + }, + child: + Text("Look for Employees", + textAlign: TextAlign.center, + style: TextStyle( + color: Colors.white, fontSize: 13)), + ), + SizedBox(height: 20), + Column( + children: [ + Text("Copyright © 2019 by Dreamjob", + textAlign: TextAlign.center, + style: TextStyle( + color: Colors.white, fontSize: 10) + ), + Text("www.dreamjob.co.id", + textAlign: TextAlign.center, + style: TextStyle( + color: Colors.cyan[400], fontSize: 10)), + ], + ), + ], + ), + ), + ), + ], + ), + ), + ); + } +} \ No newline at end of file diff --git a/lib/src/core/models/apply.dart b/lib/src/core/models/apply.dart index e0ed2ff..d2a5c79 100644 --- a/lib/src/core/models/apply.dart +++ b/lib/src/core/models/apply.dart @@ -6,12 +6,12 @@ import 'package:space/src/core/models/job.dart'; import './cart.dart'; -class ApplyItem { +class ApplyPost { final String id; final List job; final DateTime dateTime; - ApplyItem({ + ApplyPost({ @required this.id, @required this.job, @required this.dateTime, @@ -19,27 +19,27 @@ class ApplyItem { } class Applys with ChangeNotifier { - List _applys = []; + List _applys = []; final String authToken; final String userId; Applys(this.authToken, this.userId, this._applys); - List get applys { + List get applys { return [..._applys]; } Future fetchAndSetApplys() async { final url = 'https://dreamjob-id.firebaseio.com/applys/$userId.json?auth=$authToken'; final response = await http.get(url); - final List loadedApplys = []; + final List loadedApplys = []; final extractedData = json.decode(response.body) as Map; if (extractedData == null) { return; } extractedData.forEach((applyId, applyData) { loadedApplys.add( - ApplyItem( + ApplyPost( id: applyId, dateTime: DateTime.parse(applyData['dateTime']), job: (applyData['job'] as List) @@ -86,7 +86,7 @@ class Applys with ChangeNotifier { ); _applys.insert( 0, - ApplyItem( + ApplyPost( id: json.decode(response.body)['name'], dateTime: timestamp, job: addJobs, diff --git a/lib/src/core/models/job.dart b/lib/src/core/models/job.dart index e40fe2e..a449fb9 100644 --- a/lib/src/core/models/job.dart +++ b/lib/src/core/models/job.dart @@ -1,7 +1,4 @@ -import 'dart:convert'; - import 'package:flutter/foundation.dart'; -import 'package:http/http.dart' as http; class Job with ChangeNotifier { final String id; @@ -40,29 +37,8 @@ class Job with ChangeNotifier { this.isSave = false, }); - void _setSaveValue(bool newValue) { - isSave = newValue; - notifyListeners(); - } - - Future toggleSavePosts(String token, String userId) async { - final oldStatus = isSave; + void toggleSavePosts() { isSave = !isSave; notifyListeners(); - final url = - 'https://dreamjob-id.firebaseio.com/userSaves/$userId/$id.json?auth=$token'; - try { - final response = await http.put( - url, - body: json.encode( - isSave, - ), - ); - if (response.statusCode >= 400) { - _setSaveValue(oldStatus); - } - } catch (error) { - _setSaveValue(oldStatus); - } } } \ No newline at end of file diff --git a/lib/src/core/models/jobs.dart b/lib/src/core/models/jobs.dart index eb648a3..257250a 100644 --- a/lib/src/core/models/jobs.dart +++ b/lib/src/core/models/jobs.dart @@ -1,25 +1,132 @@ -import 'dart:convert'; - import 'package:flutter/material.dart'; -import 'package:http/http.dart' as http; -import 'package:space/src/core/models/http_exception.dart'; - -import 'package:space/src/core/models/job.dart'; -// const String PARSE_APP_ID = '7lbdiypJa4ZfYMky5E7NxAGFWmnfP0CtTzk6mhRj'; -// const String PARSE_APP_URL = 'https://parseapi.back4app.com/classes/job'; -// const String CLIENT_KEY = 'UH2KRTDVttLRdEB5heG70tyAdB7pcjkHgtapP4mu'; -// const String LIVE_QUERY_URL = 'wss://dreamjob.back4app.io'; +import './job.dart'; class Jobs with ChangeNotifier { - List _posts = []; - -final String authToken; -final String userId; + List _posts = [ + Job( + id: 'p1', + title: 'Head Chef', + employerName: 'Mekuru Ramen', + description: 'Our teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and BeveragesOur teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and BeveragesOur teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and BeveragesOur teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and BeveragesOur teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and BeveragesOur teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and Beverages', + salary: 2500000, + type: 'Full Time', + gender: 'Male', + typeSalary: 'Per Month', + location: 'Pontianak, Kalimantan Barat', + industry: 'Food and Beverages', + education: 'High School', + workingday: 'Tuesday - Sunday', + workinghour: '08.00 - 21.30', + imageUrl: + 'https://i.ibb.co/9NyNjxM/mekuru-2.png', + skill: 'required: ' + '• 1+ years experience in F&B company' + '• work with passion and team oriented' + '• Kitchen oriented.' + '• can work comfortably alongside both jobuction and serving teams' + '• a strong written and verbal communicator' + '• attention to food serving perfection', + ), + Job( + id: 'p2', + title: 'Assistant Chef', + employerName: 'Mekuru Ramen', + description: 'Our teams are up to date with the latest foods, media trends and are keen to prove themselves in this industry and that’s what you want from a food and beverages industry. Industry: Food and Beverages', + salary: 2500000, + type: 'Part Time', + gender: 'Female', + typeSalary: 'Per Month', + location: 'Pontianak, Kalimantan Barat', + industry: 'Food and Beverages', + education: 'High School', + workingday: 'Tuesday - Sunday', + workinghour: '08.00 - 21.30', + imageUrl: + 'https://i.ibb.co/9NyNjxM/mekuru-2.png', + skill: 'required: ' + '• 1+ years experience in F&B company' + '• work with passion and team oriented' + '• Kitchen oriented.' + '• can work comfortably alongside both jobuction and serving teams' + '• a strong written and verbal communicator' + '• attention to food serving perfection', + ), + Job( + id: 'p3', + title: 'Cleaning Service', + employerName: 'Up2u', + description: 'Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industrys standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.', salary: 2500000, + type: 'Weekend', + gender: 'Male / Female', + typeSalary: 'Per Day', + location: 'Banjarmasin, Kalimantan Barat', + industry: 'Food and Beverages', + education: 'High School', + workingday: 'Sunday', + workinghour: '10.00 - 22.00', + imageUrl: + 'https://i.ibb.co/1GcZb6v/up2u.png', + skill: 'required: ' + '• -' + '• -' + '• -' + '• -' + '• -' + '• -', + ), + Job( + id: 'p4', + title: 'CCTV Installer', + employerName: 'CV. CCTV Installer', + description: 'Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry"s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.', + salary: 1800000, + type: 'Freelance', + gender: 'Male / Female', + typeSalary: 'Per Week', + location: 'Singkawang, Kalimantan Barat', + industry: 'Technology', + education: 'High School', + workingday: 'Saturday - Sunday', + workinghour: '06.00 - 04.00', + imageUrl: + 'https://cdn.pixabay.com/photo/2017/12/27/10/14/image-3042333_960_720.png', + skill: 'required: ' + '• -' + '• -' + '• -' + '• -' + '• -' + '• -', + ), + Job( + id: 'p5', + title: 'Mobile App Beckend', + employerName: 'PT. Mobile Apps', + description: 'Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry"s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.', + salary: 10000000, + type: 'Full Time', + gender: 'Male', + typeSalary: 'Per Month', + location: 'Jakarta, Jawa Timur', + industry: 'Human Resource', + education: 'S1', + workingday: 'Everyday', + workinghour: '07.00 - 17.00', + imageUrl: + 'https://img.freepik.com/free-vector/professional-programmer-engineer-writing-code_3446-693.jpg?size=338&ext=jpg', + skill: 'required: ' + '• -' + '• -' + '• -' + '• -' + '• -' + '• -', + ), + ]; + // var _showFavoritesOnly = false; -Jobs(this.authToken, this.userId, this._posts); - - List get posts { + List get posts { return [..._posts]; } @@ -30,137 +137,19 @@ Jobs(this.authToken, this.userId, this._posts); Job findById(String id) { return _posts.firstWhere((job) => job.id == id); } - - Future fetchAndSetJobs([bool filterByUser = false]) async { - final filterString = filterByUser ? 'orderBy"creatorId"&equalTo="$userId"' : ''; - var url = - 'https://dreamjob-id.firebaseio.com/jobs.json?auth=$authToken&$filterString'; - try { - final response = await http.get(url); - final extractedData = json.decode(response.body) as Map; - if (extractedData == null) { - return; - } - url = - 'https://dreamjob-id.firebaseio.com/userSaves/$userId.json?auth=$authToken'; - final saveResponse = await http.get(url); - final saveData = json.decode(saveResponse.body); - final List loadedJobs = []; - extractedData.forEach((jobId, jobData) { - loadedJobs.add(Job( - id: jobId, - title: jobData['title'], - industry: jobData['industry'], - workingday: jobData['workingday'], - workinghour: jobData['workinghour'], - gender: jobData['gender'], - typeSalary: jobData['typeSalary'], - type: jobData['type'], - location: jobData['location'], - education: jobData['education'], - skill: jobData['skill'], - description: jobData['description'], - salary: jobData['salary'], - imageUrl: jobData['imageUrl'], - isSave: - saveData == null ? false : saveData[jobId] ?? false, - )); - }); - _posts = loadedJobs; - notifyListeners(); - } catch (error) { - print(error); - throw error; - } - } - Future addJob(Job job) async { - final url = 'https://dreamjob-id.firebaseio.com/jobs.json?auth=$authToken'; - try { - final response = await http.post( - url, - body: json.encode({ - 'title': job.title, - 'gender': job.gender, - 'industry': job.industry, - 'workingday': job.workingday, - 'workinghour': job.workinghour, - 'type': job.type, - 'location': job.location, - 'education': job.education, - 'skill': job.skill, - 'description': job.description, - 'salary': job.salary, - // 'imageUrl': job.imageUrl, - 'creatorId' : userId, - }), - ); - final newJob = Job( - title: job.title, - typeSalary: job.typeSalary, - gender: job.gender, - industry: job.industry, - workingday: job.workingday, - workinghour: job.workinghour, - type: job.type, - location: job.location, - education: job.education, - skill: job.skill, - description: job.description, - salary: job.salary, - // imageUrl: job.imageUrl, - id: json.decode(response.body)['name'], - ); - _posts.add(newJob); - _posts.insert(0, newJob); - notifyListeners(); - } catch (error) { - print(error); - throw error; - } -} + // void showFavoritesOnly() { + // _showFavoritesOnly = true; + // notifyListeners(); + // } - Future updateJob(String id, Job newJob) async { - final jobIndex = _posts.indexWhere((job) => job.id == id); - if (jobIndex >= 0) { - final url = - 'https://dreamjob-id.firebaseio.com/jobs/$id.json?auth=$authToken'; - await http.patch(url, - body: json.encode({ - 'title': newJob.title, - 'typeSalary': newJob.typeSalary, - 'gender': newJob.gender, - 'industry': newJob.industry, - 'workingday': newJob.workingday, - 'workinghour': newJob.workinghour, - 'type': newJob.type, - 'location': newJob.location, - 'education': newJob.education, - 'skill': newJob.skill, - 'description': newJob.description, - 'salary': newJob.salary, - // 'imageUrl': newJob.imageUrl, - })); - _posts[jobIndex] = newJob; - notifyListeners(); - } else { - print('...'); - } - } + // void showAll() { + // _showFavoritesOnly = false; + // notifyListeners(); + // } - Future deleteJob(String id) async { - final url = - 'https://dreamjob-id.firebaseio.com/jobs/$id.json?auth=$authToken'; - final existingJobIndex = _posts.indexWhere((job) => job.id == id); - var existingJob = _posts[existingJobIndex]; - _posts.removeAt(existingJobIndex); + void addJob() { + // _posts.add(value); notifyListeners(); - final response = await http.delete(url); - if (response.statusCode >= 400) { - _posts.insert(existingJobIndex, existingJob); - notifyListeners(); - throw HttpException('Could not delete post.'); - } - existingJob = null; } -} \ No newline at end of file +} diff --git a/lib/src/ui/auth/employer/home_employer.dart b/lib/src/ui/auth/employer/home_employer.dart index f8d023c..477b7ce 100644 --- a/lib/src/ui/auth/employer/home_employer.dart +++ b/lib/src/ui/auth/employer/home_employer.dart @@ -1,6 +1,11 @@ import 'package:carousel_slider/carousel_slider.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:gradient_app_bar/gradient_app_bar.dart'; +import 'package:carousel_pro/carousel_pro.dart'; +import 'package:space/src/ui/components/category_job_screen.dart'; import 'package:space/src/ui/employer/widgets/employer_app_drawer.dart'; import 'package:space/src/ui/components/horizontal_screen.dart'; @@ -21,14 +26,6 @@ class _HomePageEmployerState extends State { fontFamily: 'TitilliumWeb', fontSize: 20.0, color: Color(0xff3b3b3b)); int _current = 0; - final List imgList = [ - Image.asset('assets/home.png', fit: BoxFit.contain), - Image.asset('assets/vector-3.png', fit: BoxFit.contain), - Image.asset('assets/job.png', fit: BoxFit.contain), - Image.asset('assets/job2.png', fit: BoxFit.contain), - Image.asset('assets/blog.png', fit: BoxFit.contain), - ]; - List map(List list, Function handler) { List result = []; for (var i = 0; i < list.length; i++) { @@ -40,754 +37,660 @@ class _HomePageEmployerState extends State { @override Widget build(BuildContext context) { - return Scaffold( - drawer: EmployerDrawer(), - backgroundColor: Colors.grey[200], - appBar: AppBar( - automaticallyImplyLeading: false, - elevation: 0.0, - backgroundColor: Colors.grey[200], - leading: Builder( - builder: (context) => IconButton( - icon: Icon(Icons.menu), - onPressed: () => Scaffold.of(context).openDrawer(), + return Stack( + children: [ + Container( + height: 94, + width: MediaQuery.of(context).size.width, + child: SvgPicture.asset( + 'assets/vector-5.svg', + fit: BoxFit.fitWidth, ), ), - title: TextFormField( - textInputAction: TextInputAction.search, - style: style.copyWith( - fontSize: 16, - color: Color(0xffc9c8c8), - decoration: TextDecoration.none, + Scaffold( + drawer: EmployerDrawer(), + backgroundColor: Colors.transparent, + appBar: PreferredSize( + preferredSize: Size.fromHeight(70), // here the desired height + child: AppBar( + backgroundColor: Colors.transparent, + automaticallyImplyLeading: false, + leading: Builder( + builder: (context) => IconButton( + icon: Icon(Icons.menu, color: Colors.white), + onPressed: () => Scaffold.of(context).openDrawer(), + ), + ), + title: TextFormField( + textInputAction: TextInputAction.search, + style: style.copyWith( + fontSize: 16, + color: Color(0xffc9c8c8), + decoration: TextDecoration.none, + ), + decoration: InputDecoration( + focusedBorder: InputBorder.none, + contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), + prefixIcon: IconButton( + onPressed: () {}, + icon: Icon( + FeatherIcons.search, + size: 18, + ), + color: Color(0xffc9c8c8)), + fillColor: Colors.white, + filled: true, + hintText: 'Try "Barista"', + hintStyle: + style.copyWith(color: Color(0xffc9c8c8), fontSize: 16), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xffc5cfda)), + )), + ), + ), ), - decoration: InputDecoration( - focusedBorder: InputBorder.none, - contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), - prefixIcon: IconButton( - onPressed: () {}, - icon: Icon( - FeatherIcons.search, - size: 18, - ), - color: Color(0xffc9c8c8)), - fillColor: Colors.white, - filled: true, - hintText: 'Try "Barista"', - hintStyle: style.copyWith(color: Color(0xffc9c8c8), fontSize: 16), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xffc5cfda)), - )), - ), - ), - body: ListView( - children: [ - Container( - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Column(children: [ - CarouselSlider( - items: imgList, - autoPlay: true, - enlargeCenterPage: true, - aspectRatio: 2.0, - onPageChanged: (index) { - setState(() { - _current = index; - }); - }, - ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 35), - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Row( - mainAxisAlignment: MainAxisAlignment.start, - children: map( - imgList, - (index, url) { - return Container( - width: 8.0, - height: 8.0, - margin: EdgeInsets.symmetric(horizontal: 2.0), - decoration: BoxDecoration( - shape: BoxShape.circle, - color: _current == index - ? Color.fromRGBO(0, 0, 0, 0.9) - : Color.fromRGBO(0, 0, 0, 0.4)), - ); - }, + body: ListView( + children: [ + Container( + child: Column( + children: [ + Container( + height: 110, + child: Carousel( + autoplay: true, + animationCurve: Curves.fastOutSlowIn, + animationDuration: Duration(milliseconds: 2000), + dotSize: 4.0, + dotSpacing: 15, + dotIncreasedColor: Colors.amber, + dotBgColor: Colors.transparent, + dotPosition: DotPosition.bottomLeft, + dotVerticalPadding: 5.0, + showIndicator: true, + dotHorizontalPadding: 10.0, + indicatorBgPadding: 0, + images: [ + Padding( + padding: + EdgeInsets.symmetric(horizontal: 10, vertical: 10), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/dream-cast.svg', + fit: BoxFit.fill, + ), + ), ), - ), - Text('See All', - style: style2.copyWith( - fontSize: 10, - color: Color(0xffc9c8c8), - letterSpacing: 1)), - ], + Padding( + padding: EdgeInsets.symmetric(horizontal: 10, vertical: 10), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/dream-cast.svg', + fit: BoxFit.fill, + ), + ), + ), + Padding( + padding: EdgeInsets.symmetric(horizontal: 10, vertical: 10), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/dream-cast.svg', + fit: BoxFit.fill, + ), + ), + ), + ], + ), ), - ), - ]), - SizedBox(height: 10), - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('Recent Job', - style: style2.copyWith( - fontSize: 16, - fontWeight: FontWeight.bold, - letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith( - fontSize: 10, - color: Color(0xffc9c8c8), - letterSpacing: 1))), - onTap: () {}, - )), - SizedBox(height: 180, child: HorizontalScreen()), - Container( - height: 50, - child: ListTile( - leading: Text('Recomended Job', - style: style2.copyWith( - fontSize: 16, - fontWeight: FontWeight.bold, - letterSpacing: 1)), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith( - fontSize: 10, - color: Color(0xffc9c8c8), - letterSpacing: 1))), - onTap: () {}, - )), - SizedBox( - height: 180, - child: RecommendedScreen(), - ), - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('Feed your Dreams', - style: style2.copyWith( - fontSize: 16, - fontWeight: FontWeight.bold, - letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith( - fontSize: 10, - color: Color(0xffc9c8c8), - letterSpacing: 1))), - onTap: () {}, - )), - Container( - padding: EdgeInsets.symmetric(horizontal: 16), - child: Column( - children: [ - Text( - 'Success story from people around you, encourage, giving nutritions to your dreams.', - style: style.copyWith(fontSize: 13)), - ], - ), - ), - Container( - margin: EdgeInsets.only(top: 10, left: 16, right: 16), - padding: EdgeInsets.only(bottom: 10), - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.only( - bottomLeft: Radius.circular(5), - bottomRight: Radius.circular(5))), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - SizedBox( - width: MediaQuery.of(context).size.width, - height: 200, - child: Image.asset('assets/blog.png', - fit: BoxFit.cover)), - Padding( - padding: EdgeInsets.all(10), - child: Text("How to success and winning competition", - style: style.copyWith( - color: Color(0xff3b3b3b), - fontSize: 16, - fontWeight: FontWeight.bold, - letterSpacing: 0.5, - ))), - Padding( - padding: EdgeInsets.all(10), - child: Text( - 'Success story from people around you, encourage, giving nutritions to your dreams. Lorem ipsum dollor', - style: style.copyWith( - color: Color(0xff3b3b3b), fontSize: 12))), - ], - ), - ), - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('People around you', + SizedBox(height: 70, child: CategoryScreen()), + Container( + height: 45, + child: ListTile( + leading: Container( + child: Text('Recommended Job', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + SizedBox(height: 150, child: RecommendedScreen()), + Container( + height: 50, + child: ListTile( + leading: Text('Recent Job', style: style2.copyWith( fontSize: 16, fontWeight: FontWeight.bold, - letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith( - fontSize: 10, - color: Color(0xffc9c8c8), - letterSpacing: 1))), - onTap: () {}, - )), - Material( - child: Container( - height: 120, - child: SingleChildScrollView( - scrollDirection: Axis.horizontal, - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, + letterSpacing: 1)), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + SizedBox( + height: 180, + child: RecentScreen(), + ), + Container( + margin: EdgeInsets.only(top: 10), + height: 45, + child: ListTile( + leading: Container( + child: Text('Feed your Dreams', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + Card( + margin: + EdgeInsets.symmetric(horizontal: 15, vertical: 10), + elevation: 3, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10)), + child: Container( + padding: EdgeInsets.only(bottom: 10), + decoration: BoxDecoration(color: Colors.white), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, children: [ + ClipRRect( + borderRadius: BorderRadius.only( + topLeft: Radius.circular(10), + topRight: Radius.circular(10)), + child: Image.asset('assets/blog.png', + fit: BoxFit.fitWidth)), + Padding( + padding: EdgeInsets.all(10), + child: Text( + "How to success and winning competition", + style: style.copyWith( + color: Color(0xff3b3b3b), + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 0.5, + ))), Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + padding: EdgeInsets.all(10), + child: Text( + 'Success story from people around you, encourage, giving nutritions to your dreams. Lorem ipsum dollor', + style: style.copyWith( + color: Color(0xff3b3b3b), + fontSize: 12))), + ], + ), + ), + ), + Container( + margin: EdgeInsets.only(top: 10), + height: 45, + child: ListTile( + leading: Container( + child: Text('People around you', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + Material( + child: Container( + height: 120, + child: SingleChildScrollView( + scrollDirection: Axis.horizontal, + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceAround, + children: [ + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Uray Bawadi', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_2.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Yudi Salim', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_3.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Aprianto', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_4.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Gamabunta', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Uray Bawadi', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_2.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Yudi Salim', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_3.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Aprianto', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_4.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Gamabunta', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Uray Bawadi', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_2.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Yudi Salim', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_3.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Aprianto', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { - Navigator.push( - context, - new MaterialPageRoute( - builder: (context) => - new SeekerProfileView())); - }, - child: CircleAvatar( - backgroundColor: - Color(0xff48576a), - radius: 30.0, - child: Image.asset( - 'assets/img_profil_4.png', - scale: 1.3))), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, - color: Colors.white, - size: 16, - ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), ), ], ), - Text( - 'Gamabunta', - style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - ]), + ), + ]), + ), + ), ), - ), + SizedBox(height: 30) + ], ), - SizedBox(height: 30) - ], - ), + ), + ], ), - ], - ), + ), + ], ); } } diff --git a/lib/src/ui/auth/employer/intro_employer.dart b/lib/src/ui/auth/employer/intro_employer.dart new file mode 100644 index 0000000..6293c3d --- /dev/null +++ b/lib/src/ui/auth/employer/intro_employer.dart @@ -0,0 +1,92 @@ +import 'package:flutter/material.dart'; +import 'package:intro_views_flutter/Models/page_view_model.dart'; +import 'package:intro_views_flutter/intro_views_flutter.dart'; +import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; + + +class IntroImployer extends StatelessWidget { + final pages = [ + PageViewModel( + pageColor: const Color(0xffff6d00), + iconImageAssetPath: 'assets/employer-2.png', + + bubble: Image.asset('assets/employer-2.png'), + body: Text( + 'Check profile information easier.', + ), + title: Text( + 'Choose Applicants with simple click!', textAlign: TextAlign.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + mainImage: Image.asset( + 'assets/employer-2.png', + height: 450.0, + width: 450.0, + alignment: Alignment.center, + )), + PageViewModel( + pageColor: const Color(0xffd50000), + iconImageAssetPath: 'assets/employer-1.png', + bubble: Image.asset('assets/employer-1.png'), + body: Text( + 'Faster and Effectives to hired.', + ), + title: Text( + 'New and Easier Way!', textAlign: TextAlign.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + mainImage: Image.asset( + 'assets/employer-1.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + )), + PageViewModel( + pageColor: const Color(0xff64dd17), + bubble: Image.asset('assets/employer-3.png'), + iconImageAssetPath: 'assets/employer-3.png', + body: Text('Contact your candidate directly with chat and live interview features.', + textAlign: TextAlign.center), + title: Text('Get in touch directly!', + textAlign: TextAlign.center), + mainImage: Image.asset( + 'assets/employer-3.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + ), + ]; + + @override + Widget build(BuildContext context) { + return Scaffold( + body: Builder( + builder: (context) => IntroViewsFlutter( + pages, + showNextButton: true, + showBackButton: true, + showSkipButton: true, + doneText: Text('DONE'), + onTapDoneButton: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => UiGetStartedEmployer(), + ), //MaterialPageRoute + ); + }, + pageButtonTextStyles: TextStyle( + color: Colors.white, + fontSize: 16.0, + ), + pageButtonTextSize: 5, + ), //IntroViewsFlutter + ), //Builder + ); //Material App + } +} diff --git a/lib/src/ui/auth/employer/login_employer.dart b/lib/src/ui/auth/employer/login_employer.dart deleted file mode 100644 index bc1b4df..0000000 --- a/lib/src/ui/auth/employer/login_employer.dart +++ /dev/null @@ -1,202 +0,0 @@ -import 'package:flutter/material.dart'; - -import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; - - -class LoginEmployer extends StatefulWidget { - - static const routeName = 'signup_or_login'; - - @override - _LoginEmployerState createState() => _LoginEmployerState(); -} - -class _LoginEmployerState extends State { - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); - - @override - Widget build(BuildContext context) { - final textBody = - Column(children: [ - Column( - children: [ - Text('LOGIN TO YOUR ACCOUNT', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Color(0xff2c4057), fontSize: 12) - ), - ], - ), - Row(children: [ - Expanded( - child: new Container( - margin: const EdgeInsets.symmetric(horizontal: 70), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ) - ] - ); - - - final emailField = new TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: 'Username', - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Email can\'t be empty' : null - ); - - final passwordField = TextFormField( - obscureText: true, - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: 'Password', - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Password can\'t be empty' : null - ); - - final loginButton = Material( - elevation: 3.0, - borderRadius: BorderRadius.circular(30.0), - color: Color(0xff57b22f), - child: MaterialButton( - padding: EdgeInsets.fromLTRB(60.0, 15.0, 20.0, 15.0), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => UiGetStartedEmployer())); - }, - child: Row( - children: [ - Text('Login Now', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.white, fontSize: 14)), - const Expanded( - child: Icon(Icons.arrow_forward, color: Colors.white, size: 18,)), - ], - ), - ), - ); - - final linkForgot = Container( - child: Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - MaterialButton( - padding: EdgeInsets.fromLTRB(5.0, 5.0, 5.0, 5.0), - onPressed: (){}, - child: Text('FORGOT PASSWORD?', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Colors.cyan[400], fontSize: 9))), - Text('|', style: style.copyWith(fontSize: 8, color: Colors.blueGrey)), - MaterialButton( - padding: EdgeInsets.fromLTRB(5.0, 5.0, 0.0, 5.0), - onPressed: () {Navigator.pushNamed(context, 'space/register_account');}, - child: Text('REGISTER AN ACCOUNT', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Colors.blueGrey, fontSize: 9))), - ], - ), - ); - - return LayoutBuilder( - builder: (BuildContext context, BoxConstraints viewportConstraints) { - return Scaffold( - body: SingleChildScrollView( - child: ConstrainedBox( - constraints: BoxConstraints( - minHeight: viewportConstraints.maxHeight, - ), - child: Container( - padding: EdgeInsets.only(left: 60, right: 60), - child: Column( - mainAxisAlignment: MainAxisAlignment.end, - mainAxisSize: MainAxisSize.min, - children: [ - textBody, - SizedBox( - height: 10.0, - ), - SizedBox(height: 50.0), - emailField, - SizedBox(height: 20.0), - passwordField, - SizedBox( - height: 30.0, - ), - loginButton, - SizedBox( - height: 5.0, - ), - linkForgot, - SizedBox( - height: 80.0, - ), - - Column ( - children: [ - Text('Copyright © 2019 by Dreamjob', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.blueGrey, fontSize: 10) - ), - Text('www.dreamjob.com', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.cyan[400], fontSize: 10)), - ], - ), - SizedBox( - height: 5 - ), - ], - ),), - ), - ), - ); - } - -); - } - } - diff --git a/lib/src/ui/auth/employer/login_signup_employer.dart b/lib/src/ui/auth/employer/login_signup_employer.dart index bcc00fd..517ad17 100644 --- a/lib/src/ui/auth/employer/login_signup_employer.dart +++ b/lib/src/ui/auth/employer/login_signup_employer.dart @@ -1,9 +1,14 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; import 'package:provider/provider.dart'; import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:space/navigator_employer.dart'; import 'package:space/src/core/models/http_exception.dart'; import 'package:space/src/core/models/auth.dart'; +import 'package:space/src/ui/auth/employer/intro_employer.dart'; +import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; +import 'package:space/src/ui/components/otp_employer.dart'; enum AuthMode { Signup, Login } @@ -12,32 +17,34 @@ class LoginSignUpEmployer extends StatelessWidget { @override Widget build(BuildContext context) { - return Container( - decoration: BoxDecoration( - image: DecorationImage( - image: AssetImage('assets/vector-5.png'), - fit: BoxFit.cover, - ), + return Stack( + children: [ + SvgPicture.asset( + 'assets/vector-5.svg', + height: MediaQuery.of(context).size.height, + width: MediaQuery.of(context).size.width, + fit: BoxFit.fill, + ), + Scaffold( + backgroundColor: Colors.transparent, + body: Column( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Padding( + padding: EdgeInsets.only(top: 20, bottom: 10), + child: Container( + alignment: Alignment.center, + child: Image.asset('assets/logo.png'), + height: 130, ), - child: Scaffold( - backgroundColor: Colors.transparent, - body: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Padding( - padding: EdgeInsets.only(top: 20, bottom: 10), - child:Container( - alignment: Alignment.center, - child: Image.asset('assets/logo_vertical.png'), - height: 80, - ), - ), - Flexible( - child: AuthCard(), - ), - ], ), - ), + Flexible( + child: AuthCard(), + ), + ], + ), + ), + ], ); } } @@ -65,67 +72,67 @@ class _AuthCardState extends State { showDialog( context: context, builder: (ctx) => AlertDialog( - title: Text('An Error Occurred!'), - content: Text(message), - actions: [ - FlatButton( - child: Text('Okay'), - onPressed: () { - Navigator.of(ctx).pop(); - }, - ) - ], - ), + title: Text('An Error Occurred!'), + content: Text(message), + actions: [ + FlatButton( + child: Text('Okay'), + onPressed: () { + Navigator.of(ctx).pop(); + }, + ) + ], + ), ); } - Future _submit() async { - if (!_formKey.currentState.validate()) { - // Invalid! - return; - } - _formKey.currentState.save(); - setState(() { - _isLoading = true; - }); - try { - if (_authMode == AuthMode.Login) { - // Log user in - await Provider.of(context, listen: false).login( - _authData['email'], - _authData['password'], - ); - } else { - // Sign user up - await Provider.of(context, listen: false).signup( - _authData['email'], - _authData['password'], - ); - } - } on HttpException catch (error) { - var errorMessage = 'Authentication failed'; - if (error.toString().contains('EMAIL_EXISTS')) { - errorMessage = 'This email address is already in use.'; - } else if (error.toString().contains('INVALID_EMAIL')) { - errorMessage = 'This is not a valid email address'; - } else if (error.toString().contains('WEAK_PASSWORD')) { - errorMessage = 'This password is too weak.'; - } else if (error.toString().contains('EMAIL_NOT_FOUND')) { - errorMessage = 'Could not find a user with that email.'; - } else if (error.toString().contains('INVALID_PASSWORD')) { - errorMessage = 'Invalid password.'; - } - _showErrorDialog(errorMessage); - } catch (error) { - const errorMessage = - 'Could not authenticate you. Please try again later.'; - _showErrorDialog(errorMessage); - } + // Future _submit() async { + // if (!_formKey.currentState.validate()) { + // // Invalid! + // return; + // } + // _formKey.currentState.save(); + // setState(() { + // _isLoading = true; + // }); + // try { + // if (_authMode == AuthMode.Login) { + // // Log user in + // await Provider.of(context, listen: false).login( + // _authData['email'], + // _authData['password'], + // ); + // } else { + // // Sign user up + // await Provider.of(context, listen: false).signup( + // _authData['email'], + // _authData['password'], + // ); + // } + // } on HttpException catch (error) { + // var errorMessage = 'Authentication failed'; + // if (error.toString().contains('EMAIL_EXISTS')) { + // errorMessage = 'This email address is already in use.'; + // } else if (error.toString().contains('INVALID_EMAIL')) { + // errorMessage = 'This is not a valid email address'; + // } else if (error.toString().contains('WEAK_PASSWORD')) { + // errorMessage = 'This password is too weak.'; + // } else if (error.toString().contains('EMAIL_NOT_FOUND')) { + // errorMessage = 'Could not find a user with that email.'; + // } else if (error.toString().contains('INVALID_PASSWORD')) { + // errorMessage = 'Invalid password.'; + // } + // _showErrorDialog(errorMessage); + // } catch (error) { + // const errorMessage = + // 'Could not authenticate you. Please try again later.'; + // _showErrorDialog(errorMessage); + // } - setState(() { - _isLoading = false; - }); - } + // setState(() { + // _isLoading = false; + // }); + // } void _switchAuthMode() { if (_authMode == AuthMode.Login) { @@ -142,243 +149,264 @@ class _AuthCardState extends State { @override Widget build(BuildContext context) { return Form( - key: _formKey, - child: SingleChildScrollView( - child: Column( + key: _formKey, + child: SingleChildScrollView( + child: Column( + children: [ + Column( children: [ - Column(children: [ - Text((_authMode == AuthMode.Login ? 'LOGIN AN ACCOUNT' : 'SIGN UP AN ACCOUNT'), - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: TextStyle( - color: Colors.white, fontSize: 14) - ), - ], - ), - Row(children: [ - Expanded( - child: Container( - margin: EdgeInsets.only(left: 120, right: 120), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( - decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'E-mail', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), - ), - keyboardType: TextInputType.emailAddress, - validator: (value) { - if (value.isEmpty || !value.contains('@')) { - return 'Invalid email!'; - } - }, - onSaved: (value) { - _authData['email'] = value; - }, + Text( + (_authMode == AuthMode.Login + ? 'LOGIN AN ACCOUNT' + : 'SIGN UP AN ACCOUNT'), + textAlign: TextAlign.center, + overflow: TextOverflow.ellipsis, + style: TextStyle(color: Colors.white, fontSize: 14)), + ], + ), + Row(children: [ + Expanded( + child: Container( + margin: EdgeInsets.only(left: 120, right: 120), + child: Divider( + thickness: 2, color: Color(0xff22c0e8), height: 30)), + ) + ]), + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + decoration: InputDecoration( + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'E-mail', + hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), + keyboardType: TextInputType.emailAddress, + validator: (value) { + if (value.isEmpty || !value.contains('@')) { + return 'Invalid email!'; + } + }, + onSaved: (value) { + _authData['email'] = value; + }, + ), + ), + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + decoration: InputDecoration( + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'Password', + hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( + obscureText: true, + controller: _passwordController, + validator: (value) { + if (value.isEmpty || value.length < 5) { + return 'Password is too short!'; + } + }, + onSaved: (value) { + _authData['password'] = value; + }, + ), + ), + if (_authMode == AuthMode.Signup) + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + enabled: _authMode == AuthMode.Signup, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'Password', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'Confirm Password', + hintStyle: + TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), obscureText: true, - controller: _passwordController, - validator: (value) { - if (value.isEmpty || value.length < 5) { - return 'Password is too short!'; - } - }, - onSaved: (value) { - _authData['password'] = value; - }, - ), - ), - if (_authMode == AuthMode.Signup) - - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( - enabled: _authMode == AuthMode.Signup, - decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'Confirm Password', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), - ), - obscureText: true, - validator: _authMode == AuthMode.Signup - ? (value) { - if (value != _passwordController.text) { - return 'Passwords do not match!'; - } + validator: _authMode == AuthMode.Signup + ? (value) { + if (value != _passwordController.text) { + return 'Passwords do not match!'; } - : null, - ), - ), - SizedBox( - height: 20, + } + : null, ), - if (_isLoading) - CircularProgressIndicator( - backgroundColor: Color(0xff22c0e8), - ) - else - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ + ), + SizedBox( + height: 20, + ), + if (_isLoading) + CircularProgressIndicator( + backgroundColor: Color(0xff22c0e8), + ) + else + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ MaterialButton( minWidth: 160, child: Text(_authMode == AuthMode.Login ? 'Login' : 'Sign Up'), - onPressed: _submit, + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => OTPEmployer())); + }, + // _submit, shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(30.0), ), padding: EdgeInsets.symmetric(horizontal: 30.0, vertical: 8.0), - color: (_authMode == AuthMode.Login ? Color(0xff57b22f) : Color(0xff22c0e8)), + color: (_authMode == AuthMode.Login + ? Color(0xff57b22f) + : Color(0xff22c0e8)), textColor: Colors.white, ), - SizedBox(width: 10), + SizedBox(width: 10), MaterialButton( minWidth: 160, child: Text( '${_authMode == AuthMode.Login ? 'Sign up' : 'Login'} an account'), onPressed: _switchAuthMode, shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - padding: EdgeInsets.symmetric(horizontal: 30.0, vertical: 4), + borderRadius: BorderRadius.circular(30.0), + ), + padding: + EdgeInsets.symmetric(horizontal: 30.0, vertical: 4), materialTapTargetSize: MaterialTapTargetSize.shrinkWrap, - color: (_authMode == AuthMode.Login ? Color(0xff22c0e8) : Color(0xff57b22f)), + color: (_authMode == AuthMode.Login + ? Color(0xff22c0e8) + : Color(0xff57b22f)), textColor: Colors.white, ), - ], + ], + ), + SizedBox(height: 15), + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Expanded( + child: Container( + margin: EdgeInsets.only(left: 20, right: 10), + child: Divider( + thickness: 0.5, + color: Colors.white, + ), + ), + ), + Text('OR', + style: TextStyle(fontSize: 11, color: Colors.white70)), + Expanded( + child: Container( + margin: EdgeInsets.only(right: 20, left: 10), + child: Divider( + thickness: 0.5, + color: Colors.white, + ), + ), ), - SizedBox(height: 15), - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Expanded( - child: Container( - margin: EdgeInsets.only(left: 20, right: 10), - child: Divider(thickness: 0.5, color: Colors.white,), - ), - ), - Text('OR', style: TextStyle(fontSize: 11, color: Colors.white70)), - Expanded( - child: Container( - margin: EdgeInsets.only(right: 20, left: 10), - child: Divider(thickness: 0.5, color: Colors.white,), - ), - ), - ], - ), - SizedBox(height: 15), - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - MaterialButton( - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - color: Color(0xff2d67a5), - minWidth: 160, - onPressed: () {}, - child: Row( - children: [ - Icon(MdiIcons.facebook, size: 20, color: Colors.white), - Text("Login with Facebook", - textAlign: TextAlign.center, - style: TextStyle( - color: Colors.white, fontSize: 11)), - ], - ), - ), - - SizedBox(width: 10), - - MaterialButton( - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - color: Colors.white, - minWidth: 160, - onPressed: () {}, - child: Row( - children: [ - Image.asset('assets/gmail.png', height: 12), - Text(" Login with Gmail", - textAlign: TextAlign.center, - style: TextStyle( - color: Color(0xff8997a7), fontSize: 11)), - ], - ), - ), - ], - ), - SizedBox(height: 70) ], ), - ), - + SizedBox(height: 15), + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + MaterialButton( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30.0), + ), + color: Color(0xff2d67a5), + minWidth: 160, + onPressed: () {}, + child: Row( + children: [ + Icon(MdiIcons.facebook, size: 20, color: Colors.white), + Text("Login with Facebook", + textAlign: TextAlign.center, + style: TextStyle(color: Colors.white, fontSize: 11)), + ], + ), + ), + SizedBox(width: 10), + MaterialButton( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30.0), + ), + color: Colors.white, + minWidth: 160, + onPressed: () {}, + child: Row( + children: [ + Image.asset('assets/gmail.png', height: 12), + Text(" Login with Gmail", + textAlign: TextAlign.center, + style: TextStyle( + color: Color(0xff8997a7), fontSize: 11)), + ], + ), + ), + ], + ), + SizedBox(height: 70) + ], + ), + ), ); } } - diff --git a/lib/src/ui/auth/employer/register_employer.dart b/lib/src/ui/auth/employer/register_employer.dart deleted file mode 100644 index f0b2451..0000000 --- a/lib/src/ui/auth/employer/register_employer.dart +++ /dev/null @@ -1,278 +0,0 @@ -import 'package:flutter/material.dart'; - - -class RegisterEmployer extends StatefulWidget { - - static const routeName = 'register_employer'; - - @override - _RegisterEmployerState createState() => _RegisterEmployerState(); -} - -class _RegisterEmployerState extends State { -TextStyle style = TextStyle(fontFamily: 'VarelaRound'); - - String dropdownValue = 'Seeker'; - - @override - Widget build(BuildContext context) { - - final textBody = - Column(children: [ - Column(children: [ - Text("REGISTER AN ACCOUNT", - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Color(0xff2c4057), fontSize: 12) - ), - ], - ), - Row(children: [ - Expanded( - child: new Container( - margin: const EdgeInsets.only(left: 70.0, right: 70.0), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ) - ] - ); - - - final usernameField = new TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Choose a Username", - hintStyle: style.copyWith(color: Color(0xff8997a7)), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final emailField = TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Enter Your Email Address", - hintStyle: style.copyWith(color: Color(0xff8997a7)), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final passwordField = new TextFormField( - obscureText: true, - style: style.copyWith( - - color: Colors.black45, - fontSize: 12, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Password", - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final confirmPassword = new TextFormField( - obscureText: true, - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Confirm Password", - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final selectField = FormField( - builder: (FormFieldState state) { - return InputDecorator( - decoration: InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 0.0, 30.0, 0.0), - errorStyle: style.copyWith(color: Colors.redAccent, fontSize: 12), - hintStyle: style.copyWith(color: Color(0xff8997a7)), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - child: DropdownButtonHideUnderline( - child: DropdownButton( - value: dropdownValue, - onChanged: (String newValue) { - setState(() { - dropdownValue = newValue; - }); - }, - icon: Icon(Icons.expand_more, color: Colors.blueGrey, size: 18,), - items: ['Seeker', 'Employer'] - .map>((String value) { - return DropdownMenuItem( - value: value, - child: Text(value, style: style.copyWith( - color: Color(0xff8997a7), - fontSize: 12, - letterSpacing: 0.25, - )), - ); - }).toList(), - ), - ), - ); - } - ); - - final regButton = Material( - elevation: 3.0, - borderRadius: BorderRadius.all(Radius.circular(50)), - color: Color(0xff22c0e8), - child: MaterialButton( - padding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), - onPressed: () { - // showDialog( - // context: context,builder: (_) => FlareGiffyDialog( - // flarePath: 'assets/space_demo.flr', - // flareAnimation: 'loading', - // title: Text('Sedang Loading', - // style: style.copyWith( - // fontSize: 22.0, fontWeight: FontWeight.w500), - // ), - // description: Text('Silahkan tunggu...', - // textAlign: TextAlign.center, - // style: style.copyWith(), - // ), - // onOkButtonPressed: () {}, - // ) ); - }, - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Text('Register Now', - textAlign: TextAlign.center, - style: style.copyWith( - - color: Color(0xffffffff), - fontSize: 14, - fontWeight: FontWeight.w500, - ) - ), - Icon(Icons.arrow_forward, color: Colors.white, size: 18,), - ], - ), - ), - ); - -return LayoutBuilder( - builder: (BuildContext context, BoxConstraints viewportConstraints) { - return Scaffold( - body: SingleChildScrollView( - child: ConstrainedBox( - constraints: BoxConstraints( - minHeight: viewportConstraints.maxHeight, - ), - child: Container( - padding: EdgeInsets.only(left: 60, right: 60, bottom: 30), - child: Column( - mainAxisAlignment: MainAxisAlignment.end, - mainAxisSize: MainAxisSize.max, - children: [ - textBody, - SizedBox( - height: 10.0, - ), - usernameField, - SizedBox( - height: 25.0), - emailField, - SizedBox( - height: 25.0), - passwordField, - SizedBox( - height: 25.0), - confirmPassword, - SizedBox( - height: 25.0, - ), - selectField, - SizedBox( - height: 25.0), - regButton, - SizedBox( - height: 15.0, - ), - Text("LOGIN TO YOUR EXISTING ACCOUNT", - style: style.copyWith( - color: Color(0xff8997a7), - fontSize: 9, - - fontStyle: FontStyle.normal, - letterSpacing: 0.55, - ) - ), - ], - - ), - ), - ), - ), - ); - } - ); - } - } diff --git a/lib/src/ui/auth/employer/ui_get_started_employer.dart b/lib/src/ui/auth/employer/ui_get_started_employer.dart index ef1b816..7c76f8e 100644 --- a/lib/src/ui/auth/employer/ui_get_started_employer.dart +++ b/lib/src/ui/auth/employer/ui_get_started_employer.dart @@ -1,60 +1,91 @@ import 'package:flutter/material.dart'; import 'package:space/navigator_employer.dart'; +import 'package:flutter_svg/flutter_svg.dart'; class UiGetStartedEmployer extends StatelessWidget { - + static const routeName = '/ui-employer'; @override Widget build(BuildContext context) { - TextStyle style = TextStyle(fontFamily: 'Quicksand-Regular', fontSize: 20.0); - return new Scaffold( - body: Padding( - padding: EdgeInsets.fromLTRB(50, 30, 50, 30), - child: Container( - height: MediaQuery.of(context).size.height, - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Container( - padding: EdgeInsets.symmetric(horizontal: 70), - child: Image.asset('assets/logo_vertical.png') - ), - Text('Are you ready to find your dream team?', - textAlign: TextAlign.center, - style: style.copyWith(fontSize: 40, color: Color(0xff3b3b3b), fontWeight: FontWeight.bold)), - Text('Find your best team now is easiers. Easy to post a job, get in touch via chat, interviewing anywhere via live. Just type and upload.', - textAlign: TextAlign.center, - style: style.copyWith(fontSize: 17.2, color: Color(0x99383839), fontWeight: FontWeight.w600)), - ButtonTheme( - minWidth: 190, - height: 55, - child: RaisedButton( - color: Color(0xff57b22f), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => EmployerNavigator())); - }, - child: Text('Get Started', style: style.copyWith(fontSize: 24, color: Colors.white, fontWeight: FontWeight.bold)), - ), - ), - ButtonTheme( - minWidth: 190, - height: 55, - child: OutlineButton( - highlightedBorderColor: Color(0xff57b22f), - borderSide: BorderSide(color: Color(0xff57b22f)), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => EmployerNavigator())); - }, - child: Text('Try Trial', style: style.copyWith(fontSize: 24, color: Color(0xff57b22f), fontWeight: FontWeight.bold)), - ), + TextStyle style = + TextStyle(fontFamily: 'Quicksand-Regular', fontSize: 20.0, color: Colors.white); + return Stack( + children: [ + SvgPicture.asset( + 'assets/vector-5.svg', + height: MediaQuery.of(context).size.height, + width: MediaQuery.of(context).size.width, + fit: BoxFit.fill, + ), + Scaffold( + backgroundColor: Colors.transparent, + body: Container( + padding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), + height: MediaQuery.of(context).size.height, + child: Column( + mainAxisAlignment: MainAxisAlignment.end, + children: [ + Container( + child: Image.asset('assets/logo.png', height: 150,)), + Text('Are you ready to find your dream team?', + textAlign: TextAlign.center, + style: style.copyWith( + fontSize: 32, + color: Colors.white, + fontWeight: FontWeight.bold)), + SizedBox(height: 30), + Text( + 'Find your best team now is easiers. Easy to post a job, get in touch via chat, interviewing anywhere via live. Just type and upload.', + textAlign: TextAlign.center, + style: style.copyWith( + fontSize: 16, + color: Colors.white, + fontWeight: FontWeight.w600)), + SizedBox(height: 50), + ButtonTheme( + minWidth: 190, + height: 55, + child: RaisedButton( + color: Color(0xff57b22f), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => + EmployerNavigator())); + }, + child: Text('Get Started', + style: style.copyWith( + fontSize: 24, + color: Colors.white, + fontWeight: FontWeight.bold)), + ), + ), + SizedBox(height: 20), + ButtonTheme( + minWidth: 190, + height: 55, + child: OutlineButton( + highlightedBorderColor: Colors.white, + borderSide: BorderSide(color: Colors.white), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => + EmployerNavigator())); + }, + child: Text('Try Trial', + style: style.copyWith( + fontSize: 24, + color: Colors.white, + fontWeight: FontWeight.bold)), + ), + ), + ], ), - ], ), ), - ), + ], ); } -} \ No newline at end of file +} diff --git a/lib/src/ui/auth/seeker/home_seeker.dart b/lib/src/ui/auth/seeker/home_seeker.dart index d6c2e85..da1b7b0 100644 --- a/lib/src/ui/auth/seeker/home_seeker.dart +++ b/lib/src/ui/auth/seeker/home_seeker.dart @@ -1,666 +1,674 @@ import 'package:carousel_slider/carousel_slider.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; import 'package:flutter/material.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:gradient_app_bar/gradient_app_bar.dart'; +import 'package:carousel_pro/carousel_pro.dart'; +import 'package:space/src/ui/components/category_job_screen.dart'; -import 'package:space/src/ui/seeker/widgets/seeker_app_drawer.dart'; +import 'package:space/src/ui/employer/widgets/employer_app_drawer.dart'; import 'package:space/src/ui/components/horizontal_screen.dart'; import 'package:space/src/ui/components/recommended_screen.dart'; import 'package:space/src/ui/seeker/layout/seeker_profile_view.dart'; -class HomePageSeeker extends StatefulWidget { - - static const routeName = 'home_page_seeker'; +class HomePageSeeker extends StatefulWidget { + static const routeName = '/home_page_seeker'; @override _HomePageSeekerState createState() => _HomePageSeekerState(); } class _HomePageSeekerState extends State { - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0, color: Color(0xff3b3b3b)); - TextStyle style2= TextStyle(fontFamily: 'TitilliumWeb', fontSize: 20.0, color: Color(0xff3b3b3b)); - int _current = 0; + TextStyle style = TextStyle( + fontFamily: 'VarelaRound', fontSize: 20.0, color: Color(0xff3b3b3b)); + TextStyle style2 = TextStyle( + fontFamily: 'TitilliumWeb', fontSize: 20.0, color: Color(0xff3b3b3b)); + int _current = 0; - final List imgList = [ - Image.asset('assets/home.png', fit: BoxFit.contain), - Image.asset('assets/vector-3.png', fit: BoxFit.contain), - Image.asset('assets/job.png', fit: BoxFit.contain), - Image.asset('assets/job2.png', fit: BoxFit.contain), - Image.asset('assets/blog.png', fit: BoxFit.contain), -]; + List map(List list, Function handler) { + List result = []; + for (var i = 0; i < list.length; i++) { + result.add(handler(i, list[i])); + } -List map(List list, Function handler) { - List result = []; - for (var i = 0; i < list.length; i++) { - result.add(handler(i, list[i])); + return result; } - return result; -} - @override Widget build(BuildContext context) { - return Scaffold( - drawer: AppDrawer(), - backgroundColor: Colors.grey[200], - appBar: AppBar( - automaticallyImplyLeading: false, - elevation: 0.0, - backgroundColor: Colors.grey[200], - leading: Builder( - builder: (context) => IconButton( - icon: Icon(Icons.menu), - onPressed: () => Scaffold.of(context).openDrawer(), - ), - ), - title: TextFormField( - textInputAction: TextInputAction.search, - style: style.copyWith( - fontSize: 16, - color: Color(0xffc9c8c8), - decoration: TextDecoration.none, - ), - decoration: InputDecoration( - focusedBorder: InputBorder.none, - contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), - prefixIcon: IconButton( - onPressed: (){ - - }, - icon: Icon(FeatherIcons.search, size: 18,), - color: Color(0xffc9c8c8)), - fillColor: Colors.white, - filled: true, - hintText: 'Try "Barista"', - hintStyle: style.copyWith(color: Color(0xffc9c8c8), fontSize: 16), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xffc5cfda)), - )), - ), - ), - body: ListView( - children: [ - Container( - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - - Column( - children: [ - CarouselSlider( - items: imgList, - autoPlay: true, - enlargeCenterPage: true, - aspectRatio: 2.0, - onPageChanged: (index) { - setState(() { - _current = index; - }); - }, - ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 35), - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Row( - mainAxisAlignment: MainAxisAlignment.start, - children: map( - imgList, - (index, url) { - return Container( - width: 8.0, - height: 8.0, - margin: EdgeInsets.symmetric(horizontal: 2.0), - decoration: BoxDecoration( - shape: BoxShape.circle, - color: _current == index - ? Color.fromRGBO(0, 0, 0, 0.9) - : Color.fromRGBO(0, 0, 0, 0.4)), - ); - }, - ), - ), - Text('See All', - style: style2.copyWith(fontSize: 10, color: Color(0xffc9c8c8), letterSpacing: 1)), - ],), - ), - ]), - SizedBox(height: 10), - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('Recent Job', - style: style2.copyWith(fontSize: 16, fontWeight: FontWeight.bold, letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith(fontSize: 10, color: Color(0xffc9c8c8), letterSpacing: 1))), - onTap: () {}, - )), - - SizedBox( - height: 180, - child: HorizontalScreen()), - - Container( - height: 50, - child: ListTile( - leading: Text('Recomended Job', style: style2.copyWith(fontSize: 16, fontWeight: FontWeight.bold, letterSpacing: 1)), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith(fontSize: 10, color: Color(0xffc9c8c8), letterSpacing: 1))), - onTap: () {}, - )), - - SizedBox( - height: 180, - child: RecommendedScreen(), - ), - - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('Feed your Dreams', - style: style2.copyWith(fontSize: 16, fontWeight: FontWeight.bold, letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith(fontSize: 10, color: Color(0xffc9c8c8), letterSpacing: 1))), - onTap: () {}, - )), - - Container( - padding: EdgeInsets.symmetric(horizontal: 16), - child: Column( - children: [ - Text( - 'Success story from people around you, encourage, giving nutritions to your dreams.', - style: style.copyWith(fontSize: 13)), - ], - ), - ), - - Container( - margin: EdgeInsets.only(top: 10, left: 16, right: 16), - padding: EdgeInsets.only(bottom: 10), - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.only(bottomLeft: Radius.circular(5), bottomRight: Radius.circular(5)) + return Stack( + children: [ + Container( + height: 94, + width: MediaQuery.of(context).size.width, + child: Image.asset( + 'assets/vector-5.png', + fit: BoxFit.fitWidth, ), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - SizedBox( - width: MediaQuery.of(context).size.width, - height: 200, - child: Image.asset('assets/blog.png', fit: BoxFit.cover)), - Padding( - padding: EdgeInsets.all(10), - child: Text("How to success and winning competition", - style: style.copyWith( - color: Color(0xff3b3b3b), - fontSize: 16, - fontWeight: FontWeight.bold, - letterSpacing: 0.5, - ))), - Padding( - padding: EdgeInsets.all(10), - child: Text('Success story from people around you, encourage, giving nutritions to your dreams. Lorem ipsum dollor', - style: style.copyWith( - color: Color(0xff3b3b3b), - fontSize: 12))), - ], - ),), - - Container( - margin: EdgeInsets.only(top: 10), - height: 45, - child: ListTile( - leading: Container( - child: Text('People around you', - style: style2.copyWith(fontSize: 16, fontWeight: FontWeight.bold, letterSpacing: 1))), - trailing: Container( - margin: EdgeInsets.only(bottom: 5), - child: Text('See All', - style: style2.copyWith(fontSize: 10, color: Color(0xffc9c8c8), letterSpacing: 1))), - onTap: () {}, - )), - - Material( - child: Container( - height: 120, - child: SingleChildScrollView( - scrollDirection: Axis.horizontal, - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Uray Bawadi', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_2.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Yudi Salim', style: style.copyWith(fontSize: 10), - ), - ], - ), + ), + Scaffold( + drawer: EmployerDrawer(), + backgroundColor: Colors.transparent, + appBar: PreferredSize( + preferredSize: Size.fromHeight(70), // here the desired height + child: AppBar( + backgroundColor: Colors.transparent, + automaticallyImplyLeading: false, + leading: Builder( + builder: (context) => IconButton( + icon: Icon(Icons.menu, color: Colors.white), + onPressed: () => Scaffold.of(context).openDrawer(), ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_3.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Aprianto', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_4.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Gamabunta', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Uray Bawadi', style: style.copyWith(fontSize: 10), - ), - ], - ),), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_2.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Yudi Salim', style: style.copyWith(fontSize: 10), - ), - ], ), + title: TextFormField( + textInputAction: TextInputAction.search, + style: style.copyWith( + fontSize: 16, + color: Color(0xffc9c8c8), + decoration: TextDecoration.none, ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_3.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Aprianto', style: style.copyWith(fontSize: 10), - ), - ], + decoration: InputDecoration( + focusedBorder: InputBorder.none, + contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), + prefixIcon: IconButton( + onPressed: () {}, + icon: Icon( + FeatherIcons.search, + size: 18, + ), + color: Color(0xffc9c8c8)), + fillColor: Colors.white, + filled: true, + hintText: 'Try "Barista"', + hintStyle: + style.copyWith(color: Color(0xffc9c8c8), fontSize: 16), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xffc5cfda)), + )), ), ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_4.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), - ), - ], - ), - Text( - 'Gamabunta', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, + ), + body: ListView( + children: [ + Container( + child: Column( + children: [ + Container( + padding: + EdgeInsets.symmetric(horizontal: 10, vertical: 10), + height: 120, + child: Carousel( + borderRadius: true, + boxFit: BoxFit.fill, + autoplay: true, + animationCurve: Curves.fastOutSlowIn, + animationDuration: Duration(milliseconds: 2000), + dotSize: 4.0, + dotSpacing: 15, + dotIncreasedColor: Colors.amber, + dotBgColor: Colors.transparent, + dotPosition: DotPosition.bottomLeft, + dotVerticalPadding: 5.0, + showIndicator: true, + dotHorizontalPadding: 10.0, + indicatorBgPadding: 0, + images: [ + NetworkImage( + 'https://www.theatreartlife.com/wp-content/uploads/TheMarket-Ad-TD-800x200-768x192.png'), + NetworkImage( + 'http://tapsbus.com/wp-content/uploads/2015/06/driver-job-fi.png'), + NetworkImage( + 'https://i0.wp.com/www.thehtn.co.uk/wp-content/uploads/2019/08/Latest-News-3-copy-3.png?fit=800%2C200&ssl=1'), + ], ), ), - ], - ), - Text( - 'Uray Bawadi', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_2.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, - ), + SizedBox(height: 70, child: CategoryScreen()), + Container( + height: 45, + child: ListTile( + leading: Container( + child: Text('Recommended Job', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + SizedBox(height: 150, child: RecommendedScreen()), + Container( + height: 50, + child: ListTile( + leading: Text('Job Around You', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + SizedBox( + height: 180, + child: RecentScreen(), ), - ], - ), - Text( - 'Yudi Salim', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_3.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, + Container( + margin: EdgeInsets.only(top: 10), + height: 45, + child: ListTile( + leading: Container( + child: Text('Feed your Dreams', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + Card( + margin: + EdgeInsets.symmetric(horizontal: 15, vertical: 10), + elevation: 3, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10)), + child: Container( + padding: EdgeInsets.only(bottom: 10), + decoration: BoxDecoration(color: Colors.white), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, + children: [ + ClipRRect( + borderRadius: BorderRadius.only( + topLeft: Radius.circular(10), + topRight: Radius.circular(10)), + child: Image.asset('assets/blog.png', + fit: BoxFit.fitWidth)), + Padding( + padding: EdgeInsets.all(10), + child: Text( + "How to success and winning competition", + style: style.copyWith( + color: Color(0xff3b3b3b), + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 0.5, + ))), + Padding( + padding: EdgeInsets.all(10), + child: Text( + 'Success story from people around you, encourage, giving nutritions to your dreams. Lorem ipsum dollor', + style: style.copyWith( + color: Color(0xff3b3b3b), + fontSize: 12))), + ], + ), ), ), - ], - ), - Text( - 'Aprianto', style: style.copyWith(fontSize: 10), - ), - ], - ), - ), - Padding( - padding: EdgeInsets.symmetric(vertical: 10), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - Stack( - alignment: Alignment(0.6, -1), - children: [ - MaterialButton( - shape: CircleBorder(), - onPressed: () { Navigator.push(context, new MaterialPageRoute( - builder: (context) => - new SeekerProfileView()) - ); }, - child: CircleAvatar( - backgroundColor: Color(0xff48576a), - radius: 30.0, - child: Image.asset('assets/img_profil_4.png', scale: 1.3) - )), - CircleAvatar( - backgroundColor: Color(0xff22c0e8), - radius: 10, - child: Icon( - Icons.add, color: Colors.white, size: 16, + Container( + margin: EdgeInsets.only(top: 10), + height: 45, + child: ListTile( + leading: Container( + child: Text('People around you', + style: style2.copyWith( + fontSize: 16, + fontWeight: FontWeight.bold, + letterSpacing: 1))), + trailing: Container( + margin: EdgeInsets.only(bottom: 5), + child: Text('See All', + style: style2.copyWith( + fontSize: 10, + color: Color(0xffc9c8c8), + letterSpacing: 1))), + onTap: () {}, + )), + Material( + child: Container( + height: 120, + child: SingleChildScrollView( + scrollDirection: Axis.horizontal, + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceAround, + children: [ + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil.png', + scale: 1.3))), + ], + ), + Text( + 'Uray Bawadi', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_2.png', + scale: 1.3))), + ], + ), + Text( + 'Yudi Salim', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_3.png', + scale: 1.3))), + ], + ), + Text( + 'Aprianto', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + Padding( + padding: EdgeInsets.symmetric(vertical: 10), + child: Column( + mainAxisAlignment: + MainAxisAlignment.spaceEvenly, + children: [ + Stack( + alignment: Alignment(0.6, -1), + children: [ + MaterialButton( + shape: CircleBorder(), + onPressed: () { + Navigator.push( + context, + new MaterialPageRoute( + builder: (context) => + new SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: + Color(0xff48576a), + radius: 30.0, + child: Image.asset( + 'assets/img_profil_4.png', + scale: 1.3))), + ], + ), + Text( + 'Gamabunta', + style: style.copyWith(fontSize: 10), + ), + ], + ), + ), + ]), + ), ), ), - ], - ), - Text( - 'Gamabunta', style: style.copyWith(fontSize: 10), - ), - ], - ), + SizedBox(height: 30) + ], + ), ), - ] - ), + ], ), ), - ), - SizedBox(height: 30) - - ], - ), - ), ], - ), - ); - + ); } - } diff --git a/lib/src/ui/auth/seeker/intro_seeker.dart b/lib/src/ui/auth/seeker/intro_seeker.dart new file mode 100644 index 0000000..f9a26d9 --- /dev/null +++ b/lib/src/ui/auth/seeker/intro_seeker.dart @@ -0,0 +1,109 @@ +import 'package:flutter/material.dart'; +import 'package:intro_views_flutter/Models/page_view_model.dart'; +import 'package:intro_views_flutter/intro_views_flutter.dart'; +import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; +import 'package:space/src/ui/auth/seeker/ui_get_started_seeker.dart'; + + +class IntroSeeker extends StatelessWidget { + final pages = [ + PageViewModel( + pageColor: const Color(0xffff6d00), + iconImageAssetPath: 'assets/seeker-1.png', + bubble: Image.asset('assets/seeker-1.png'), + body: Text( + 'More than 100+ Job may suite you.', + ), + title: Text( + 'Get job and Start your dreams!', textAlign: TextAlign.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + mainImage: Image.asset( + 'assets/seeker-1.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + )), + PageViewModel( + pageColor: const Color(0xffd50000), + iconImageAssetPath: 'assets/seeker-2.png', + bubble: Image.asset('assets/seeker-2.png'), + body: Text( + 'Say goodbay to paper, More Effectives and Efficients.', + ), + title: Text( + 'New and Easier way!', textAlign: TextAlign.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + mainImage: Image.asset( + 'assets/seeker-2.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + )), + PageViewModel( + pageColor: const Color(0xff64dd17), + bubble: Image.asset('assets/seeker-3.png'), + iconImageAssetPath: 'assets/seeker-3.png', + body: Text('Check your applied status. No need to wait for another chances.', + textAlign: TextAlign.center), + title: Text('No worry!', + textAlign: TextAlign.center), + mainImage: Image.asset( + 'assets/seeker-3.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + ), + PageViewModel( + pageColor: const Color(0xff64dd17), + bubble: Image.asset('assets/employer-3.png'), + iconImageAssetPath: 'assets/employer-3.png', + body: Text('Contact your employer directly with chat and live interview Features.', + textAlign: TextAlign.center), + title: Text('Get in touch directly!', + textAlign: TextAlign.center), + mainImage: Image.asset( + 'assets/employer-3.png', + height: 285.0, + width: 285.0, + alignment: Alignment.center, + ), + titleTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 32, fontWeight: FontWeight.bold), + bodyTextStyle: TextStyle(fontFamily: 'VarelaRound', color: Colors.white, fontSize: 21), + ), + ]; + + @override + Widget build(BuildContext context) { + return Scaffold( + body: Builder( + builder: (context) => IntroViewsFlutter( + pages, + showNextButton: true, + showBackButton: true, + showSkipButton: true, + doneText: Text('DONE'), + onTapDoneButton: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => UiGetStartedSeeker(), + ), //MaterialPageRoute + ); + }, + pageButtonTextStyles: TextStyle( + color: Colors.white, + fontSize: 16.0, + ), + pageButtonTextSize: 5, + ), //IntroViewsFlutter + ), //Builder + ); //Material App + } +} diff --git a/lib/src/ui/auth/seeker/login_seeker.dart b/lib/src/ui/auth/seeker/login_seeker.dart deleted file mode 100644 index daa65ee..0000000 --- a/lib/src/ui/auth/seeker/login_seeker.dart +++ /dev/null @@ -1,257 +0,0 @@ -import 'package:flutter/material.dart'; - -import 'package:space/src/ui/auth/seeker/ui_get_started_seeker.dart'; - - -class LoginSeeker extends StatefulWidget { - - static const routeName = 'login_seeker'; - - @override - _LoginSeekerState createState() => _LoginSeekerState(); -} - -class _LoginSeekerState extends State { - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); - final GlobalKey _formKey = GlobalKey(); - Map _authData = { - 'email': '', - 'password': '', - }; - var _isLoading = false; - final _passwordController = TextEditingController(); - - void _showErrorDialog(String message) { - showDialog( - context: context, - builder: (ctx) => AlertDialog( - title: Text('An Error Occurred!'), - content: Text(message), - actions: [ - FlatButton( - child: Text('Ok'), - onPressed: () { - Navigator.of(ctx).pop(); - }, - ) - ], - ), - ); - } - - Future _submit() async { - if (!_formKey.currentState.validate()) { - // Invalid! - return; - } - _formKey.currentState.save(); - setState(() { - _isLoading = true; - }); - - setState(() { - _isLoading = false; - }); - } - - @override - Widget build(BuildContext context) { - final textBody = - Column(children: [ - Column( - children: [ - Text('LOGIN TO YOUR ACCOUNT', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Color(0xff2c4057), fontSize: 12) - ), - ], - ), - Row(children: [ - Expanded( - child: new Container( - margin: const EdgeInsets.symmetric(horizontal: 70), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ) - ] - ); - - - final emailField = new TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: 'Email Address', - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - keyboardType: TextInputType.emailAddress, - validator: (value) { - if (value.isEmpty || !value.contains('@')) { - return 'Invalid email!'; - } - }, - onSaved: (value) { - _authData['email'] = value; - }, - ); - final passwordField = TextFormField( - obscureText: true, - controller: _passwordController, - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: 'Password', - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) { - if (value.isEmpty || value.length < 5) { - return 'Password is too short!'; - } - }, - onSaved: (value) { - _authData['password'] = value; - }, - ); - - final loginButton = Material( - elevation: 3.0, - borderRadius: BorderRadius.circular(30.0), - color: Color(0xff57b22f), - child: MaterialButton( - padding: EdgeInsets.fromLTRB(60.0, 15.0, 20.0, 15.0), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => UiGetStartedSeeker())); - }, - child: Row( - children: [ - Text('Login Now', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.white, fontSize: 14)), - const Expanded( - child: Icon(Icons.arrow_forward, color: Colors.white, size: 18,)), - ], - ), - ), - ); - - final linkForgot = Container( - child: Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - MaterialButton( - padding: EdgeInsets.fromLTRB(5.0, 5.0, 5.0, 5.0), - onPressed: _submit, - child: Text('FORGOT PASSWORD?', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Colors.cyan[400], fontSize: 9))), - Text('|', style: style.copyWith(fontSize: 8, color: Colors.blueGrey)), - MaterialButton( - padding: EdgeInsets.fromLTRB(5.0, 5.0, 0.0, 5.0), - onPressed: () {Navigator.pushNamed(context, 'space/register_account');}, - child: Text('REGISTER AN ACCOUNT', - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Colors.blueGrey, fontSize: 9))), - ], - ), - ); - - return LayoutBuilder( - builder: (BuildContext context, BoxConstraints viewportConstraints) { - return Scaffold( - body: SingleChildScrollView( - child: ConstrainedBox( - constraints: BoxConstraints( - minHeight: viewportConstraints.maxHeight, - ), - child: Container( - padding: EdgeInsets.only(left: 60, right: 60), - child: Column( - mainAxisAlignment: MainAxisAlignment.end, - mainAxisSize: MainAxisSize.min, - children: [ - textBody, - SizedBox( - height: 10.0, - ), - SizedBox(height: 50.0), - emailField, - SizedBox(height: 20.0), - passwordField, - SizedBox( - height: 30.0, - ), - loginButton, - SizedBox( - height: 5.0, - ), - linkForgot, - SizedBox( - height: 80.0, - ), - - Column ( - children: [ - Text('Copyright © 2019 by Dreamjob', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.blueGrey, fontSize: 10) - ), - Text('www.dreamjob.com', - textAlign: TextAlign.center, - style: style.copyWith( - color: Colors.cyan[400], fontSize: 10)), - ], - ), - SizedBox( - height: 5 - ), - ], - ),), - ), - ), - ); - } - -); - } - } - diff --git a/lib/src/ui/auth/seeker/login_signup_seeker.dart b/lib/src/ui/auth/seeker/login_signup_seeker.dart index b4cdf63..116aaba 100644 --- a/lib/src/ui/auth/seeker/login_signup_seeker.dart +++ b/lib/src/ui/auth/seeker/login_signup_seeker.dart @@ -1,43 +1,51 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; import 'package:provider/provider.dart'; import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:space/navigator_employer.dart'; import 'package:space/src/core/models/http_exception.dart'; import 'package:space/src/core/models/auth.dart'; +import 'package:space/src/ui/auth/employer/ui_get_started_employer.dart'; +import 'package:space/src/ui/auth/seeker/intro_seeker.dart'; +import 'package:space/src/ui/auth/seeker/ui_get_started_seeker.dart'; +import 'package:space/src/ui/components/otp_seeker.dart'; enum AuthMode { Signup, Login } class LoginSignUpSeeker extends StatelessWidget { - static const routeName = '/auth'; + static const routeName = '/auth-seeker'; @override Widget build(BuildContext context) { - return Container( - decoration: BoxDecoration( - image: DecorationImage( - image: AssetImage('assets/vector-5.png'), - fit: BoxFit.cover, - ), + return Stack( + children: [ + SvgPicture.asset( + 'assets/vector-5.svg', + height: MediaQuery.of(context).size.height, + width: MediaQuery.of(context).size.width, + fit: BoxFit.fill, + ), + Scaffold( + backgroundColor: Colors.transparent, + body: Column( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Padding( + padding: EdgeInsets.only(top: 20, bottom: 10), + child: Container( + alignment: Alignment.center, + child: Image.asset('assets/logo.png'), + height: 130, ), - child: Scaffold( - backgroundColor: Colors.transparent, - body: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Padding( - padding: EdgeInsets.only(top: 20, bottom: 10), - child:Container( - alignment: Alignment.center, - child: Image.asset('assets/logo_vertical.png'), - height: 80, - ), - ), - Flexible( - child: AuthCard(), - ), - ], ), - ), + Flexible( + child: AuthCard(), + ), + ], + ), + ), + ], ); } } @@ -65,67 +73,67 @@ class _AuthCardState extends State { showDialog( context: context, builder: (ctx) => AlertDialog( - title: Text('An Error Occurred!'), - content: Text(message), - actions: [ - FlatButton( - child: Text('Okay'), - onPressed: () { - Navigator.of(ctx).pop(); - }, - ) - ], - ), + title: Text('An Error Occurred!'), + content: Text(message), + actions: [ + FlatButton( + child: Text('Okay'), + onPressed: () { + Navigator.of(ctx).pop(); + }, + ) + ], + ), ); } - Future _submit() async { - if (!_formKey.currentState.validate()) { - // Invalid! - return; - } - _formKey.currentState.save(); - setState(() { - _isLoading = true; - }); - try { - if (_authMode == AuthMode.Login) { - // Log user in - await Provider.of(context, listen: false).login( - _authData['email'], - _authData['password'], - ); - } else { - // Sign user up - await Provider.of(context, listen: false).signup( - _authData['email'], - _authData['password'], - ); - } - } on HttpException catch (error) { - var errorMessage = 'Authentication failed'; - if (error.toString().contains('EMAIL_EXISTS')) { - errorMessage = 'This email address is already in use.'; - } else if (error.toString().contains('INVALID_EMAIL')) { - errorMessage = 'This is not a valid email address'; - } else if (error.toString().contains('WEAK_PASSWORD')) { - errorMessage = 'This password is too weak.'; - } else if (error.toString().contains('EMAIL_NOT_FOUND')) { - errorMessage = 'Could not find a user with that email.'; - } else if (error.toString().contains('INVALID_PASSWORD')) { - errorMessage = 'Invalid password.'; - } - _showErrorDialog(errorMessage); - } catch (error) { - const errorMessage = - 'Could not authenticate you. Please try again later.'; - _showErrorDialog(errorMessage); - } + // Future _submit() async { + // if (!_formKey.currentState.validate()) { + // // Invalid! + // return; + // } + // _formKey.currentState.save(); + // setState(() { + // _isLoading = true; + // }); + // try { + // if (_authMode == AuthMode.Login) { + // // Log user in + // await Provider.of(context, listen: false).login( + // _authData['email'], + // _authData['password'], + // ); + // } else { + // // Sign user up + // await Provider.of(context, listen: false).signup( + // _authData['email'], + // _authData['password'], + // ); + // } + // } on HttpException catch (error) { + // var errorMessage = 'Authentication failed'; + // if (error.toString().contains('EMAIL_EXISTS')) { + // errorMessage = 'This email address is already in use.'; + // } else if (error.toString().contains('INVALID_EMAIL')) { + // errorMessage = 'This is not a valid email address'; + // } else if (error.toString().contains('WEAK_PASSWORD')) { + // errorMessage = 'This password is too weak.'; + // } else if (error.toString().contains('EMAIL_NOT_FOUND')) { + // errorMessage = 'Could not find a user with that email.'; + // } else if (error.toString().contains('INVALID_PASSWORD')) { + // errorMessage = 'Invalid password.'; + // } + // _showErrorDialog(errorMessage); + // } catch (error) { + // const errorMessage = + // 'Could not authenticate you. Please try again later.'; + // _showErrorDialog(errorMessage); + // } - setState(() { - _isLoading = false; - }); - } + // setState(() { + // _isLoading = false; + // }); + // } void _switchAuthMode() { if (_authMode == AuthMode.Login) { @@ -142,242 +150,262 @@ class _AuthCardState extends State { @override Widget build(BuildContext context) { return Form( - key: _formKey, - child: SingleChildScrollView( - child: Column( + key: _formKey, + child: SingleChildScrollView( + child: Column( + children: [ + Column( children: [ - Column(children: [ - Text((_authMode == AuthMode.Login ? 'LOGIN AN ACCOUNT' : 'SIGN UP AN ACCOUNT'), - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: TextStyle( - color: Colors.white, fontSize: 14) - ), - ], - ), - Row(children: [ - Expanded( - child: new Container( - margin: const EdgeInsets.only(left: 120, right: 120), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( - decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'E-mail', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), - ), - keyboardType: TextInputType.emailAddress, - validator: (value) { - if (value.isEmpty || !value.contains('@')) { - return 'Invalid email!'; - } - }, - onSaved: (value) { - _authData['email'] = value; - }, + Text( + (_authMode == AuthMode.Login + ? 'LOGIN AN ACCOUNT' + : 'SIGN UP AN ACCOUNT'), + textAlign: TextAlign.center, + overflow: TextOverflow.ellipsis, + style: TextStyle(color: Colors.white, fontSize: 14)), + ], + ), + Row(children: [ + Expanded( + child: Container( + margin: EdgeInsets.only(left: 120, right: 120), + child: Divider( + thickness: 2, color: Color(0xff22c0e8), height: 30)), + ) + ]), + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + decoration: InputDecoration( + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'E-mail', + hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), + keyboardType: TextInputType.emailAddress, + validator: (value) { + if (value.isEmpty || !value.contains('@')) { + return 'Invalid email!'; + } + }, + onSaved: (value) { + _authData['email'] = value; + }, + ), + ), + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + decoration: InputDecoration( + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'Password', + hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( + obscureText: true, + controller: _passwordController, + validator: (value) { + if (value.isEmpty || value.length < 5) { + return 'Password is too short!'; + } + }, + onSaved: (value) { + _authData['password'] = value; + }, + ), + ), + if (_authMode == AuthMode.Signup) + Padding( + padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), + child: TextFormField( + enabled: _authMode == AuthMode.Signup, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'Password', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), + contentPadding: + EdgeInsets.symmetric(horizontal: 20, vertical: 10), + errorStyle: TextStyle(color: Theme.of(context).errorColor), + hintText: 'Confirm Password', + hintStyle: + TextStyle(color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + errorBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Theme.of(context).errorColor), + borderRadius: BorderRadius.all(Radius.circular(30))), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8)), + borderRadius: BorderRadius.all(Radius.circular(30))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(30))), ), obscureText: true, - controller: _passwordController, - validator: (value) { - if (value.isEmpty || value.length < 5) { - return 'Password is too short!'; - } - }, - onSaved: (value) { - _authData['password'] = value; - }, - ), - ), - if (_authMode == AuthMode.Signup) - - Padding( - padding: EdgeInsets.symmetric(horizontal: 50, vertical: 5), - child: TextFormField( - enabled: _authMode == AuthMode.Signup, - decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), - errorStyle: TextStyle(color: Theme.of(context).errorColor), - hintText: 'Confirm Password', - hintStyle: TextStyle(color: Color(0xff8997a7), fontSize: 14), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: Theme.of(context).errorColor), - borderRadius: BorderRadius.all(Radius.circular(30))), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8)), - borderRadius: BorderRadius.all(Radius.circular(30))), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: Colors.transparent), - borderRadius: BorderRadius.all(Radius.circular(30))), - ), - obscureText: true, - validator: _authMode == AuthMode.Signup - ? (value) { - if (value != _passwordController.text) { - return 'Passwords do not match!'; - } + validator: _authMode == AuthMode.Signup + ? (value) { + if (value != _passwordController.text) { + return 'Passwords do not match!'; } - : null, - ), - ), - SizedBox( - height: 20, + } + : null, ), - if (_isLoading) - CircularProgressIndicator( - backgroundColor: Color(0xff22c0e8), - ) - else - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ + ), + SizedBox( + height: 20, + ), + if (_isLoading) + CircularProgressIndicator( + backgroundColor: Color(0xff22c0e8), + ) + else + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ MaterialButton( minWidth: 160, child: Text(_authMode == AuthMode.Login ? 'Login' : 'Sign Up'), - onPressed: _submit, + onPressed: () { + Navigator.push(context, + MaterialPageRoute(builder: (context) => OTPSeeker())); + }, + // _submit, shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(30.0), ), padding: EdgeInsets.symmetric(horizontal: 30.0, vertical: 8.0), - color: (_authMode == AuthMode.Login ? Color(0xff57b22f) : Color(0xff22c0e8)), + color: (_authMode == AuthMode.Login + ? Color(0xff57b22f) + : Color(0xff22c0e8)), textColor: Colors.white, ), - SizedBox(width: 10), + SizedBox(width: 10), MaterialButton( minWidth: 160, child: Text( '${_authMode == AuthMode.Login ? 'Sign up' : 'Login'} an account'), onPressed: _switchAuthMode, shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - padding: EdgeInsets.symmetric(horizontal: 30.0, vertical: 4), + borderRadius: BorderRadius.circular(30.0), + ), + padding: + EdgeInsets.symmetric(horizontal: 30.0, vertical: 4), materialTapTargetSize: MaterialTapTargetSize.shrinkWrap, - color: (_authMode == AuthMode.Login ? Color(0xff22c0e8) : Color(0xff57b22f)), + color: (_authMode == AuthMode.Login + ? Color(0xff22c0e8) + : Color(0xff57b22f)), textColor: Colors.white, ), - ], + ], + ), + SizedBox(height: 15), + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Expanded( + child: Container( + margin: EdgeInsets.only(left: 20, right: 10), + child: Divider( + thickness: 0.5, + color: Colors.white, + ), + ), + ), + Text('OR', + style: TextStyle(fontSize: 11, color: Colors.white70)), + Expanded( + child: Container( + margin: EdgeInsets.only(right: 20, left: 10), + child: Divider( + thickness: 0.5, + color: Colors.white, + ), + ), ), - SizedBox(height: 15), - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Expanded( - child: Container( - margin: EdgeInsets.only(left: 20, right: 10), - child: Divider(thickness: 0.5, color: Colors.white,), - ), - ), - Text('OR', style: TextStyle(fontSize: 11, color: Colors.white70)), - Expanded( - child: Container( - margin: EdgeInsets.only(right: 20, left: 10), - child: Divider(thickness: 0.5, color: Colors.white,), - ), - ), - ], - ), - SizedBox(height: 15), - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - MaterialButton( - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - color: Color(0xff2d67a5), - minWidth: 160, - onPressed: () {}, - child: Row( - children: [ - Icon(MdiIcons.facebook, size: 20, color: Colors.white), - Text("Login with Facebook", - textAlign: TextAlign.center, - style: TextStyle( - color: Colors.white, fontSize: 11)), - ], - ), - ), - - SizedBox(width: 10), - - MaterialButton( - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30.0), - ), - color: Colors.white, - minWidth: 160, - onPressed: () {}, - child: Row( - children: [ - Image.asset('assets/gmail.png', height: 12), - Text(" Login with Gmail", - textAlign: TextAlign.center, - style: TextStyle( - color: Color(0xff8997a7), fontSize: 11)), - ], - ), - ), - ], - ), - SizedBox(height: 70) ], ), - ), - + SizedBox(height: 15), + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + MaterialButton( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30.0), + ), + color: Color(0xff2d67a5), + minWidth: 160, + onPressed: () {}, + child: Row( + children: [ + Icon(MdiIcons.facebook, size: 20, color: Colors.white), + Text("Login with Facebook", + textAlign: TextAlign.center, + style: TextStyle(color: Colors.white, fontSize: 11)), + ], + ), + ), + SizedBox(width: 10), + MaterialButton( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30.0), + ), + color: Colors.white, + minWidth: 160, + onPressed: () {}, + child: Row( + children: [ + Image.asset('assets/gmail.png', height: 12), + Text(" Login with Gmail", + textAlign: TextAlign.center, + style: TextStyle( + color: Color(0xff8997a7), fontSize: 11)), + ], + ), + ), + ], + ), + SizedBox(height: 70) + ], + ), + ), ); } } diff --git a/lib/src/ui/auth/seeker/register_seeker.dart b/lib/src/ui/auth/seeker/register_seeker.dart deleted file mode 100644 index f864cf2..0000000 --- a/lib/src/ui/auth/seeker/register_seeker.dart +++ /dev/null @@ -1,233 +0,0 @@ -import 'package:flutter/material.dart'; - -class RegisterSeeker extends StatefulWidget { - - static const routeName = 'register_seeker'; - - @override - _RegisterSeekerState createState() => _RegisterSeekerState(); -} - -class _RegisterSeekerState extends State { -TextStyle style = TextStyle(fontFamily: 'VarelaRound'); - - @override - Widget build(BuildContext context) { - - final textBody = - Column(children: [ - Column(children: [ - Text("REGISTER AN ACCOUNT", - textAlign: TextAlign.center, - overflow: TextOverflow.ellipsis, - style: style.copyWith( - color: Color(0xff2c4057), fontSize: 12) - ), - ], - ), - Row(children: [ - Expanded( - child: new Container( - margin: const EdgeInsets.only(left: 70.0, right: 70.0), - child: Divider( - thickness: 2, - color: Color(0xff22c0e8), - height: 30)), - ) - ] - ) - ] - ); - - - final usernameField = TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Choose a Username", - hintStyle: style.copyWith(color: Color(0xff8997a7)), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final emailField = TextFormField( - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Enter Your Email Address", - hintStyle: style.copyWith(color: Color(0xff8997a7)), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final passwordField = new TextFormField( - obscureText: true, - style: style.copyWith( - - color: Colors.black45, - fontSize: 12, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Password", - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final confirmPassword = new TextFormField( - obscureText: true, - style: style.copyWith( - color: Colors.black45, - fontSize: 12, - fontStyle: FontStyle.normal, - letterSpacing: 0.25, - ), - decoration: new InputDecoration( - contentPadding: EdgeInsets.fromLTRB(30.0, 15.0, 30.0, 15.0), - hintText: "Confirm Password", - hintStyle: style.copyWith(color: Color(0xff8997a7), fontSize: 12), - filled: true, - fillColor: Color(0xffdcdfe3), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(30.0)), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(30.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - )), - validator: (value) => value.isEmpty ? 'Column can\'t be empty' : null - ); - - final regButton = Material( - elevation: 3.0, - borderRadius: BorderRadius.all(Radius.circular(50)), - color: Color(0xff22c0e8), - child: MaterialButton( - padding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), - onPressed: () { - // showDialog( - // context: context,builder: (_) => FlareGiffyDialog( - // flarePath: 'assets/space_demo.flr', - // flareAnimation: 'loading', - // title: Text('Sedang Loading', - // style: style.copyWith( - // fontSize: 22.0, fontWeight: FontWeight.w500), - // ), - // description: Text('Silahkan tunggu...', - // textAlign: TextAlign.center, - // style: style.copyWith(), - // ), - // onOkButtonPressed: () {}, - // ) ); - }, - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Text('Register Now', - textAlign: TextAlign.center, - style: style.copyWith( - - color: Color(0xffffffff), - fontSize: 14, - fontWeight: FontWeight.w500, - ) - ), - Icon(Icons.arrow_forward, color: Colors.white, size: 18,), - ], - ), - ), - ); - -return LayoutBuilder( - builder: (BuildContext context, BoxConstraints viewportConstraints) { - return Scaffold( - body: SingleChildScrollView( - child: ConstrainedBox( - constraints: BoxConstraints( - minHeight: viewportConstraints.maxHeight, - ), - child: Container( - padding: EdgeInsets.only(left: 60, right: 60, bottom: 30), - child: Column( - mainAxisAlignment: MainAxisAlignment.end, - mainAxisSize: MainAxisSize.max, - children: [ - textBody, - SizedBox( - height: 10.0, - ), - usernameField, - SizedBox( - height: 25.0), - emailField, - SizedBox( - height: 25.0), - passwordField, - SizedBox( - height: 25.0), - confirmPassword, - SizedBox( - height: 25.0, - ), - regButton, - SizedBox( - height: 15.0, - ), - Text("LOGIN TO YOUR EXISTING ACCOUNT", - style: style.copyWith( - color: Color(0xff8997a7), - fontSize: 9, - - fontStyle: FontStyle.normal, - letterSpacing: 0.55, - ) - ), - SizedBox( - height: 50.0, - ), - ], - - ), - ), - ), - ), - ); - } - ); - } - } diff --git a/lib/src/ui/auth/seeker/ui_get_started_seeker.dart b/lib/src/ui/auth/seeker/ui_get_started_seeker.dart index b0bd8d7..76cd991 100644 --- a/lib/src/ui/auth/seeker/ui_get_started_seeker.dart +++ b/lib/src/ui/auth/seeker/ui_get_started_seeker.dart @@ -1,60 +1,92 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:space/navigator_employer.dart'; import 'package:space/navigator_seeker.dart'; class UiGetStartedSeeker extends StatelessWidget { - + static const routeName = '/ui-seeker'; @override - Widget build(BuildContext context) { - TextStyle style = TextStyle(fontFamily: 'Quicksand-Regular', fontSize: 20.0); - return Scaffold( - body: Padding( - padding: EdgeInsets.fromLTRB(40, 50, 40, 50), - child: Container( + Widget build(BuildContext context) { + TextStyle style = + TextStyle(fontFamily: 'Quicksand-Regular', fontSize: 20.0, color: Colors.white); + return Stack( + children: [ + SvgPicture.asset( + 'assets/vector-5.svg', + height: MediaQuery.of(context).size.height, + width: MediaQuery.of(context).size.width, + fit: BoxFit.fill, + ), + Scaffold( + backgroundColor: Colors.transparent, + body: Container( + padding: EdgeInsets.symmetric(horizontal: 20, vertical: 10), height: MediaQuery.of(context).size.height, child: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, + mainAxisAlignment: MainAxisAlignment.end, children: [ - Container( - padding: EdgeInsets.symmetric(horizontal: 60), - child: Image.asset('assets/logo_vertical.png') - ), - Text('Are you ready to chase your dreams?', - textAlign: TextAlign.center, - style: style.copyWith(fontSize: 40, color: Color(0xff3b3b3b), fontWeight: FontWeight.bold)), - Text('Make your dreams come true by start working. Find jobs which suit you. Easy to apply, no paper, no writing. Just type and upload.', - textAlign: TextAlign.center, - style: style.copyWith(fontSize: 17.2, color: Color(0x99383839), fontWeight: FontWeight.w600)), - ButtonTheme( - minWidth: 190, - height: 55, - child: RaisedButton( - color: Color(0xff57b22f), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => SeekerNavigator())); - }, - child: Text('Get Started', style: style.copyWith(fontSize: 24, color: Colors.white, fontWeight: FontWeight.bold)), - ), - ), - ButtonTheme( - minWidth: 190, - height: 55, - child: OutlineButton( - highlightedBorderColor: Color(0xff57b22f), - borderSide: BorderSide(color: Color(0xff57b22f)), - onPressed: () { Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => SeekerNavigator())); - }, - child: Text('Try Trial', style: style.copyWith(fontSize: 24, color: Color(0xff57b22f), fontWeight: FontWeight.bold)), - ), - ), + Container( + child: Image.asset('assets/logo.png', height: 150,)), + Text('Are you ready to chase your dreams?', + textAlign: TextAlign.center, + style: style.copyWith( + fontSize: 32, + color: Colors.white, + fontWeight: FontWeight.bold)), + SizedBox(height: 30), + Text( + 'Make your dreams come true by start working. Find jobs which suit you. Easy to apply, no paper, no writing. Just type and upload.', + textAlign: TextAlign.center, + style: style.copyWith( + fontSize: 16, + color: Colors.white, + fontWeight: FontWeight.w600)), + SizedBox(height: 50), + ButtonTheme( + minWidth: 190, + height: 55, + child: RaisedButton( + color: Color(0xff57b22f), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => + SeekerNavigator())); + }, + child: Text('Get Started', + style: style.copyWith( + fontSize: 24, + color: Colors.white, + fontWeight: FontWeight.bold)), + ), + ), + SizedBox(height: 20), + ButtonTheme( + minWidth: 190, + height: 55, + child: OutlineButton( + highlightedBorderColor: Colors.white, + borderSide: BorderSide(color: Colors.white), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (BuildContext context) => + SeekerNavigator())); + }, + child: Text('Try Trial', + style: style.copyWith( + fontSize: 24, + color: Colors.white, + fontWeight: FontWeight.bold)), + ), + ), ], ), ), - ), + ), + ], ); } -} \ No newline at end of file +} diff --git a/lib/src/ui/chat/inbox_ui_chat.dart b/lib/src/ui/chat/inbox_ui_chat.dart index c43cdfb..e8e81f2 100644 --- a/lib/src/ui/chat/inbox_ui_chat.dart +++ b/lib/src/ui/chat/inbox_ui_chat.dart @@ -1,299 +1,518 @@ import 'package:flutter/material.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; +import 'package:space/src/ui/chat/video_ui_calling.dart'; - -class InboxUiList extends StatefulWidget { - const InboxUiList({ Key key, String title }) : super(key: key); - @override - _InboxUiListState createState() => _InboxUiListState(); -} - -class _InboxUiListState extends State with SingleTickerProviderStateMixin { - - - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); - +class InboxUiChat extends StatelessWidget { @override Widget build(BuildContext context) { - - return new Scaffold( - backgroundColor: Colors.white, + TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); + return Scaffold( appBar: AppBar( automaticallyImplyLeading: true, leading: IconButton( - onPressed: () { - Navigator.pop(context,true); - }, - icon: Icon(FeatherIcons.chevronLeft, color: Color(0xff2c4057), size: 16)), + onPressed: () { + Navigator.pop(context, true); + }, + icon: Icon(FeatherIcons.chevronLeft, + color: Color(0xff2c4057), size: 14)), elevation: 1, backgroundColor: Colors.white, - title: Row(children:[ + title: Row( + children: [ Stack( alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-2.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-2.png', + scale: 3.3, + ), ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xff81c784)), - ), - - ], + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + Container( + padding: EdgeInsets.only(left: 20), + child: Text('Mekuru Ramen', + style: style.copyWith( + color: Color(0xff2c4057), + fontSize: 14, + fontWeight: FontWeight.w600, + letterSpacing: 1)), ), - Container( - padding: EdgeInsets.only(left: 20), - child:Text('Mekuru Ramen', style: style.copyWith(color: Color(0xff2c4057), - fontSize: 18, fontWeight: FontWeight.w600,letterSpacing: 1)), - ), ], ), centerTitle: true, actions: [ - // action button - IconButton( - icon: Icon(Icons.videocam, color: Color(0xff4d4d4d), size: 33), - onPressed: () {}, - ), - ], - ), - body: SingleChildScrollView( - child: Container( - margin: EdgeInsets.only(top: 15), - child: Column( - children: [ - Stack( - children: [ - Container( - alignment: AlignmentDirectional.topEnd, - margin: EdgeInsets.fromLTRB(0, 10, 15, 0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - new Container( - width: 350, - padding: EdgeInsets.fromLTRB(35, 15, 15, 15), - margin: EdgeInsets.only(bottom: 5), - decoration: new BoxDecoration( - color: Color(0xffffffff), - borderRadius: BorderRadius.circular(5), - boxShadow: [BoxShadow( - color: Color(0x11000000), - offset: Offset(2.121320343559643,2.1213203435596424), - blurRadius: 21, - spreadRadius: 0 - ) ], - ), - child: Column( - children: [ - Text('Hello, nice to see you again today. Hope you are well.', - style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - - ], + // action button + IconButton( + icon: Icon(Icons.videocam, color: Color(0xff4d4d4d), size: 33), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + Calling())); + }, ), - ), - Text('03:41 PM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), ], - ), - ), - Stack( - alignment: AlignmentDirectional.topStart, - children: [ - Container(), - Container( - margin: EdgeInsets.only(top: 20, left: 30), - child: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-2.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, - ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xff81c784)), - ), - ], - ), - ), - ], - ), - ], - ), - - Stack( - children: [ - Container( - alignment: AlignmentDirectional.topStart, - margin: EdgeInsets.fromLTRB(10, 10, 0, 0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.end, - children: [ - new Container( - width: 350, - padding: EdgeInsets.fromLTRB(15, 15, 35, 15), - margin: EdgeInsets.only(bottom: 5), - decoration: new BoxDecoration( - color: Color(0xffffffff), - borderRadius: BorderRadius.circular(5), - boxShadow: [BoxShadow( - color: Color(0x11000000), - offset: Offset(2.121320343559643,2.1213203435596424), - blurRadius: 21, - spreadRadius: 0 - ) ], - ), + ), + body: SingleChildScrollView( + child: Container( + margin: EdgeInsets.only(top: 15, bottom: 80), child: Column( - children: [ - Text('This is my office location. You can visit as per your time.', - style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - new Container( - height: 200, - decoration: new BoxDecoration( - color: Color(0xffbdbdbd), - boxShadow: [BoxShadow( - color: Color(0x11000000), - offset: Offset(2.121320343559643,2.1213203435596424), - blurRadius: 21, - spreadRadius: 0 - ) ], - ) - ), - ], - ), - ), - Text('03:42 PM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), - ], - ), - ), - Stack( - alignment: AlignmentDirectional.topEnd, children: [ - Container(), - Container( - margin: EdgeInsets.only(top: 20, right: 30), - child: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-1.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, - ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xff81c784)), - ), - ], - ), - ), - ], - ), - ], - ), - - Stack( - children: [ - Container( - alignment: AlignmentDirectional.topEnd, - margin: EdgeInsets.fromLTRB(0, 10, 15, 0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - new Container( - width: 350, - padding: EdgeInsets.fromLTRB(35, 15, 15, 15), - margin: EdgeInsets.only(bottom: 5), - decoration: new BoxDecoration( - color: Color(0xffffffff), - borderRadius: BorderRadius.circular(5), - boxShadow: [BoxShadow( - color: Color(0x11000000), - offset: Offset(2.121320343559643,2.1213203435596424), - blurRadius: 21, - spreadRadius: 0 - ) ], - ), - child: Column( - children: [ - Text('Sure, I will visit the location in evening. Is that alright for you.', - style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - + Stack( + children: [ + Container( + alignment: AlignmentDirectional.topEnd, + margin: EdgeInsets.fromLTRB(0, 10, 15, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Container( + padding: EdgeInsets.fromLTRB(40, 10, 10, 10), + margin: EdgeInsets.only(bottom: 5, left: 38), + decoration: BoxDecoration( + color: Color(0xffffffff), + borderRadius: BorderRadius.circular(5), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset( + 2.121320343559643, 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + ), + child: Column( + children: [ + Text( + 'Hello, nice to see you again today. Hope you are well.', + style: style.copyWith( + fontSize: 14, color: Color(0xff757575))), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 38), + child: Text('03:41 PM', + style: style.copyWith( + fontSize: 12, color: Color(0xff757575))), + ), + ], + ), + ), + Stack( + alignment: AlignmentDirectional.topStart, + children: [ + Container(), + Container( + margin: EdgeInsets.only(top: 20, left: 20), + child: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-2.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + ), + ], + ), + ], + ), + Stack( + children: [ + Container( + alignment: AlignmentDirectional.topStart, + margin: EdgeInsets.fromLTRB(15, 10, 0, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.end, + children: [ + Container( + padding: EdgeInsets.fromLTRB(10, 10, 40, 10), + margin: EdgeInsets.only(bottom: 5, right: 38), + decoration: BoxDecoration( + color: Color(0xffffffff), + borderRadius: BorderRadius.circular(5), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset( + 2.121320343559643, 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + ), + child: Column( + children: [ + Text( + 'This is my office location. You can visit as per your time.', + style: style.copyWith( + fontSize: 14, color: Color(0xff757575))), + Container( + height: 200, + decoration: BoxDecoration( + color: Color(0xffbdbdbd), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset(2.121320343559643, + 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + )), + ], + ), + ), + Padding( + padding: EdgeInsets.only(right: 38), + child: Text('03:42 PM', + style: style.copyWith( + fontSize: 12, color: Color(0xff757575)))), + ], + ), + ), + Stack( + alignment: AlignmentDirectional.topEnd, + children: [ + Container(), + Container( + margin: EdgeInsets.only(top: 20, right: 20), + child: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-1.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + ), + ], + ), + ], + ), + Stack( + children: [ + Container( + alignment: AlignmentDirectional.topEnd, + margin: EdgeInsets.fromLTRB(0, 10, 15, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Container( + + padding: EdgeInsets.fromLTRB(40, 10, 10, 10), + margin: EdgeInsets.only(bottom: 5, left: 38), + decoration: BoxDecoration( + color: Color(0xffffffff), + borderRadius: BorderRadius.circular(5), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset( + 2.121320343559643, 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + ), + child: Column( + children: [ + Text( + 'Sure, I will visit the location in evening. Is that alright for you.', + style: style.copyWith( + fontSize: 14, color: Color(0xff757575))), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 38), + child: Text('03:43 PM', + style: style.copyWith( + fontSize: 12, color: Color(0xff757575)))), + ], + ), + ), + Stack( + alignment: AlignmentDirectional.topStart, + children: [ + Container(), + Container( + margin: EdgeInsets.only(top: 20, left: 20), + child: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-2.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + ), + ], + ), + ], + ), + Stack( + children: [ + Container( + alignment: AlignmentDirectional.topStart, + margin: EdgeInsets.fromLTRB(15, 10, 0, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.end, + children: [ + Container( + padding: EdgeInsets.fromLTRB(10, 10, 40, 10), + margin: EdgeInsets.only(bottom: 5, right: 38), + decoration: BoxDecoration( + color: Color(0xffffffff), + borderRadius: BorderRadius.circular(5), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset( + 2.121320343559643, 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + ), + child: Column( + children: [ + Text( + 'This is my office location. You can visit as per your time.', + style: style.copyWith( + fontSize: 14, color: Color(0xff757575))), + Container( + height: 200, + decoration: BoxDecoration( + color: Color(0xffbdbdbd), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset(2.121320343559643, + 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + )), + ], + ), + ), + Padding( + padding: EdgeInsets.only(right: 38), + child: Text('03:44 PM', + style: style.copyWith( + fontSize: 12, color: Color(0xff757575)))), + ], + ), + ), + Stack( + alignment: AlignmentDirectional.topEnd, + children: [ + Container(), + Container( + margin: EdgeInsets.only(top: 20, right: 20), + child: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-1.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + ), + ], + ), + ], + ), + Stack( + children: [ + Container( + alignment: AlignmentDirectional.topEnd, + margin: EdgeInsets.fromLTRB(0, 10, 15, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Container( + + padding: EdgeInsets.fromLTRB(40, 10, 10, 10), + margin: EdgeInsets.only(bottom: 5, left: 38), + decoration: BoxDecoration( + color: Color(0xffffffff), + borderRadius: BorderRadius.circular(5), + boxShadow: [ + BoxShadow( + color: Color(0x11000000), + offset: Offset( + 2.121320343559643, 2.1213203435596424), + blurRadius: 21, + spreadRadius: 0) + ], + ), + child: Column( + children: [ + Text( + 'Sure, I will visit the location in evening. Is that alright for you.', + style: style.copyWith( + fontSize: 14, color: Color(0xff757575))), + ], + ), + ), + Padding( + padding: EdgeInsets.only(left: 38), + child: Text('03:44 PM', + style: style.copyWith( + fontSize: 12, color: Color(0xff757575)))), + ], + ), + ), + Stack( + alignment: AlignmentDirectional.topStart, + children: [ + Container(), + Container( + margin: EdgeInsets.only(top: 20, left: 20), + child: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-2.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + ), + ], + ), + ], + ), ], ), - ), - Text('03:43 PM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), - ], - ), - ), - Stack( - alignment: AlignmentDirectional.topStart, - children: [ - Container(), - Container( - margin: EdgeInsets.only(top: 20, left: 30), - child: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-2.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, - ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xff81c784)), - ), - ], - ), - ), - ], - ), - ], - ), - - ], - ), + ), ), + floatingActionButton: Padding( + padding: EdgeInsets.only(left: 30.0), + child: Row( + children: [ + Expanded( + child: Material( + elevation: 1, + borderRadius: BorderRadius.circular(20.0), + child: Container( + child: Row( + children: [ + SizedBox(width: 8.0), + Icon(Icons.insert_emoticon, + size: 25.0, color: Theme.of(context).hintColor), + SizedBox(width: 8.0), + Expanded( + child: TextField( + style: TextStyle(fontSize: 14, color: Color(0xff757575)), + textInputAction: TextInputAction.newline, + decoration: InputDecoration( + hintText: 'Type a message', + hintStyle: TextStyle(fontSize: 14, color: Colors.black26), + border: InputBorder.none, + ), + ), + ), + Icon(Icons.attach_file, + size: 25.0, color: Theme.of(context).hintColor), + SizedBox(width: 8.0), + Icon(Icons.camera_alt, + size: 25.0, color: Theme.of(context).hintColor), + SizedBox(width: 8.0), + ], ), - floatingActionButton: Container( - padding: EdgeInsets.fromLTRB(40, 10, 10, 0), - child: new TextField( - style: style.copyWith(fontSize: 16, color: Color(0xff757575)), - decoration: new InputDecoration( - suffixIcon: Padding( - padding: const EdgeInsetsDirectional.only(end: 12.0), - child: Icon(Icons.place), - ), - - border: new OutlineInputBorder( - borderRadius: const BorderRadius.all( - const Radius.circular(100.0), ), + ), +), + SizedBox( + width: 5.0, ), - filled: true, - hintStyle: style.copyWith(color: Color(0xffaaaaaa), fontSize: 16), - hintText: "Message", - fillColor: Colors.white), + GestureDetector( + onTap: () {}, + child: CircleAvatar( + child: Icon(Icons.send, size: 20,), + ), ), - ), - - + ], + ), +), ); } -} \ No newline at end of file +} diff --git a/lib/src/ui/chat/inbox_ui_empty.dart b/lib/src/ui/chat/inbox_ui_empty.dart index 018b41c..992042c 100644 --- a/lib/src/ui/chat/inbox_ui_empty.dart +++ b/lib/src/ui/chat/inbox_ui_empty.dart @@ -1,345 +1,30 @@ -// import 'package:flutter/material.dart'; -// import 'dart:async'; - -// import 'package:agora_rtm/agora_rtm.dart'; - - -// class InboxNoMessage extends StatefulWidget { -// @override -// _InboxNoMessageState createState() => _InboxNoMessageState(); -// } - -// class _InboxNoMessageState extends State with SingleTickerProviderStateMixin { - -// TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); -// bool _isLogin = false; -// bool _isInChannel = false; - -// final _userNameController = TextEditingController(); -// final _peerUserIdController = TextEditingController(); -// final _peerMessageController = TextEditingController(); -// final _channelNameController = TextEditingController(); -// final _channelMessageController = TextEditingController(); - -// final _infoStrings = []; - -// AgoraRtmClient _client; -// AgoraRtmChannel _channel; - -// @override -// void initState() { -// super.initState(); -// _createClient(); -// } - -// @override -// Widget build(BuildContext context) { - -// return new Scaffold( -// backgroundColor: Colors.white, -// body: Container( -// padding: EdgeInsets.only(top: 50, left: 30, right: 30), -// child: Column( -// children: [ -// _buildLogin(), -// _buildQueryOnlineStatus(), -// _buildSendPeerMessage(), -// _buildJoinChannel(), -// _buildGetMembers(), -// _buildSendChannelMessage(), -// _buildInfoList(), -// ], -// ), - -// ), -// ); -// } - - -// void _createClient() async { -// _client = -// await AgoraRtmClient.createInstance('6389279af2b74d949734539ba2fb66d8'); -// _client.onMessageReceived = (AgoraRtmMessage message, String peerId) { -// _log("Peer msg: " + peerId + ", msg: " + message.text); -// }; -// _client.onConnectionStateChanged = (int state, int reason) { -// _log('Connection state changed: ' + -// state.toString() + -// ', reason: ' + -// reason.toString()); -// if (state == 5) { -// _client.logout(); -// _log('Logout.'); -// setState(() { -// _isLogin = false; -// }); -// } -// }; -// } - -// Future _createChannel(String name) async { -// AgoraRtmChannel channel = await _client.createChannel(name); -// channel.onMemberJoined = (AgoraRtmMember member) { -// _log( -// "Member joined: " + member.userId + ', channel: ' + member.channelId); -// }; -// channel.onMemberLeft = (AgoraRtmMember member) { -// _log("Member left: " + member.userId + ', channel: ' + member.channelId); -// }; -// channel.onMessageReceived = -// (AgoraRtmMessage message, AgoraRtmMember member) { -// _log("Channel msg: " + member.userId + ", msg: " + message.text); -// }; -// return channel; -// } - -// static TextStyle textStyle = TextStyle(fontSize: 18, color: Colors.blue); - -// Widget _buildLogin() { -// return Row(children: [ -// _isLogin -// ? new Expanded( -// child: new Text('User Id: ' + _userNameController.text, -// style: textStyle)) -// : new Expanded( -// child: new TextField( -// controller: _userNameController, -// decoration: InputDecoration(hintText: 'Input your user id'))), -// new OutlineButton( -// child: Text(_isLogin ? 'Logout' : 'Login', style: textStyle), -// onPressed: _toggleLogin, -// ) -// ]); -// } - -// Widget _buildQueryOnlineStatus() { -// if (!_isLogin) { -// return Container(); -// } -// return Row(children: [ -// new Expanded( -// child: new TextField( -// controller: _peerUserIdController, -// decoration: InputDecoration(hintText: 'Input peer user id'))), -// new OutlineButton( -// child: Text('Query Online', style: textStyle), -// onPressed: _toggleQuery, -// ) -// ]); -// } - -// Widget _buildSendPeerMessage() { -// if (!_isLogin) { -// return Container(); -// } -// return Row(children: [ -// new Expanded( -// child: new TextField( -// controller: _peerMessageController, -// decoration: InputDecoration(hintText: 'Input peer message'))), -// new OutlineButton( -// child: Text('Send to Peer', style: textStyle), -// onPressed: _toggleSendPeerMessage, -// ) -// ]); -// } - -// Widget _buildJoinChannel() { -// if (!_isLogin) { -// return Container(); -// } -// return Row(children: [ -// _isInChannel -// ? new Expanded( -// child: new Text('Channel: ' + _channelNameController.text, -// style: textStyle)) -// : new Expanded( -// child: new TextField( -// controller: _channelNameController, -// decoration: InputDecoration(hintText: 'Input channel id'))), -// new OutlineButton( -// child: Text(_isInChannel ? 'Leave Channel' : 'Join Channel', -// style: textStyle), -// onPressed: _toggleJoinChannel, -// ) -// ]); -// } - -// Widget _buildSendChannelMessage() { -// if (!_isLogin || !_isInChannel) { -// return Container(); -// } -// return Row(children: [ -// new Expanded( -// child: new TextField( -// controller: _channelMessageController, -// decoration: InputDecoration(hintText: 'Input channel message'))), -// new OutlineButton( -// child: Text('Send to Channel', style: textStyle), -// onPressed: _toggleSendChannelMessage, -// ) -// ]); -// } - -// Widget _buildGetMembers() { -// if (!_isLogin || !_isInChannel) { -// return Container(); -// } -// return Row(children: [ -// new OutlineButton( -// child: Text('Get Members in Channel', style: textStyle), -// onPressed: _toggleGetMembers, -// ) -// ]); -// } - -// Widget _buildInfoList() { -// return Expanded( -// child: Container( -// child: ListView.builder( -// itemExtent: 24, -// itemBuilder: (context, i) { -// return ListTile( -// contentPadding: const EdgeInsets.all(0.0), -// title: Text(_infoStrings[i]), -// ); -// }, -// itemCount: _infoStrings.length, -// ))); -// } - -// void _toggleLogin() async { -// if (_isLogin) { -// try { -// await _client.logout(); -// _log('Logout success.'); - -// setState(() { -// _isLogin = false; -// _isInChannel = false; -// }); -// } catch (errorCode) { -// _log('Logout error: ' + errorCode.toString()); -// } -// } else { -// String userId = _userNameController.text; -// if (userId.isEmpty) { -// _log('Please input your user id to login.'); -// return; -// } - -// try { -// await _client.login(null, userId); -// _log('Login success: ' + userId); -// setState(() { -// _isLogin = true; -// }); -// } catch (errorCode) { -// _log('Login error: ' + errorCode.toString()); -// } -// } -// } - -// void _toggleQuery() async { -// String peerUid = _peerUserIdController.text; -// if (peerUid.isEmpty) { -// _log('Please input peer user id to query.'); -// return; -// } -// try { -// Map result = -// await _client.queryPeersOnlineStatus([peerUid]); -// _log('Query result: ' + result.toString()); -// } catch (errorCode) { -// _log('Query error: ' + errorCode.toString()); -// } -// } - -// void _toggleSendPeerMessage() async { -// String peerUid = _peerUserIdController.text; -// if (peerUid.isEmpty) { -// _log('Please input peer user id to send message.'); -// return; -// } - -// String text = _peerMessageController.text; -// if (text.isEmpty) { -// _log('Please input text to send.'); -// return; -// } - -// try { -// AgoraRtmMessage message = AgoraRtmMessage.fromText(text); -// _log(message.text); -// await _client.sendMessageToPeer(peerUid, message, false); -// _log('Send peer message success.'); -// } catch (errorCode) { -// _log('Send peer message error: ' + errorCode.toString()); -// } -// } - -// void _toggleJoinChannel() async { -// if (_isInChannel) { -// try { -// await _channel.leave(); -// _log('Leave channel success.'); -// _client.releaseChannel(_channel.channelId); -// _channelMessageController.text = null; - -// setState(() { -// _isInChannel = false; -// }); -// } catch (errorCode) { -// _log('Leave channel error: ' + errorCode.toString()); -// } -// } else { -// String channelId = _channelNameController.text; -// if (channelId.isEmpty) { -// _log('Please input channel id to join.'); -// return; -// } - -// try { -// _channel = await _createChannel(channelId); -// await _channel.join(); -// _log('Join channel success.'); - -// setState(() { -// _isInChannel = true; -// }); -// } catch (errorCode) { -// _log('Join channel error: ' + errorCode.toString()); -// } -// } -// } - -// void _toggleGetMembers() async { -// try { -// List members = await _channel.getMembers(); -// _log('Members: ' + members.toString()); -// } catch (errorCode) { -// _log('GetMembers failed: ' + errorCode.toString()); -// } -// } - -// void _toggleSendChannelMessage() async { -// String text = _channelMessageController.text; -// if (text.isEmpty) { -// _log('Please input text to send.'); -// return; -// } -// try { -// await _channel.sendMessage(AgoraRtmMessage.fromText(text)); -// _log('Send channel message success.'); -// } catch (errorCode) { -// _log('Send channel message error: ' + errorCode.toString()); -// } -// } - -// void _log(String info) { -// print(info); -// setState(() { -// _infoStrings.insert(0, info); -// }); -// } -// } +import 'package:flutter/material.dart'; + +class InboxNoMessage extends StatelessWidget { + @override + Widget build(BuildContext context) { + TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); + return new Scaffold( + backgroundColor: Colors.white, + body: Container( + padding: EdgeInsets.only(top: 50, left: 30, right: 30), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Inbox', style: style.copyWith(fontSize: 32, fontWeight: FontWeight.w600, color: Color(0xff3b3b3b))), + Text('Information and message will appear here.', style: style.copyWith(fontSize: 15, fontWeight: FontWeight.w600)), + Stack( + children: [ + Container( + margin: EdgeInsets.only(top: 100), + child: Image.asset('assets/vector-2.png'), + ), + ], + ), + + ] + ), + ), + ); + } +} \ No newline at end of file diff --git a/lib/src/ui/chat/inbox_ui_list.dart b/lib/src/ui/chat/inbox_ui_list.dart index 4f255ae..52b0874 100644 --- a/lib/src/ui/chat/inbox_ui_list.dart +++ b/lib/src/ui/chat/inbox_ui_list.dart @@ -1,136 +1,159 @@ import 'package:flutter/material.dart'; - +import 'package:space/src/ui/chat/inbox_ui_chat.dart'; +import 'package:space/src/ui/seeker/layout/seeker_profile_view.dart'; class InboxUiList extends StatefulWidget { - @override _InboxUiListState createState() => _InboxUiListState(); } -class _InboxUiListState extends State with SingleTickerProviderStateMixin { - - - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); - +class _InboxUiListState extends State + with SingleTickerProviderStateMixin { @override Widget build(BuildContext context) { - return Scaffold( - backgroundColor: Colors.white, - body: Container( - padding: EdgeInsets.only(top: 50, left: 30, right: 30), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text('Inbox', style: style.copyWith(fontSize: 32, fontWeight: FontWeight.w600, color: Color(0xff3b3b3b))), - - SingleChildScrollView( - child:Container( - child: Column(children: [ - - SizedBox( - height: 30, - ), - ListTile( - leading: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-1.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, - ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xff81c784)), + body: Container( + margin: EdgeInsets.only(top: 20), + child: ListView( + children: [ + Padding( + padding: EdgeInsets.symmetric(horizontal: 15, vertical: 10), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Inbox', + style: TextStyle( + fontSize: 32, + fontWeight: FontWeight.bold, + color: Color(0xff3b3b3b))), + ], ), - - ], ), - title: Text('Mekuru Ramen', style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - subtitle: Text('Hello, New job offers for you', style: style.copyWith(fontSize: 14, color: Color(0xff757575))), - trailing: Text('03:57 AM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), - ), - - Container( + Padding( + padding: const EdgeInsets.symmetric(horizontal: 10), + child: ListTile( + leading: Stack( + alignment: Alignment(1, -1), + children: [ + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => SeekerProfileView())); + }, + child: CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-1.png', + scale: 3.3, + ), + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xff81c784)), + ), + ], + ), + title: Text('Mekuru Ramen', + style: TextStyle(fontSize: 16, color: Color(0xff757575))), + subtitle: Text('Hello, New job offers for you', + style: TextStyle(fontSize: 14, color: Color(0xff757575))), + trailing: Text('03:57 AM', + style: TextStyle(fontSize: 12, color: Color(0xff757575))), + onTap: () { + Navigator.push(context, + MaterialPageRoute(builder: (context) => InboxUiChat())); + }), + ), + Container( height: 30, padding: EdgeInsets.symmetric(horizontal: 17), - child: Divider( - color: Color(0xffc9c8c8) - ), - ), - - ListTile( - leading: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-1.png', scale: 3.3,), + child: Divider(color: Color(0xffc9c8c8)), ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, + Padding( + padding: const EdgeInsets.symmetric(horizontal: 10), + child: ListTile( + leading: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-1.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xfffca467)), + ), + ], ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xfffca467)), + title: Text('Diamonds Group', + style: TextStyle(fontSize: 16, color: Color(0xff757575))), + subtitle: Text('Hello, New job offers for you', + style: TextStyle(fontSize: 14, color: Color(0xff757575))), + trailing: Text('03:57 AM', + style: TextStyle(fontSize: 12, color: Color(0xff757575))), ), - - ], ), - title: Text('Diamonds Group', style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - subtitle: Text('Hello, New job offers for you', style: style.copyWith(fontSize: 14, color: Color(0xff757575))), - trailing: Text('03:57 AM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), - ), - - Container( + Container( height: 30, padding: EdgeInsets.symmetric(horizontal: 17), - child: Divider( - color: Color(0xffc9c8c8) - ), + child: Divider(color: Color(0xffc9c8c8)), ), - - ListTile( - leading: Stack( - alignment: Alignment(1, -1), - children:[ - CircleAvatar( - backgroundColor: Color(0xff757575), - radius: 20.0, - child: Image.asset('assets/img_profile-1.png', scale: 3.3,), - ), - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(20), - color: Colors.white, + Padding( + padding: const EdgeInsets.symmetric(horizontal: 10), + child: ListTile( + leading: Stack( + alignment: Alignment(1, -1), + children: [ + CircleAvatar( + backgroundColor: Color(0xff757575), + radius: 20.0, + child: Image.asset( + 'assets/img_profile-1.png', + scale: 3.3, + ), + ), + Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + color: Colors.white, + ), + child: Icon(Icons.brightness_1, + size: 10, color: Color(0xfffc6767)), + ), + ], ), - child: Icon(Icons.brightness_1, size: 10, color: Color(0xfffc6767)), + title: Text('Pull n Beat', + style: TextStyle(fontSize: 16, color: Color(0xff757575))), + subtitle: Text('Hello, New job offers for you', + style: TextStyle(fontSize: 14, color: Color(0xff757575))), + trailing: Text('03:57 AM', + style: TextStyle(fontSize: 12, color: Color(0xff757575))), ), - - ], ), - title: Text('Pull n Beat', style: style.copyWith(fontSize: 16, color: Color(0xff757575))), - subtitle: Text('Hello, New job offers for you', style: style.copyWith(fontSize: 14, color: Color(0xff757575))), - trailing: Text('03:57 AM', style: style.copyWith(fontSize: 12, color: Color(0xff757575))), - ), - Container( + Container( height: 30, padding: EdgeInsets.symmetric(horizontal: 17), - child: Divider( - color: Color(0xffc9c8c8) - ), + child: Divider(color: Color(0xffc9c8c8)), ), - ], - ), - ), - ), - ],) - ), + ], + ), + ), ); } -} \ No newline at end of file +} diff --git a/lib/src/ui/chat/video_ongoing_call.dart b/lib/src/ui/chat/video_ongoing_call.dart index e395e8c..3862c3b 100644 --- a/lib/src/ui/chat/video_ongoing_call.dart +++ b/lib/src/ui/chat/video_ongoing_call.dart @@ -1,23 +1,5 @@ import 'package:flutter/material.dart'; -void main() { - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - - @override - Widget build(BuildContext context) { - return MaterialApp( - debugShowCheckedModeBanner: false, - theme: ThemeData( - ), - home: const Oncalling(), -); - } -} - - class Oncalling extends StatefulWidget { const Oncalling({ Key key, String title }) : super(key: key); @override diff --git a/lib/src/ui/chat/video_ui_calling.dart b/lib/src/ui/chat/video_ui_calling.dart index c048be5..096d53b 100644 --- a/lib/src/ui/chat/video_ui_calling.dart +++ b/lib/src/ui/chat/video_ui_calling.dart @@ -1,102 +1,98 @@ import 'package:flutter/material.dart'; - -void main() { - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - - @override - Widget build(BuildContext context) { - return MaterialApp( - debugShowCheckedModeBanner: false, - theme: ThemeData( - ), - home: const Calling(), -); - } -} - +import 'package:space/src/ui/chat/video_ongoing_call.dart'; +import 'package:space/src/ui/chat/video_ui_incoming.dart'; class Calling extends StatefulWidget { - const Calling({ Key key, String title }) : super(key: key); + const Calling({Key key, String title}) : super(key: key); @override _CallingState createState() => _CallingState(); } class _CallingState extends State with SingleTickerProviderStateMixin { + TextStyle style = + TextStyle(fontFamily: 'VarelaRound', fontSize: 18.0, color: Colors.white); - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 24.0, color: Colors.white); - @override Widget build(BuildContext context) { - - return new Scaffold( - body: Container( - width: MediaQuery.of(context).size.width, - height: MediaQuery.of(context).size.height, - decoration: BoxDecoration( - image: DecorationImage( - image: AssetImage('assets/background-2.png'), - colorFilter: new ColorFilter.mode(Colors.black.withOpacity(0.7), BlendMode.multiply), - fit: BoxFit.cover + return Scaffold( + appBar: AppBar( + actions: [ + RaisedButton( + child: Text('In Coming Call'), + onPressed: () { + Navigator.push(context, + MaterialPageRoute(builder: (context) => IncomingCall())); + }, ), - ), - child: Container( - margin: EdgeInsets.only(top: 80, bottom: 60), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Column( - children: [ - CircleAvatar( - backgroundColor: Colors.white, - radius: 80, - child: Image.asset('assets/mekuru_2.png', fit: BoxFit.cover), - ), - SizedBox( - height:20 - ), - Text('Mekuru Ramen', style: style.copyWith()), - SizedBox( - height:20 - ), - Text('contacting...', style: style.copyWith(fontSize: 18)), - ],), - Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - MaterialButton( - padding: EdgeInsets.all(20), - onPressed: (){}, - child: Icon(Icons.mic_off, color: Colors.white, size: 35), - color: Colors.transparent, - shape: CircleBorder(side: BorderSide(color: Colors.white)) - ), - MaterialButton( - padding: EdgeInsets.all(20), - onPressed: (){}, - child: Icon(Icons.call_end, color: Colors.white, size: 35), - color: Color(0xfffd2e61), - shape: CircleBorder() + RaisedButton( + child: Text('On Going Call'), + onPressed: () { + Navigator.push(context, + MaterialPageRoute(builder: (context) => Oncalling())); + }, + ), + ], + ), + body: Container( + width: MediaQuery.of(context).size.width, + height: MediaQuery.of(context).size.height, + decoration: BoxDecoration( + image: DecorationImage( + image: AssetImage('assets/background-2.png'), + colorFilter: new ColorFilter.mode( + Colors.black.withOpacity(0.7), BlendMode.multiply), + fit: BoxFit.cover), ), - MaterialButton( - padding: EdgeInsets.all(20), - onPressed: (){}, - child: Icon(Icons.volume_up, color: Colors.white, size: 35), - color: Colors.transparent, - shape: CircleBorder(side: BorderSide(color: Colors.white)) + child: Container( + margin: EdgeInsets.only(top: 80, bottom: 60), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Column( + children: [ + CircleAvatar( + backgroundColor: Colors.white, + radius: 60, + child: + Image.asset('assets/mekuru_2.png', fit: BoxFit.cover), + ), + SizedBox(height: 20), + Text('Mekuru Ramen', style: style.copyWith(fontSize: 20)), + SizedBox(height: 20), + Text('contacting...', style: style.copyWith(fontSize: 16)), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceAround, + children: [ + MaterialButton( + padding: EdgeInsets.all(20), + onPressed: () {}, + child: Icon(Icons.mic_off, color: Colors.white, size: 30), + color: Colors.transparent, + shape: + CircleBorder(side: BorderSide(color: Colors.white))), + MaterialButton( + padding: EdgeInsets.all(20), + onPressed: () {}, + child: + Icon(Icons.call_end, color: Colors.white, size: 30), + color: Color(0xfffd2e61), + shape: CircleBorder()), + MaterialButton( + padding: EdgeInsets.all(20), + onPressed: () {}, + child: + Icon(Icons.volume_up, color: Colors.white, size: 30), + color: Colors.transparent, + shape: + CircleBorder(side: BorderSide(color: Colors.white))), + ], + ), + ], + ), ), - ],), - - - - ],), ), - - ), - - ); } -} \ No newline at end of file +} diff --git a/lib/src/ui/chat/video_ui_incoming.dart b/lib/src/ui/chat/video_ui_incoming.dart index c0eed62..7b3468e 100644 --- a/lib/src/ui/chat/video_ui_incoming.dart +++ b/lib/src/ui/chat/video_ui_incoming.dart @@ -1,23 +1,5 @@ import 'package:flutter/material.dart'; -void main() { - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - - @override - Widget build(BuildContext context) { - return MaterialApp( - debugShowCheckedModeBanner: false, - theme: ThemeData( - ), - home: const IncomingCall(), -); - } -} - - class IncomingCall extends StatefulWidget { const IncomingCall({ Key key, String title }) : super(key: key); @override @@ -31,7 +13,7 @@ class _IncomingCallState extends State with SingleTickerProviderSt @override Widget build(BuildContext context) { - return new Scaffold( + return Scaffold( body: Container( width: MediaQuery.of(context).size.width, height: MediaQuery.of(context).size.height, diff --git a/lib/src/ui/components/category_job.dart b/lib/src/ui/components/category_job.dart new file mode 100644 index 0000000..e06bc97 --- /dev/null +++ b/lib/src/ui/components/category_job.dart @@ -0,0 +1,270 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:space/src/ui/components/category_list_screen.dart'; +import 'package:space/src/ui/components/category_post_screen.dart'; +import 'package:space/src/ui/seeker/screens/jobs_list_screen.dart'; + +class CategoryJob extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Container( + padding: EdgeInsets.symmetric(horizontal: 5, vertical: 5), + child: Row( + children: [ + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + children: [ + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/f&b.svg', + fit: BoxFit.fill, + ), + ), + ), + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Food & Beverages', + style: TextStyle( + fontSize: 14, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('5917 Jobs Available', + style: TextStyle( + fontSize: 10, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ), + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + children: [ + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/Fashion.svg', + fit: BoxFit.fill, + ), + ), + ), + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Fashion', + style: TextStyle( + fontSize: 14, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('2130 Jobs Available', + style: TextStyle( + fontSize: 10, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ), + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + children: [ + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/market-2.svg', + fit: BoxFit.fill, + ), + ), + ), + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Retail', + style: TextStyle( + fontSize: 14, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('2130 Jobs Available', + style: TextStyle( + fontSize: 10, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ), + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + children: [ + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/Corporate.svg', + fit: BoxFit.fill, + ), + ), + ), + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10), + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Corporate', + style: TextStyle( + fontSize: 14, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('2130 Jobs Available', + style: TextStyle( + fontSize: 10, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ), + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryListScreen())); + }, + child: Stack( + children: [ + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: ClipRRect( + borderRadius: new BorderRadius.circular(10), + child: SvgPicture.asset( + 'assets/others.svg', + fit: BoxFit.fill, + ), + ), + ), + Container( + height: 50, + width: 140, + margin: EdgeInsets.symmetric(horizontal: 5), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10), + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('More', + style: TextStyle( + fontSize: 14, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Icon(MdiIcons.dotsHorizontal, color: Colors.white,) + ], + ), + ), + ), + ], + ), + ), + ], + ), + ); + } +} diff --git a/lib/src/ui/components/category_job_screen.dart b/lib/src/ui/components/category_job_screen.dart new file mode 100644 index 0000000..1c9478c --- /dev/null +++ b/lib/src/ui/components/category_job_screen.dart @@ -0,0 +1,21 @@ +import 'package:flutter/material.dart'; +import 'package:provider/provider.dart'; + +import 'package:space/src/ui/components/category_job.dart'; + +class CategoryScreen extends StatefulWidget { + _CategoryScreenState createState() => _CategoryScreenState(); +} + +class _CategoryScreenState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Colors.transparent, + body: ListView( + scrollDirection: Axis.horizontal, + children: [CategoryJob()], + ), + ); + } +} diff --git a/lib/src/ui/components/category_list.dart b/lib/src/ui/components/category_list.dart new file mode 100644 index 0000000..7eaacb4 --- /dev/null +++ b/lib/src/ui/components/category_list.dart @@ -0,0 +1,398 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:space/src/ui/components/category_list_screen.dart'; +import 'package:space/src/ui/components/category_post_screen.dart'; +import 'package:space/src/ui/seeker/screens/jobs_list_screen.dart'; + +class CategoryList extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Container( + child: Column( + children: [ + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/f&b.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Food & Beverages', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('8570 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/Startup.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Startup', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('721 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/Corporate.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Corporate', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('2130 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/market-2.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Retails', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('6483 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/Goverment.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Goverment', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('823 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/IT.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('IT', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('2123 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/market.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Market', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('3523 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/Fashion.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Fashion', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('1373 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/Transport.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Transport', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('223 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + GestureDetector( + onTap: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => CategoryPostScreen())); + }, + child: Stack( + alignment: Alignment.center, + children: [ + Container( + height: 100, + child: SvgPicture.asset( + 'assets/DKV.svg', + fit: BoxFit.fill, + ), + ), + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Design', + style: TextStyle( + fontFamily: 'Roboto-Regular', + fontSize: 22, + color: Colors.white, + fontWeight: FontWeight.bold, + letterSpacing: 1)), + Text('3821 Jobs Available', + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Colors.white, + letterSpacing: 1)), + ], + ), + ], + ), + ), + ], + ), + ); + } +} diff --git a/lib/src/ui/components/category_list_screen.dart b/lib/src/ui/components/category_list_screen.dart new file mode 100644 index 0000000..52955ff --- /dev/null +++ b/lib/src/ui/components/category_list_screen.dart @@ -0,0 +1,51 @@ +import 'package:flutter/material.dart'; +import 'package:gradient_app_bar/gradient_app_bar.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:provider/provider.dart'; + +import 'package:space/src/ui/components/category_job.dart'; +import 'package:space/src/ui/components/category_list.dart'; + +class CategoryListScreen extends StatefulWidget { + _CategoryListScreenState createState() => _CategoryListScreenState(); +} + +class _CategoryListScreenState extends State { + @override + Widget build(BuildContext context) { + return Container( + decoration: BoxDecoration( + image: DecorationImage( + image: AssetImage('assets/vector-5.png'), + fit: BoxFit.cover + ), + ), + child: Scaffold( + backgroundColor: Colors.transparent, + appBar: PreferredSize( + preferredSize: Size.fromHeight(40), + child: AppBar( + backgroundColor: Colors.transparent, + automaticallyImplyLeading: false, + elevation: 0.0, + leading: IconButton( + onPressed: () { + Navigator.pop(context, true); + }, + icon: Icon(MdiIcons.chevronLeft, color: Colors.white, size: 16)), + title: Text('Category List', + style: TextStyle( + color: Colors.white, + fontSize: 14, + fontWeight: FontWeight.w500, + letterSpacing: 1, + )), + ), + ), + body: ListView( + children: [CategoryList()], + ), + ), + ); + } +} diff --git a/lib/src/ui/components/category_post_screen.dart b/lib/src/ui/components/category_post_screen.dart new file mode 100644 index 0000000..0bd8141 --- /dev/null +++ b/lib/src/ui/components/category_post_screen.dart @@ -0,0 +1,59 @@ +import 'package:flutter/material.dart'; +import 'package:gradient_app_bar/gradient_app_bar.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:provider/provider.dart'; + +import 'package:space/src/core/models/jobs.dart'; +import 'package:space/src/ui/seeker/layout/job_list.dart'; + +class CategoryPostScreen extends StatefulWidget { + _CategoryPostScreenState createState() => _CategoryPostScreenState(); +} + +class _CategoryPostScreenState extends State { + var _isLoading = false; + + @override + Widget build(BuildContext context) { + final jobData = Provider.of(context); + final jobs = jobData.posts; + return Scaffold( + backgroundColor: Colors.white, + appBar: PreferredSize( + preferredSize: Size.fromHeight(40), + child: AppBar( + automaticallyImplyLeading: false, + elevation: 1, + leading: IconButton( + onPressed: () { + Navigator.pop(context, true); + }, + icon: Icon(MdiIcons.chevronLeft, color: Color(0xff2c4057), size: 16)), + title: Text('Job List', + style: TextStyle( + color: Color(0xff2c4057), + fontSize: 14, + fontWeight: FontWeight.w500, + letterSpacing: 1, + )), + ), + ), + body: _isLoading + ? Center( + child: CircularProgressIndicator(), + ) + : ListView.builder( + itemCount: jobs.length, + itemBuilder: (ctx, i) => ChangeNotifierProvider.value( + // builder: (c) => jobs[i], + value: jobs[i], + child: JobsList( + // jobs[i].id, + // jobs[i].title, + // jobs[i].imageUrl, + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/components/horizontal_list.dart b/lib/src/ui/components/horizontal_list.dart index dbf4b56..a00afc1 100644 --- a/lib/src/ui/components/horizontal_list.dart +++ b/lib/src/ui/components/horizontal_list.dart @@ -1,65 +1,80 @@ import 'package:flutter/material.dart'; import 'package:flutter_money_formatter/flutter_money_formatter.dart'; +import 'package:flutter_svg/flutter_svg.dart'; import 'package:provider/provider.dart'; import 'package:space/src/core/models/job.dart'; import 'package:space/src/ui/seeker/layout/job_details.dart'; -class HorizontalList extends StatelessWidget { +class RecommendedJob extends StatelessWidget { @override Widget build(BuildContext context) { final job = Provider.of(context, listen: false); - return Row( - children: [ - Container( - padding: EdgeInsets.all(5), - child: MaterialButton( - padding: EdgeInsets.symmetric(vertical: 0, horizontal: 0), - onPressed: () { - Navigator.of(context) - .pushNamed(JobDetails.routeName, arguments: job.id); - }, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Center( - child: Container( - padding: EdgeInsets.all(10), - height: 100, - width: 100, - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(20)), - child: Text('Image.network(job.imageUrl)'), - )), - Text('job.employerName', - style: TextStyle( - fontSize: 12, fontWeight: FontWeight.bold, height: 2)), - Text(job.title, - style: - TextStyle(fontSize: 10, fontWeight: FontWeight.bold)), - Row( + return GestureDetector( + onTap: () { + Navigator.of(context) + .pushNamed(JobDetails.routeName, arguments: job.id); + }, + child: Container( + width: 120, + height: 60, + margin: EdgeInsets.symmetric(horizontal: 5, vertical: 5), + child: Material( + elevation: 3, + shape: + RoundedRectangleBorder(borderRadius: BorderRadius.circular(10)), + child: Column( + children: [ + Container( + height: 60, + child: ClipRRect( + borderRadius: new BorderRadius.only(topLeft: Radius.circular(10), topRight: Radius.circular(10)), + child: SvgPicture.asset( + 'assets/ketapang.svg', + fit: BoxFit.cover, + ), + ), + ), + Padding( + padding: const EdgeInsets.symmetric(horizontal: 4), + child: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, children: [ - Text('Salary: ', style: TextStyle(fontSize: 8)), - Text( - FlutterMoneyFormatter( - amount: job.salary, - settings: MoneyFormatterSettings( - symbol: 'Rp', - thousandSeparator: '.', - fractionDigits: 0)) - .output - .symbolOnLeft, - style: TextStyle(fontSize: 8)), + Text(job.employerName, + style: TextStyle( + fontSize: 12, + fontWeight: FontWeight.bold, + height: 2)), + Text(job.title, + style: TextStyle( + fontSize: 10, + fontWeight: FontWeight.bold, + )), + Row( + children: [ + Text('Salary: ', style: TextStyle(fontSize: 8)), + Text( + FlutterMoneyFormatter( + amount: job.salary, + settings: MoneyFormatterSettings( + symbol: 'Rp', + thousandSeparator: '.', + fractionDigits: 0)) + .output + .symbolOnLeft, + style: TextStyle(fontSize: 8)), + ], + ), + Text(job.workingday, style: TextStyle(fontSize: 8)), + Text(job.workinghour, style: TextStyle(fontSize: 8)), ], ), - Text(job.workingday, style: TextStyle(fontSize: 8)), - Text(job.workinghour, style: TextStyle(fontSize: 8)), - ], - ), + ), + ], ), ), - ], + ), ); } } diff --git a/lib/src/ui/components/horizontal_screen.dart b/lib/src/ui/components/horizontal_screen.dart index 25703f0..59dcdb1 100644 --- a/lib/src/ui/components/horizontal_screen.dart +++ b/lib/src/ui/components/horizontal_screen.dart @@ -4,29 +4,29 @@ import 'package:provider/provider.dart'; import 'package:space/src/core/models/jobs.dart'; import 'package:space/src/ui/components/horizontal_list.dart'; -class HorizontalScreen extends StatefulWidget { - _HorizontalScreenState createState() => _HorizontalScreenState(); +class RecommendedScreen extends StatefulWidget { + _RecommendedScreenState createState() => _RecommendedScreenState(); } -class _HorizontalScreenState extends State { - var _isInit = true; +class _RecommendedScreenState extends State { + // var _isInit = true; var _isLoading = false; - @override - void didChangeDependencies() { - if (_isInit) { - setState(() { - _isLoading = true; - }); - Provider.of(context).fetchAndSetJobs().then((_) { - setState(() { - _isLoading = false; - }); - }); - } - _isInit = false; - super.didChangeDependencies(); - } + // @override + // void didChangeDependencies() { + // if (_isInit) { + // setState(() { + // _isLoading = true; + // }); + // Provider.of(context).fetchAndSetJobs().then((_) { + // setState(() { + // _isLoading = false; + // }); + // }); + // } + // _isInit = false; + // super.didChangeDependencies(); + // } @override Widget build(BuildContext context) { @@ -45,7 +45,7 @@ class _HorizontalScreenState extends State { itemBuilder: (ctx, i) => ChangeNotifierProvider.value( // builder: (c) => jobs[i], value: jobs[i], - child: HorizontalList( + child: RecommendedJob( // jobs[i].id, // jobs[i].title, // jobs[i].imageUrl, diff --git a/lib/src/ui/components/notification.dart b/lib/src/ui/components/notification.dart new file mode 100644 index 0000000..b46b940 --- /dev/null +++ b/lib/src/ui/components/notification.dart @@ -0,0 +1,208 @@ +import 'dart:ui'; + +import 'package:flutter/material.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:space/src/ui/employer/layout/employer_app_bar.dart'; +import 'package:space/src/ui/employer/layout/employer_edit_post.dart'; + +class NotificationUi extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + body: Container( + margin: EdgeInsets.only(top: 18), + child: ListView( + children: [ + Padding( + padding: EdgeInsets.symmetric(horizontal: 15, vertical: 10), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Notifications', + style: TextStyle( + fontSize: 32, + fontWeight: FontWeight.bold, + color: Color(0xff3b3b3b))), + ], + ), + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Rudy ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'following you.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Your Post ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'have 93 Applicants.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Rudy ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'following you.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Rudy ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'following you.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Rudy ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'following you.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ListTile( + leading: CircleAvatar( + radius: 20, + backgroundColor: Colors.white, + child: Image.asset('assets/img_profile-1.png', scale: 2.3), + ), + title: RichText( + text: TextSpan(children: [ + TextSpan( + text: 'Rudy ', + style: TextStyle( + fontSize: 14, + fontWeight: FontWeight.bold, + color: Colors.black), + ), + TextSpan( + text: 'following you.', + style: TextStyle(fontSize: 14, color: Colors.black), + ), + ])), + subtitle: Text('Today 16.42 PM', style: TextStyle(fontSize: 13)), + trailing: Padding( + padding: EdgeInsets.only(bottom: 15), + child: IconButton( + onPressed: () {}, + icon: + Icon(MdiIcons.dotsHorizontal, color: Colors.black))), + onTap: () {}, + ), + ], + ), + ), + ); + } +} diff --git a/lib/src/ui/components/otp_employer.dart b/lib/src/ui/components/otp_employer.dart new file mode 100644 index 0000000..a4d2792 --- /dev/null +++ b/lib/src/ui/components/otp_employer.dart @@ -0,0 +1,238 @@ +import 'package:flutter/material.dart'; +import 'package:space/src/ui/auth/employer/intro_employer.dart'; +import 'package:space/src/ui/auth/seeker/intro_seeker.dart'; +import 'package:space/src/ui/components/verify_otp_employer.dart'; + +class OTPEmployer extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Color.fromARGB(255, 255, 211, 105), + body: SingleChildScrollView( + child: Container( + height: MediaQuery.of(context).size.height, + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Stack( + alignment: Alignment(0, 1), + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 130, vertical: 75), + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 140, right: 130, bottom: 55), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 130, right: 130, bottom: 40), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 110, right: 120), + height: 45, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(bottom: 5), + alignment: Alignment.center, + child: Image.asset( + 'assets/otp.png', + scale: 0.8, + ), + ), + Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 60, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 50, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 40, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 20, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + ], + ) + ], + ), + Text('Enter your mobile number', + style: TextStyle( + color: Colors.redAccent, fontSize: 18, height: 6)), + Text('You will get a OTP message', + style: TextStyle( + color: Colors.white, fontSize: 14, height: 0.3)), + Container( + padding: const EdgeInsets.symmetric(horizontal: 60), + child: TextFormField( + decoration: InputDecoration( + labelText: '(+62) Indonesia', + labelStyle: + TextStyle(color: Colors.redAccent, fontSize: 14), + alignLabelWithHint: true, + enabledBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.white), + ), + focusedBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.redAccent), + ), + ), + ), + ), + Padding( + padding: const EdgeInsets.symmetric(horizontal: 60), + child: TextFormField( + textAlign: TextAlign.center, + decoration: InputDecoration( + labelText: 'Enter your phone number', + labelStyle: + TextStyle(color: Colors.redAccent, fontSize: 14), + alignLabelWithHint: true, + enabledBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.white), + ), + focusedBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.redAccent), + ), + ), + ), + ), + Padding( + padding: const EdgeInsets.only(top: 40), + child: ButtonTheme( + height: 40, + minWidth: 150, + child: RaisedButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => VerifyEmployer())); + }, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30)), + color: Colors.white, + child: Text('Verify', + style: + TextStyle(color: Colors.redAccent, fontSize: 14)), + ), + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/components/otp_seeker.dart b/lib/src/ui/components/otp_seeker.dart new file mode 100644 index 0000000..92fcd22 --- /dev/null +++ b/lib/src/ui/components/otp_seeker.dart @@ -0,0 +1,239 @@ +import 'package:flutter/material.dart'; +import 'package:space/src/ui/auth/employer/intro_employer.dart'; +import 'package:space/src/ui/auth/seeker/intro_seeker.dart'; +import 'package:space/src/ui/components/verify_otp_seeker.dart'; + +class OTPSeeker extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Color.fromARGB(255, 255, 211, 105), + body: SingleChildScrollView( + child: Container( + height: MediaQuery.of(context).size.height, + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Stack( + alignment: Alignment(0, 1), + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 130,vertical: 75), + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 140, right: 130, bottom: 55), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 130, right: 130, bottom: 40), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 110, right: 120), + height: 45, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(bottom: 5), + alignment: Alignment.center, + child: Image.asset( + 'assets/otp.png', + scale: 0.8, + ), + ), + Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 60, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 50, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 40, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 20, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + ], + ) + ], + ), + Text('Enter your mobile number', + style: TextStyle( + color: Colors.redAccent, fontSize: 18, height: 9)), + Text('You will get a OTP message', + style: TextStyle( + color: Colors.white, fontSize: 14, height: 0.3)), + Container( + margin: EdgeInsets.symmetric(vertical: 20), + padding: const EdgeInsets.symmetric(horizontal: 60), + child: TextFormField( + decoration: InputDecoration( + labelText: '(+62) Indonesia', + labelStyle: + TextStyle(color: Colors.redAccent, fontSize: 14), + alignLabelWithHint: true, + enabledBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.white), + ), + focusedBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.redAccent), + ), + ), + ), + ), + Padding( + padding: const EdgeInsets.symmetric(horizontal: 60), + child: TextFormField( + textAlign: TextAlign.center, + decoration: InputDecoration( + labelText: 'Enter your phone number', + labelStyle: + TextStyle(color: Colors.redAccent, fontSize: 14), + alignLabelWithHint: true, + enabledBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.white), + ), + focusedBorder: UnderlineInputBorder( + borderSide: BorderSide(color: Colors.redAccent), + ), + ), + ), + ), + Padding( + padding: const EdgeInsets.only(top: 40), + child: ButtonTheme( + height: 40, + minWidth: 150, + child: RaisedButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => VerifySeeker())); + }, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30)), + color: Colors.white, + child: Text('Verify', + style: + TextStyle(color: Colors.redAccent, fontSize: 14)), + ), + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/components/recommended_job.dart b/lib/src/ui/components/recommended_job.dart index 8a94e04..d1c3466 100644 --- a/lib/src/ui/components/recommended_job.dart +++ b/lib/src/ui/components/recommended_job.dart @@ -5,13 +5,14 @@ import 'package:provider/provider.dart'; import 'package:space/src/core/models/job.dart'; import 'package:space/src/ui/seeker/layout/job_details.dart'; -class RecommendedJob extends StatelessWidget { +class RecentJob extends StatelessWidget { @override Widget build(BuildContext context) { final job = Provider.of(context, listen: false); return Container( padding: EdgeInsets.symmetric(horizontal: 10), child: Card( + elevation: 3, shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(10)), child: ListTile( onTap: () { @@ -20,7 +21,7 @@ class RecommendedJob extends StatelessWidget { }, leading: SizedBox( height: 40, - // child: Image.network(job.imageUrl, fit: BoxFit.cover), + child: Image.network(job.imageUrl, fit: BoxFit.cover), ), title: Container( padding: EdgeInsets.only(bottom: 10), diff --git a/lib/src/ui/components/recommended_screen.dart b/lib/src/ui/components/recommended_screen.dart index 884cb09..e8bc986 100644 --- a/lib/src/ui/components/recommended_screen.dart +++ b/lib/src/ui/components/recommended_screen.dart @@ -4,31 +4,31 @@ import 'package:provider/provider.dart'; import 'package:space/src/core/models/jobs.dart'; import 'package:space/src/ui/components/recommended_job.dart'; -class RecommendedScreen extends StatefulWidget { +class RecentScreen extends StatefulWidget { - _RecommendedScreenState createState() => _RecommendedScreenState(); + _RecentScreenState createState() => _RecentScreenState(); } -class _RecommendedScreenState extends State { - var _isInit = true; +class _RecentScreenState extends State { + // var _isInit = true; var _isLoading = false; - @override - void didChangeDependencies() { - if (_isInit) { - setState(() { - _isLoading = true; - }); - Provider.of(context).fetchAndSetJobs().then((_) { - setState(() { - _isLoading = false; - }); - }); - } - _isInit = false; - super.didChangeDependencies(); - } + // @override + // void didChangeDependencies() { + // if (_isInit) { + // setState(() { + // _isLoading = true; + // }); + // Provider.of(context).fetchAndSetJobs().then((_) { + // setState(() { + // _isLoading = false; + // }); + // }); + // } + // _isInit = false; + // super.didChangeDependencies(); + // } @override Widget build(BuildContext context) { @@ -46,7 +46,7 @@ class _RecommendedScreenState extends State { itemBuilder: (ctx, i) => ChangeNotifierProvider.value( // builder: (c) => jobs[i], value: jobs[i], - child: RecommendedJob( + child: RecentJob( // jobs[i].id, // jobs[i].title, // jobs[i].imageUrl, diff --git a/lib/src/ui/components/test.dart b/lib/src/ui/components/test.dart new file mode 100644 index 0000000..e69de29 diff --git a/lib/src/ui/components/verify_otp_employer.dart b/lib/src/ui/components/verify_otp_employer.dart new file mode 100644 index 0000000..291af3f --- /dev/null +++ b/lib/src/ui/components/verify_otp_employer.dart @@ -0,0 +1,335 @@ +import 'package:flutter/material.dart'; +import 'package:space/src/ui/auth/employer/intro_employer.dart'; +import 'package:space/src/ui/auth/seeker/intro_seeker.dart'; + +class VerifyEmployer extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Color.fromARGB(255, 255, 211, 105), + body: SingleChildScrollView( + child: Container( + height: MediaQuery.of(context).size.height, + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Stack( + alignment: Alignment(0, 1), + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 130,vertical: 75), + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 140, right: 130, bottom: 55), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 130, right: 130, bottom: 40), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 110, right: 120), + height: 45, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(bottom: 5), + alignment: Alignment.center, + child: Image.asset( + 'assets/otp.png', + scale: 0.8, + ), + ), + Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 60, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 50, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 40, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 20, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + ], + ) + ], + ), + Container( + width: 231, + height: 231, + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Align( + alignment: Alignment.topCenter, + child: Container( + width: 231, + height: 52, + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 14), + child: Text( + "Enter your OTP number", + style: TextStyle( + color: Color.fromARGB(255, 226, 98, 65), + fontSize: 18, + fontFamily: "Varela Round", + ), + textAlign: TextAlign.center, + ), + ), + Spacer(), + Text( + "We have sent OTP on your number", + style: TextStyle( + color: Color.fromARGB(255, 255, 255, 255), + fontSize: 14, + fontFamily: "Varela Round", + ), + textAlign: TextAlign.center, + ), + ], + ), + ), + ), + Align( + alignment: Alignment.topCenter, + child: Container( + width: 219, + height: 95, + margin: EdgeInsets.only(top: 84), + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Container( + height: 55, + child: Row( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + margin: EdgeInsets.only(left: 9), + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Spacer(), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + margin: EdgeInsets.only(right: 9), + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + ], + ), + ), + Spacer(), + Align( + alignment: Alignment.topCenter, + child: Text( + "OTP auto resend in 29 sec", + style: TextStyle( + color: Color.fromARGB(255, 255, 255, 255), + fontSize: 14, + fontFamily: "Roboto", + fontWeight: FontWeight.w500, + ), + textAlign: TextAlign.center, + ), + ), + ], + ), + ), + ), + ], + ), + ), + Padding( + padding: const EdgeInsets.only(top: 40), + child: ButtonTheme( + height: 40, + minWidth: 150, + child: RaisedButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + IntroImployer())); + }, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30)), + color: Colors.white, + child: Text('Verify', + style: TextStyle( + color: Colors.redAccent, + fontSize: 14)), + ), + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/components/verify_otp_seeker.dart b/lib/src/ui/components/verify_otp_seeker.dart new file mode 100644 index 0000000..ce7b3f9 --- /dev/null +++ b/lib/src/ui/components/verify_otp_seeker.dart @@ -0,0 +1,335 @@ +import 'package:flutter/material.dart'; +import 'package:space/src/ui/auth/employer/intro_employer.dart'; +import 'package:space/src/ui/auth/seeker/intro_seeker.dart'; + +class VerifySeeker extends StatelessWidget { + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Color.fromARGB(255, 255, 211, 105), + body: SingleChildScrollView( + child: Container( + height: MediaQuery.of(context).size.height, + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Stack( + alignment: Alignment(0, 1), + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 130,vertical: 75), + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 140, right: 130, bottom: 55), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 130, right: 130, bottom: 40), + height: 25, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(left: 110, right: 120), + height: 45, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.circular(30)), + ), + Container( + margin: EdgeInsets.only(bottom: 5), + alignment: Alignment.center, + child: Image.asset( + 'assets/otp.png', + scale: 0.8, + ), + ), + Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 60, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 30, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 50, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 40, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 70, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topRight: Radius.circular(30), + bottomRight: Radius.circular(30)), + ), + ), + Container( + margin: EdgeInsets.symmetric(vertical: 5), + width: 20, + height: 30, + decoration: BoxDecoration( + color: Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + bottomLeft: Radius.circular(30)), + ), + ), + ], + ), + ], + ) + ], + ), + Container( + width: 231, + height: 231, + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Align( + alignment: Alignment.topCenter, + child: Container( + width: 231, + height: 52, + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Container( + margin: EdgeInsets.symmetric(horizontal: 14), + child: Text( + "Enter your OTP number", + style: TextStyle( + color: Color.fromARGB(255, 226, 98, 65), + fontSize: 18, + fontFamily: "Varela Round", + ), + textAlign: TextAlign.center, + ), + ), + Spacer(), + Text( + "We have sent OTP on your number", + style: TextStyle( + color: Color.fromARGB(255, 255, 255, 255), + fontSize: 14, + fontFamily: "Varela Round", + ), + textAlign: TextAlign.center, + ), + ], + ), + ), + ), + Align( + alignment: Alignment.topCenter, + child: Container( + width: 219, + height: 95, + margin: EdgeInsets.only(top: 84), + child: Column( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Container( + height: 55, + child: Row( + crossAxisAlignment: CrossAxisAlignment.stretch, + children: [ + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + margin: EdgeInsets.only(left: 9), + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Spacer(), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + margin: EdgeInsets.only(right: 9), + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + Align( + alignment: Alignment.topLeft, + child: Container( + width: 48, + height: 55, + decoration: BoxDecoration( + color: + Color.fromARGB(255, 255, 248, 205), + borderRadius: BorderRadius.all( + Radius.circular(9)), + ), + child: Container(), + ), + ), + ], + ), + ), + Spacer(), + Align( + alignment: Alignment.topCenter, + child: Text( + "OTP auto resend in 29 sec", + style: TextStyle( + color: Color.fromARGB(255, 255, 255, 255), + fontSize: 14, + fontFamily: "Roboto", + fontWeight: FontWeight.w500, + ), + textAlign: TextAlign.center, + ), + ), + ], + ), + ), + ), + ], + ), + ), + Padding( + padding: const EdgeInsets.only(top: 40), + child: ButtonTheme( + height: 40, + minWidth: 150, + child: RaisedButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + IntroSeeker())); + }, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30)), + color: Colors.white, + child: Text('Verify', + style: TextStyle( + color: Colors.redAccent, + fontSize: 14)), + ), + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/employer/layout/employer_app_bar.dart b/lib/src/ui/employer/layout/employer_app_bar.dart index 7c5b17a..2f9d6de 100644 --- a/lib/src/ui/employer/layout/employer_app_bar.dart +++ b/lib/src/ui/employer/layout/employer_app_bar.dart @@ -20,7 +20,7 @@ class EmployerAppBar extends StatelessWidget { centerTitle: true, title: SizedBox( child: Image.asset('assets/logo_vertical.png'), - height: 30, + height: 60, ), actions: [ IconButton( diff --git a/lib/src/ui/employer/layout/employer_edit_post.dart b/lib/src/ui/employer/layout/employer_edit_post.dart index f0a81e6..087e510 100644 --- a/lib/src/ui/employer/layout/employer_edit_post.dart +++ b/lib/src/ui/employer/layout/employer_edit_post.dart @@ -47,34 +47,34 @@ class _EditPostState extends State { 'typeSalary': '', 'gender': '', }; - var _isInit = true; + // var _isInit = true; var _isLoading = false; - @override - void didChangeDependencies() { - if (_isInit) { - final jobId = ModalRoute.of(context).settings.arguments as String; - if (jobId != null) { - _editJob = Provider.of(context, listen: false).findById(jobId); - _initValues = { - 'title': _editJob.title, - 'location': _editJob.location, - 'description': _editJob.description, - 'workingday': _editJob.workingday, - 'workinghour': _editJob.workinghour, - 'skill': _editJob.skill, - 'salary': _editJob.salary.toString(), - 'type': _editJob.type, - 'education': _editJob.education, - 'industry': _editJob.industry, - 'typeSalary': _editJob.typeSalary, - 'gender': _editJob.gender.toString(), - }; - } - } - _isInit = false; - super.didChangeDependencies(); - } + // @override + // void didChangeDependencies() { + // if (_isInit) { + // final jobId = ModalRoute.of(context).settings.arguments as String; + // if (jobId != null) { + // _editJob = Provider.of(context, listen: false).findById(jobId); + // _initValues = { + // 'title': _editJob.title, + // 'location': _editJob.location, + // 'description': _editJob.description, + // 'workingday': _editJob.workingday, + // 'workinghour': _editJob.workinghour, + // 'skill': _editJob.skill, + // 'salary': _editJob.salary.toString(), + // 'type': _editJob.type, + // 'education': _editJob.education, + // 'industry': _editJob.industry, + // 'typeSalary': _editJob.typeSalary, + // 'gender': _editJob.gender.toString(), + // }; + // } + // } + // _isInit = false; + // super.didChangeDependencies(); + // } @override void dispose() { @@ -87,54 +87,54 @@ class _EditPostState extends State { super.dispose(); } - Future _saveForm() async { - final isValid = _form.currentState.validate(); - if (!isValid) { - return; - } - _form.currentState.save(); - setState(() { - _isLoading = true; - }); - if (_editJob.id != null) { - await Provider.of(context, listen: false) - .updateJob(_editJob.id, _editJob); - } else { - try { - await Provider.of(context, listen: false).addJob(_editJob); - } catch (error) { - print(error); - } - { - await showDialog( - context: context, - builder: (ctx) => AlertDialog( - title: Text('An error occurred!'), - content: Text('Something went wrong.'), - actions: [ - FlatButton( - child: Text('Ok'), - onPressed: () { - Navigator.of(ctx).pop(); - }, - ) - ], - ), - ); - } + // Future _saveForm() async { + // final isValid = _form.currentState.validate(); + // if (!isValid) { + // return; + // } + // _form.currentState.save(); + // setState(() { + // _isLoading = true; + // }); + // if (_editJob.id != null) { + // await Provider.of(context, listen: false) + // .updateJob(_editJob.id, _editJob); + // } else { + // try { + // await Provider.of(context, listen: false).addJob(_editJob); + // } catch (error) { + // print(error); + // } + // { + // await showDialog( + // context: context, + // builder: (ctx) => AlertDialog( + // title: Text('An error occurred!'), + // content: Text('Something went wrong.'), + // actions: [ + // FlatButton( + // child: Text('Ok'), + // onPressed: () { + // Navigator.of(ctx).pop(); + // }, + // ) + // ], + // ), + // ); + // } // finally { // setState(() { // _isLoading = false; // }); // Navigator.of(context).pop(); // } - } - setState(() { - _isLoading = false; - }); - Navigator.of(context).pop(); + // } + // setState(() { + // _isLoading = false; + // }); // Navigator.of(context).pop(); - } + // Navigator.of(context).pop(); + // } String gender; String industry; @@ -145,23 +145,6 @@ class _EditPostState extends State { @override Widget build(BuildContext context) { return Scaffold( - appBar: AppBar( - automaticallyImplyLeading: true, - leading: IconButton( - onPressed: () { - Navigator.pop(context, true); - }, - icon: Icon(Icons.chevron_left, color: Color(0xff2c4057), size: 16)), - elevation: 1, - backgroundColor: Colors.white, - title: Text('Post Job', - style: TextStyle( - color: Color(0xff2c4057), - fontSize: 14, - fontWeight: FontWeight.w500, - letterSpacing: 1, - )), - ), body: _isLoading ? Center( child: CircularProgressIndicator(), @@ -169,7 +152,7 @@ class _EditPostState extends State { : Form( key: _form, child: SingleChildScrollView( - padding: EdgeInsets.symmetric(vertical: 30), + padding: EdgeInsets.symmetric(vertical: 50,), child: Column( children: [ Column( @@ -1113,27 +1096,19 @@ class _EditPostState extends State { borderRadius: BorderRadius.all(Radius.circular(5)), color: Color(0xff22c0e8), child: MaterialButton( + onPressed: (){}, padding: EdgeInsets.fromLTRB(15.0, 15.0, 15.0, 15.0), - onPressed: _saveForm, + // onPressed: _saveForm, child: Row( - mainAxisAlignment: MainAxisAlignment.end, + mainAxisAlignment: MainAxisAlignment.center, children: [ - Text('Save Post', - textAlign: TextAlign.center, + Text('Post', style: TextStyle( fontFamily: 'VarelaRound', color: Color(0xffffffff), fontSize: 16, fontWeight: FontWeight.w500, )), - Container( - padding: EdgeInsets.only(left: 40, right: 30), - child: Icon( - Icons.arrow_forward, - color: Colors.white, - size: 20, - ), - ), ], ), ), diff --git a/lib/src/ui/employer/layout/employer_post.dart b/lib/src/ui/employer/layout/employer_post.dart index 24e40bf..498ed8a 100644 --- a/lib/src/ui/employer/layout/employer_post.dart +++ b/lib/src/ui/employer/layout/employer_post.dart @@ -102,58 +102,24 @@ class EmployerPost extends StatelessWidget { child: Row( mainAxisAlignment: MainAxisAlignment.end, children: [ - IconButton( - onPressed: () { - Navigator.of(context) - .pushNamed(EditPost.routeName, arguments: id); - }, - icon: Icon(Icons.edit), - ), - IconButton( - icon: Icon(Icons.delete), - onPressed: () async { - try { - await Provider.of(context, listen: false) - .deleteJob(id); - } catch (error) { - scaffold.showSnackBar( - SnackBar( - content: Text( - 'Deleting failed!', - textAlign: TextAlign.center, - ), - ), - ); - } - }, - color: Theme.of(context).errorColor, - ), + PopupMenuButton( + icon: Icon( + Icons.more_vert, + size: 22, + ), + itemBuilder: (_) => [ + PopupMenuItem( + child: Text('Edit'), + ), + PopupMenuItem( + child: Text('Delete'), + ), + ], + + ) ], ), -// PopupMenuButton( -// onSelected: (PostOptions selectedValue) { -// setState(() { -// if (selectedValue == PostOptions.Edit) { -// _showOnlyFavorites = true; -// } else { -// _showOnlyFavorites = false; -// } -// }); -// }, -// icon: Icon( -// Icons.more_vert, -// ), -// itemBuilder: (_) => [ -// PopupMenuItem( -// child: Text('Edit'), -// value: PostOptions.Edit, -// ), -// PopupMenuItem( -// child: Text('Delete'), -// value: PostOptions.Delete, -// ), -// ], -// ), + ), ], ), diff --git a/lib/src/ui/employer/screens/employer_posted_screen.dart b/lib/src/ui/employer/screens/employer_posted_screen.dart index 56ae60a..a5f29d6 100644 --- a/lib/src/ui/employer/screens/employer_posted_screen.dart +++ b/lib/src/ui/employer/screens/employer_posted_screen.dart @@ -8,7 +8,8 @@ class EmployerPostScreen extends StatelessWidget { static const routeName = '/employer-posts'; Future _refreshJobs(BuildContext context) async { - await Provider.of(context, listen: false).fetchAndSetJobs(true); + //await + Provider.of(context, listen: false);//.fetchAndSetJobs(true); } @override diff --git a/lib/src/ui/employer/screens/employer_seeker_screen.dart b/lib/src/ui/employer/screens/employer_seeker_screen.dart index 577621e..b40379d 100644 --- a/lib/src/ui/employer/screens/employer_seeker_screen.dart +++ b/lib/src/ui/employer/screens/employer_seeker_screen.dart @@ -47,22 +47,10 @@ class _EmployerSeekerListState extends State { ListTile( leading: Column( children: [ - Stack( - alignment: Alignment(1, -1), - children: [ - CircleAvatar( - backgroundImage: - AssetImage('assets/img_profil.png'), - backgroundColor: Colors.blue, - radius: 28, - ), - Material( - borderRadius: BorderRadius.circular(20), - color: Color(0xff22c0e8), - child: Icon(FeatherIcons.plus, - color: Colors.white, size: 14), - ), - ], + CircleAvatar( + backgroundImage: AssetImage('assets/img_profil.png'), + backgroundColor: Colors.blue, + radius: 28, ), ], ), diff --git a/lib/src/ui/employer/screens/employer_tabs.dart b/lib/src/ui/employer/screens/employer_tabs.dart index 5907b0e..79459e3 100644 --- a/lib/src/ui/employer/screens/employer_tabs.dart +++ b/lib/src/ui/employer/screens/employer_tabs.dart @@ -20,7 +20,7 @@ class EmployerTabs extends StatelessWidget { body: TabBarView( children: [ EmployerSeekerList(), - JobsListScreen(), + EmployerSeekerList(), EmployerPostScreen(), ], )), diff --git a/lib/src/ui/employer/widgets/employer_app_drawer.dart b/lib/src/ui/employer/widgets/employer_app_drawer.dart index 883b0f5..eabb799 100644 --- a/lib/src/ui/employer/widgets/employer_app_drawer.dart +++ b/lib/src/ui/employer/widgets/employer_app_drawer.dart @@ -32,15 +32,15 @@ class EmployerDrawer extends StatelessWidget { children: [ Text('Mekuru Ramen', style: - TextStyle(fontSize: 16, color: Color(0xff3b3b3b))), + TextStyle(fontSize: 18, color: Colors.black, height: 2)), Text('View and Edit Profile', style: - TextStyle(fontSize: 11, color: Color(0xff3b3b3b))), + TextStyle(fontSize: 10, color: Colors.black)), ], ), trailing: CircleAvatar( backgroundColor: Colors.white, - radius: 40.0, + radius: 30.0, child: Image.asset( 'assets/mekuru.png', height: 75, @@ -61,7 +61,7 @@ class EmployerDrawer extends StatelessWidget { style: TextStyle( color: Color(0xff757575), fontSize: 12, height: 0.5)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.bellOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -82,7 +82,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Profile Setting', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.accountEditOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -103,7 +103,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Settings', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.settingsOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -124,7 +124,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Help?', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.accountQuestionOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -144,7 +144,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Feedback Us', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.sendCircleOutline, color: Color(0xff4d4d4d), size: 20)), onTap: () { @@ -164,7 +164,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Invite Friends', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.accountMultiplePlusOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -185,7 +185,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('FAQ', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.helpCircleOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -205,7 +205,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Abous Us', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.accountGroupOutline, color: Color(0xff4d4d4d), size: 18)), onTap: () { @@ -225,7 +225,7 @@ class EmployerDrawer extends StatelessWidget { title: Text('Log Out', style: TextStyle(color: Color(0xff757575), fontSize: 12)), trailing: Padding( - padding: EdgeInsets.only(bottom: 5), + padding: EdgeInsets.only(bottom: 5, right: 5), child: Icon(MdiIcons.logoutVariant, color: Color(0xff4d4d4d), size: 18)), onTap: () { diff --git a/lib/src/ui/seeker/layout/apply_post.dart b/lib/src/ui/seeker/layout/apply_post.dart index 1501dfe..4deda37 100644 --- a/lib/src/ui/seeker/layout/apply_post.dart +++ b/lib/src/ui/seeker/layout/apply_post.dart @@ -1,71 +1,71 @@ -import 'dart:math'; +// import 'dart:math'; -import 'package:flutter/material.dart'; -import 'package:intl/intl.dart'; +// import 'package:flutter/material.dart'; +// import 'package:intl/intl.dart'; -import 'package:space/src/core/models/apply.dart' as ord; +// // import 'package:space/src/core/models/apply.dart' as ord; -class ApplyItem extends StatefulWidget { - final ord.ApplyItem apply; - ApplyItem(this.apply); +// class ApplyPost extends StatefulWidget { +// // final ord.ApplyPost apply; +// // ApplyPost(this.apply); - @override - _OrderItemState createState() => _OrderItemState(); -} +// @override +// _OrderItemState createState() => _OrderItemState(); +// } -class _OrderItemState extends State { - var _expanded = false; +// class _OrderItemState extends State { +// var _expanded = false; - @override - Widget build(BuildContext context) { - return AnimatedContainer( - duration: Duration(milliseconds: 300), - height: _expanded ? min(widget.apply.jobs.length * 20.0 + 110, 200) : 95, - child: Card( - margin: EdgeInsets.all(10), - child: Column( - children: [ - ListTile( - subtitle: Text( - DateFormat('dd/MM/yyyy hh:mm').format(widget.apply.dateTime), - ), - trailing: IconButton( - icon: Icon(_expanded ? Icons.expand_less : Icons.expand_more), - onPressed: () { - setState(() { - _expanded = !_expanded; - }); - }, - ), - ), - AnimatedContainer( - duration: Duration(milliseconds: 300), - padding: EdgeInsets.symmetric(horizontal: 15, vertical: 4), - height: _expanded - ? min(widget.apply.jobs.length * 20.0 + 10, 100) - : 0, - child: ListView( - children: widget.apply.jobs - .map( - (prod) => Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text( - prod.title, - style: TextStyle( - fontSize: 18, - fontWeight: FontWeight.bold, - ), - ), - ], - ), - ) - .toList(), - ), - ) - ], - ), - ), - ); - } -} +// @override +// Widget build(BuildContext context) { +// return AnimatedContainer( +// duration: Duration(milliseconds: 300), +// height: _expanded ? min(widget.apply.job.length * 20.0 + 110, 200) : 95, +// child: Card( +// margin: EdgeInsets.all(10), +// child: Column( +// children: [ +// ListTile( +// subtitle: Text( +// DateFormat('dd/MM/yyyy hh:mm').format(widget.apply.dateTime), +// ), +// trailing: IconButton( +// icon: Icon(_expanded ? Icons.expand_less : Icons.expand_more), +// onPressed: () { +// setState(() { +// _expanded = !_expanded; +// }); +// }, +// ), +// ), +// AnimatedContainer( +// duration: Duration(milliseconds: 300), +// padding: EdgeInsets.symmetric(horizontal: 15, vertical: 4), +// height: _expanded +// ? min(widget.apply.job.length * 20.0 + 10, 100) +// : 0, +// child: ListView( +// children: widget.apply.job +// .map( +// (job) => Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// // Text( +// // job.title, +// // style: TextStyle( +// // fontSize: 18, +// // fontWeight: FontWeight.bold, +// // ), +// // ), +// ], +// ), +// ) +// .toList(), +// ), +// ) +// ], +// ), +// ), +// ); +// } +// } diff --git a/lib/src/ui/seeker/layout/cv.dart b/lib/src/ui/seeker/layout/cv.dart new file mode 100644 index 0000000..165e83b --- /dev/null +++ b/lib/src/ui/seeker/layout/cv.dart @@ -0,0 +1,987 @@ +import 'package:flutter/material.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; +import 'package:provider/provider.dart'; +import 'package:space/src/core/models/job.dart'; +import 'package:space/src/core/models/jobs.dart'; + +class CVSeeker extends StatefulWidget { + static const routeName = '/cv-seeker'; + + @override + _CVSeekerState createState() => _CVSeekerState(); +} + +class _CVSeekerState extends State { + var _isLoading = false; + + String gender; + String industry; + String type; + String typeSalary; + String education; + + @override + Widget build(BuildContext context) { + return Scaffold( + body: _isLoading + ? Center( + child: CircularProgressIndicator(), + ) + : Form( + child: SingleChildScrollView( + padding: EdgeInsets.symmetric( + vertical: 50, + ), + child: Column( + children: [ + Column( + children: [ + Column( + children: [ + Text("CV Details", + textAlign: TextAlign.center, + overflow: TextOverflow.ellipsis, + style: TextStyle( + color: Color(0xff2c4057), + fontSize: 22, + fontWeight: FontWeight.w600, + letterSpacing: 2)), + ], + ), + Row( + children: [ + Expanded( + child: Container( + margin: EdgeInsets.only( + left: 130.0, right: 130.0), + child: Divider( + thickness: 2, + color: Color(0xff22c0e8), + height: 30)), + ), + ], + ), + ], + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Full Name", + labelStyle: TextStyle( + color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + textInputAction: TextInputAction.next), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: FormField( + builder: (FormFieldState state) { + return InputDecorator( + decoration: InputDecoration( + contentPadding: + EdgeInsets.fromLTRB(15.0, 5.0, 15.0, 5.0), + errorStyle: TextStyle( + color: Colors.redAccent, fontSize: 16.0), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + child: DropdownButtonFormField( + decoration: + InputDecoration.collapsed(hintText: ''), + hint: Text('Gender', + style: TextStyle( + color: Color(0xff8997a7), fontSize: 14)), + icon: Icon( + Icons.expand_more, + color: Colors.black45, + size: 22, + ), + value: gender, + onChanged: (String newValue) { + setState(() { + gender = newValue; + }); + }, + items: [ + 'Male', + 'Female' + ].map>((String value) { + return DropdownMenuItem( + value: value, + child: Text(value, + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25)), + ); + }).toList(), + ), + ); + }, + // validator: (value) { + // if (value.isEmpty) { + // return 'Gender should filled'; + // } + // return null; + // }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: FormField( + builder: (FormFieldState state) { + return InputDecorator( + decoration: InputDecoration( + contentPadding: + EdgeInsets.fromLTRB(15.0, 5.0, 15.0, 5.0), + errorStyle: TextStyle( + color: Colors.redAccent, fontSize: 16.0), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + child: DropdownButtonHideUnderline( + child: DropdownButtonFormField( + decoration: + InputDecoration.collapsed(hintText: ''), + hint: Text('Status', + style: TextStyle( + color: Color(0xff8997a7), + fontSize: 14)), + icon: Icon( + Icons.expand_more, + color: Colors.black45, + size: 22, + ), + value: industry, + onChanged: (String newValue) { + setState(() { + industry = newValue; + }); + }, + items: [ + 'Single', + 'Married' + ].map>((String value) { + return DropdownMenuItem( + value: value, + child: Text(value, + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25)), + ); + }).toList(), + ), + ), + ); + }, + // validator: (value) { + // if (value.isEmpty) { + // return 'Industry should filled'; + // } + // return null; + // }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: FormField( + builder: (FormFieldState state) { + return InputDecorator( + decoration: InputDecoration( + contentPadding: + EdgeInsets.fromLTRB(15.0, 5.0, 15.0, 5.0), + errorStyle: TextStyle( + color: Colors.redAccent, fontSize: 16.0), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + child: DropdownButtonHideUnderline( + child: DropdownButtonFormField( + decoration: + InputDecoration.collapsed(hintText: ''), + hint: Text('Religion', + style: TextStyle( + color: Color(0xff8997a7), + fontSize: 14)), + icon: Icon( + Icons.expand_more, + color: Colors.black45, + size: 22, + ), + value: type, + onChanged: (String newValue) { + setState(() { + type = newValue; + }); + }, + items: [ + 'Islam', + 'Christian', + 'Hindu', + 'Buddha', + ].map>((String value) { + return DropdownMenuItem( + value: value, + child: Text(value, + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25)), + ); + }).toList(), + ), + ), + ); + }, + // validator: (value) { + // if (value.isEmpty) { + // return 'Type should filled'; + // } + // return null; + // }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Date of Birth", + labelStyle: TextStyle( + color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + keyboardType: TextInputType.datetime, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "City", + labelStyle: TextStyle( + color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: FormField( + builder: (FormFieldState state) { + return InputDecorator( + decoration: InputDecoration( + contentPadding: + EdgeInsets.fromLTRB(15.0, 5.0, 15.0, 5.0), + errorStyle: TextStyle( + color: Colors.redAccent, fontSize: 16.0), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + child: DropdownButtonHideUnderline( + child: DropdownButtonFormField( + decoration: + InputDecoration.collapsed(hintText: ''), + hint: Text('Education Level', + style: TextStyle( + color: Color(0xff8997a7), + fontSize: 14)), + icon: Icon( + Icons.expand_more, + color: Colors.black45, + size: 22, + ), + value: education, + onChanged: (String newValue) { + setState(() { + education = newValue; + }); + }, + items: [ + 'SD', + 'SMP', + 'SMA', + 'D3', + 'S1', + 'S2', + 'S3' + ].map>((String value) { + return DropdownMenuItem( + value: value, + child: Text(value, + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25)), + ); + }).toList(), + ), + ), + ); + }, + // validator: (value) { + // if (value.isEmpty) { + // return 'Education Level should filled'; + // } + // return null; + // }, + ), + ), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Course", + labelStyle: TextStyle( + color: Color(0xff8997a7), fontSize: 14), + filled: true, + fillColor: Color(0xffdcdfe3), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context).errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: + BorderSide(color: Colors.transparent), + borderRadius: + BorderRadius.all(Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + GestureDetector( + onTap: (){}, + child: Container( + height: 55, + margin: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + padding: EdgeInsets.symmetric(horizontal: 8), + decoration: BoxDecoration( + color: Colors.grey, + borderRadius: + BorderRadius.all(Radius.circular(5))), + child: Row( + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Text('Add Experience', + style: TextStyle( + fontSize: 14, color: Colors.white)), + Icon(MdiIcons.plusCircleOutline, + color: Colors.white, size: 22) + ], + ), + ), + ), + Container( + margin: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(5), + ), + child: Column( + children: [ + Container( + height: 55, + padding: EdgeInsets.symmetric(horizontal: 8), + decoration: BoxDecoration( + color: Colors.grey, + borderRadius: BorderRadius.only( + topLeft: Radius.circular(5), + topRight: Radius.circular(5))), + child: Row( + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Text('Your Experience', + style: TextStyle( + fontSize: 14, color: Colors.white)), + Icon(MdiIcons.minusCircleOutline, + color: Colors.white, size: 22) + ], + ), + ), + Container( + padding: EdgeInsets.symmetric(vertical: 10), + decoration: BoxDecoration( + color: Color(0xffdcdfe3), + borderRadius: BorderRadius.only( + bottomLeft: Radius.circular(5), + bottomRight: Radius.circular(5))), + child: Column( + children: [ + Padding( + padding: EdgeInsets.symmetric( + horizontal: 10, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Company Name", + labelStyle: TextStyle( + color: Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: + OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Colors.transparent), + borderRadius: BorderRadius.all( + Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Padding( + padding: EdgeInsets.symmetric( + horizontal: 10, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Position", + labelStyle: TextStyle( + color: Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: + OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Colors.transparent), + borderRadius: BorderRadius.all( + Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Row( + children: [ + Flexible( + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + Container( + margin: EdgeInsets.only( + left: 10, + right: 10, + top: 5, + bottom: 10), + child: TextField( + style: TextStyle( + fontSize: 16, + color: Color(0xff8997a7)), + decoration: InputDecoration( + labelText: "Start", + labelStyle: TextStyle( + color: + Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color( + 0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(5)))), + ), + ), + ], + ), + ), + Flexible( + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + Container( + margin: EdgeInsets.only( + left: 10, + right: 10, + top: 5, + bottom: 10), + child: TextField( + style: TextStyle( + fontSize: 16, + color: Color(0xff8997a7)), + decoration: InputDecoration( + labelText: "Till", + labelStyle: TextStyle( + color: + Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color( + 0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(5)))), + ), + ), + ], + ), + ), + ], + ), + ], + ), + ), + ], + )), + Container( + margin: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(5), + ), + child: Column( + children: [ + Container( + height: 55, + padding: EdgeInsets.symmetric(horizontal: 8), + decoration: BoxDecoration( + color: Colors.grey, + borderRadius: BorderRadius.only( + topLeft: Radius.circular(5), + topRight: Radius.circular(5))), + child: Row( + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Text('Your Experience', + style: TextStyle( + fontSize: 14, color: Colors.white)), + Icon(MdiIcons.minusCircleOutline, + color: Colors.white, size: 22) + ], + ), + ), + Container( + padding: EdgeInsets.symmetric(vertical: 10), + decoration: BoxDecoration( + color: Color(0xffdcdfe3), + borderRadius: BorderRadius.only( + bottomLeft: Radius.circular(5), + bottomRight: Radius.circular(5))), + child: Column( + children: [ + Padding( + padding: EdgeInsets.symmetric( + horizontal: 10, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Company Name", + labelStyle: TextStyle( + color: Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: + OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Colors.transparent), + borderRadius: BorderRadius.all( + Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Padding( + padding: EdgeInsets.symmetric( + horizontal: 10, vertical: 8), + child: TextFormField( + style: TextStyle( + color: Colors.black45, + fontSize: 14, + letterSpacing: 0.25, + ), + decoration: InputDecoration( + labelText: "Position", + labelStyle: TextStyle( + color: Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: + OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color(0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Colors.transparent), + borderRadius: BorderRadius.all( + Radius.circular(5)))), + textInputAction: TextInputAction.next, + validator: (value) { + if (value.isEmpty) { + return 'Please provide a value.'; + } + return null; + }, + ), + ), + Row( + children: [ + Flexible( + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + Container( + margin: EdgeInsets.only( + left: 10, + right: 10, + top: 5, + bottom: 10), + child: TextField( + style: TextStyle( + fontSize: 16, + color: Color(0xff8997a7)), + decoration: InputDecoration( + labelText: "Start", + labelStyle: TextStyle( + color: + Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color( + 0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(5)))), + ), + ), + ], + ), + ), + Flexible( + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + Container( + margin: EdgeInsets.only( + left: 10, + right: 10, + top: 5, + bottom: 10), + child: TextField( + style: TextStyle( + fontSize: 16, + color: Color(0xff8997a7)), + decoration: InputDecoration( + labelText: "Till", + labelStyle: TextStyle( + color: + Color(0xff8997a7), + fontSize: 14), + filled: true, + fillColor: Colors.white, + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + errorBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Theme.of(context) + .errorColor)), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide( + color: Color( + 0xff22c0e8))), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: Colors.transparent), + borderRadius: BorderRadius.all(Radius.circular(5)))), + ), + ), + ], + ), + ), + ], + ), + ], + ), + ), + ], + )), + Padding( + padding: + EdgeInsets.symmetric(horizontal: 40, vertical: 8), + child: Material( + elevation: 3.0, + borderRadius: BorderRadius.all(Radius.circular(5)), + color: Color(0xff22c0e8), + child: MaterialButton( + onPressed: () {}, + padding: EdgeInsets.fromLTRB(15.0, 15.0, 15.0, 15.0), + // onPressed: _saveForm, + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Save', + style: TextStyle( + fontFamily: 'VarelaRound', + color: Color(0xffffffff), + fontSize: 16, + fontWeight: FontWeight.w500, + )), + ], + ), + ), + ), + ), + ], + ), + ), + ), + ); + } +} diff --git a/lib/src/ui/seeker/layout/job_details.dart b/lib/src/ui/seeker/layout/job_details.dart index 29819fd..3b23321 100644 --- a/lib/src/ui/seeker/layout/job_details.dart +++ b/lib/src/ui/seeker/layout/job_details.dart @@ -1,5 +1,6 @@ import 'package:flutter/material.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; import 'package:provider/provider.dart'; import 'package:flutter_money_formatter/flutter_money_formatter.dart'; import 'package:space/src/core/models/apply.dart'; @@ -15,21 +16,7 @@ class JobDetails extends StatefulWidget { class _JobDetailsState extends State { var _isLoading = false; - var _editJob = Job( - id: null, - title: '', - salary: 0, - description: '', - type: '', - workingday: '', - workinghour: '', - skill: '', - education: '', - industry: '', - location: '', - typeSalary: '', - gender: '', - ); + var _editJob = List(); // final bool showSaves; // JobDetails(this.showSaves); @@ -45,34 +32,34 @@ class _JobDetailsState extends State { context, listen: false, ).findById(jobId); - return Stack( - children: [ - // Container( - // child: Image.asset('assets/ketapang.png', fit: BoxFit.cover), - // ), - Scaffold( - backgroundColor: Colors.transparent, - appBar: AppBar( - automaticallyImplyLeading: true, - leading: IconButton( - onPressed: () { - Navigator.pop(context, true); - }, - icon: Icon(FeatherIcons.chevronLeft, - color: Colors.white, size: 16)), - elevation: 1, - backgroundColor: Colors.transparent, - title: Text('loadedJob.employerName', - style: TextStyle( - color: Colors.white, - fontSize: 14, - fontWeight: FontWeight.w500, - letterSpacing: 1, - )), + return Material( + color: Colors.white, + child: Stack( + children: [ + Container( + child: Image.asset('assets/ketapang.png', fit: BoxFit.cover), ), - body: SingleChildScrollView( - child: Container( - height: MediaQuery.of(context).size.height, + Scaffold( + backgroundColor: Colors.transparent, + appBar: AppBar( + automaticallyImplyLeading: true, + leading: IconButton( + onPressed: () { + Navigator.pop(context, true); + }, + icon: Icon(FeatherIcons.chevronLeft, + color: Colors.white, size: 16)), + elevation: 1, + backgroundColor: Colors.transparent, + title: Text(loadedJob.employerName, + style: TextStyle( + color: Colors.white, + fontSize: 14, + fontWeight: FontWeight.w500, + letterSpacing: 1, + )), + ), + body: Container( child: Stack( children: [ Container( @@ -168,12 +155,15 @@ class _JobDetailsState extends State { top: 50, left: 30, ), - child: ClipOval( - // child: Image.network(loadedJob.imageUrl, height: 80), - ), + child: CircleAvatar( + backgroundColor: Colors.white, + radius: 40, + child: ClipOval( + child: Image.network(loadedJob.imageUrl, height: 80), + ), + ), ), Container( - height: MediaQuery.of(context).size.height, margin: EdgeInsets.only(top: 190), padding: EdgeInsets.only(top: 10, left: 20, right: 20), decoration: BoxDecoration( @@ -181,8 +171,7 @@ class _JobDetailsState extends State { borderRadius: BorderRadius.only( topLeft: const Radius.circular(40.0), topRight: const Radius.circular(40.0))), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, + child: ListView( children: [ RichText( text: TextSpan( @@ -257,29 +246,32 @@ class _JobDetailsState extends State { SizedBox( height: 15, ), - Center( - child: RaisedButton( - child: _isLoading - ? CircularProgressIndicator() - : Text('Apply for a job', - style: TextStyle( - color: Colors.white, fontSize: 15)), - color: Color(0xff22c0e8), - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(30)), - // onPressed: (_isLoading) - // ? null - // : () async { - // setState(() { - // _isLoading = true; - // }); - // await Provider.of(context, - // listen: false) - // .addApply(_editJob); - // setState(() { - // _isLoading = false; - // }); - // }, + Padding( + padding: EdgeInsets.only(bottom: 20), + child: Center( + child: RaisedButton( + child: _isLoading + ? CircularProgressIndicator() + : Text('Apply for a job', + style: TextStyle( + color: Colors.white, fontSize: 15)), + color: Color(0xff22c0e8), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30)), + onPressed: (_isLoading) + ? null + : () async { + setState(() { + _isLoading = true; + }); + await Provider.of(context, + listen: false) + .addApply(_editJob); + setState(() { + _isLoading = false; + }); + }, + ), ), ), ], @@ -287,29 +279,22 @@ class _JobDetailsState extends State { ], ), ), + floatingActionButton: FloatingActionButton( + child: Icon(MdiIcons.bookmarkOutline, + color: Colors.white), + onPressed: () { + Scaffold.of(context).showSnackBar( + SnackBar( + duration: Duration(seconds: 1), + content: + Text('Save', style: TextStyle(color: Colors.white)), + ), + ); + }, + ), ), - // floatingActionButton: Consumer( - // builder: (ctx, job, _) => - // FloatingActionButton( - // child: Icon( - // job.isSave ? MdiIcons.bookmark : MdiIcons.bookmarkOutline, - // color: Theme.of(context).colorScheme.secondary), - // onPressed: () { - // job.toggleSavePosts( - // authData.token, - // authData.userId, - // ); - // Scaffold.of(context).showSnackBar( - // SnackBar( - // duration: Duration(seconds: 1), - // content: Text('Save', style: TextStyle(color:Colors.white)), - // ), - // ); - // }, - // ), - // ), - ), - ], + ], + ), ); } } diff --git a/lib/src/ui/seeker/layout/job_list.dart b/lib/src/ui/seeker/layout/job_list.dart index c1a838b..f798d01 100644 --- a/lib/src/ui/seeker/layout/job_list.dart +++ b/lib/src/ui/seeker/layout/job_list.dart @@ -12,8 +12,8 @@ class JobsList extends StatelessWidget { @override Widget build(BuildContext context) { final job = Provider.of(context, listen: false); - final authData = Provider.of(context, listen: false); - final cart = Provider.of(context, listen: false); + // final authData = Provider.of(context, listen: false); + // final cart = Provider.of(context, listen: false); // final save = Provider.of(context, listen: false); return Dismissible( direction: DismissDirection.endToStart, @@ -67,145 +67,103 @@ class JobsList extends StatelessWidget { alignment: Alignment(1.06, -2), children: [ ListTile( - leading: Column( + leading: + Padding( + padding: const EdgeInsets.only(top: 10.0), + child: ClipOval( + child: Image.network(job.imageUrl, + fit: BoxFit.cover, height: 40), + ), + ), + title: Container( + padding: (EdgeInsets.only(top: 5)), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + crossAxisAlignment: CrossAxisAlignment.start, children: [ - Stack( - alignment: Alignment(1, -1), - children: [ - ClipOval( - // child: Text('Image.network(job.imageUrl, fit: BoxFit.cover, height: 40)') - ), - GestureDetector( - onTap: () { - Navigator.of(context).pushNamed( - JobDetails.routeName, - arguments: job.id); - }, + Text(job.employerName, + style: + TextStyle(fontSize: 14, color: Color(0xff3b3b3b), height: 2)), + Row( + children: [ + Text(job.title, + style: TextStyle( + fontFamily: 'VarelaRound', + fontSize: 12, + color: Color(0xff3b3b3b))), + Container( + padding: EdgeInsets.only(left: 5), child: Material( - borderRadius: BorderRadius.circular(20), - color: Color(0xff22c0e8), - child: - Icon(Icons.add, color: Colors.white, size: 14), + elevation: 1.0, + borderRadius: BorderRadius.circular(5.0), + color: Color(0xff65be3e), + child: Container( + padding: EdgeInsets.symmetric(horizontal: 4), + child: Text(job.type, + style: TextStyle( + color: Colors.white, fontSize: 9, height: 1.3)), + ), ), ), ], ), + Row( + children: [ + Icon(Icons.location_on, + size: 10, color: Color(0xff8997a7)), + Flexible( + child: Text(job.location, + overflow: TextOverflow.ellipsis, + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7), height: 1.3))), + ], + ), + Row( + children: [ + Text('Salary: ', + style: TextStyle( + fontSize: 10, color: Color(0xff8997a7), height: 1.3)), + Text( + FlutterMoneyFormatter( + amount: job.salary, + settings: MoneyFormatterSettings( + symbol: 'Rp', + thousandSeparator: '.', + fractionDigits: 0)) + .output + .symbolOnLeft, + style: TextStyle( + fontSize: 10, color: Color(0xff3b3b3b), height: 1.3)), + ], + ), ], ), - title: Container( - height: 50, - padding: (EdgeInsets.only(top: 5)), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text('job.employerName', - style: TextStyle( - fontSize: 14, color: Color(0xff3b3b3b))), - Row( - children: [ - Text(job.title, - style: TextStyle( - fontFamily: 'VarelaRound', - fontSize: 12, - color: Color(0xff3b3b3b))), - Container( - padding: EdgeInsets.only(left: 5), - child: Material( - elevation: 1.0, - borderRadius: BorderRadius.circular(5.0), - color: Color(0xff65be3e), - child: Container( - padding: EdgeInsets.symmetric(horizontal: 4), - child: Text('Full Time', - style: TextStyle( - color: Colors.white, fontSize: 9)), - ), - ), - ), - ], - ), - ], - ), - ), - subtitle: Container( - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Row( - children: [ - Icon(Icons.location_on, - size: 10, color: Color(0xff8997a7)), - Flexible( - child: Text('job.location', - overflow: TextOverflow.ellipsis, - style: TextStyle( - fontSize: 12, color: Color(0xff8997a7)))), - ], - ), - Row( - children: [ - Text('Salary: ', - style: TextStyle( - fontSize: 10, color: Color(0xff8997a7))), - Text( - FlutterMoneyFormatter( - amount: job.salary, - settings: MoneyFormatterSettings( - symbol: 'Rp', - thousandSeparator: '.', - fractionDigits: 0)) - .output - .symbolOnLeft, - style: TextStyle( - fontSize: 10, color: Color(0xff3b3b3b))), - ], - ), - ], - ), - ), - onTap: () { - cart.addItem(job.id, job.salary, job.title); - Scaffold.of(context).hideCurrentSnackBar(); - Scaffold.of(context).showSnackBar( - SnackBar( - content: Text( - 'Added item to cart!', - ), - duration: Duration(seconds: 2), - action: SnackBarAction( - label: 'UNDO', - onPressed: () { - cart.removeSingleItem(job.id); - }, - ), - ), - ); - }), - Padding( - padding: EdgeInsets.only(top: 6), - child: Consumer( - builder: (ctx, job, _) => IconButton( - icon: Icon( - job.isSave ? MdiIcons.bookmark : MdiIcons.bookmarkOutline, - color: Theme.of(context).colorScheme.onPrimary), - onPressed: () { - job.toggleSavePosts( - authData.token, - authData.userId, - ); - Scaffold.of(context).showSnackBar( - SnackBar( - duration: Duration(seconds: 1), - content: - Text('Save', style: TextStyle(color: Colors.white)), - ), - ); - }, - ), ), + onTap: () { + Navigator.of(context) + .pushNamed(JobDetails.routeName, arguments: job.id); + }, ), + // Padding( + // padding: EdgeInsets.only(top: 6), + // child: Consumer( + // builder: (ctx, job, _) => IconButton( + // icon: Icon( + // job.isSave ? MdiIcons.bookmark : MdiIcons.bookmarkOutline, + // color: Theme.of(context).colorScheme.onPrimary), + // onPressed: () { + // job.toggleSavePosts(); + // Scaffold.of(context).showSnackBar( + // SnackBar( + // duration: Duration(seconds: 1), + // content: + // Text('Save', style: TextStyle(color: Colors.white)), + // ), + // ); + // }, + // ), + // ), + // ), ], ), ), diff --git a/lib/src/ui/seeker/layout/job_search.dart b/lib/src/ui/seeker/layout/job_search.dart index edf229a..99d7b02 100644 --- a/lib/src/ui/seeker/layout/job_search.dart +++ b/lib/src/ui/seeker/layout/job_search.dart @@ -8,7 +8,6 @@ class JobSearch extends StatefulWidget { } class _JobSearchState extends State { - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); String dropdownValue = 'Rp.0 - Rp.1.000.000'; double _sliderValue = 20.0; bool fulltime = false; @@ -28,21 +27,20 @@ class _JobSearchState extends State { minHeight: viewportConstraints.maxHeight, ), child: Container( - padding: EdgeInsets.only(top: 50), child: Column( + mainAxisAlignment: MainAxisAlignment.center, mainAxisSize: MainAxisSize.min, children: [ Text('SEARCH FOR A JOB', textAlign: TextAlign.center, - style: style.copyWith( + style: TextStyle( color: Color(0xff2c4057), - fontSize: 13, + fontSize: 18, fontWeight: FontWeight.bold, fontStyle: FontStyle.normal, - letterSpacing: 1, )), Container( - margin: EdgeInsets.only(top: 15, bottom: 20), + margin: EdgeInsets.only(top: 15, bottom: 50), width: 100, color: Color(0xff22c0e8), child: Divider( @@ -51,18 +49,17 @@ class _JobSearchState extends State { ), Container( height: 180, - width: 300, + width: 280, child: Column( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ TextField( - style: style.copyWith( - fontSize: 16, color: Colors.black54), + style: TextStyle(fontSize: 12, color: Colors.black54), decoration: new InputDecoration( contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), hintText: "Keywords (e.g. Job Title...)", - hintStyle: style.copyWith(fontSize: 16), + hintStyle: TextStyle(fontSize: 12), filled: true, fillColor: Color(0xffdcdfe3), enabledBorder: OutlineInputBorder( @@ -77,13 +74,12 @@ class _JobSearchState extends State { ), ), TextField( - style: style.copyWith( - fontSize: 16, color: Colors.black54), + style: TextStyle(fontSize: 12, color: Colors.black54), decoration: new InputDecoration( contentPadding: EdgeInsets.fromLTRB(20.0, 15.0, 20.0, 15.0), hintText: "Location (e.g. City, Zip...)", - hintStyle: style.copyWith(fontSize: 15), + hintStyle: TextStyle(fontSize: 12), filled: true, fillColor: Color(0xffdcdfe3), enabledBorder: OutlineInputBorder( @@ -104,7 +100,7 @@ class _JobSearchState extends State { contentPadding: EdgeInsets.fromLTRB(30.0, 0.0, 25.0, 0.0), errorStyle: TextStyle( - color: Colors.redAccent, fontSize: 16.0), + color: Colors.redAccent, fontSize: 12.0), filled: true, fillColor: Color(0xffdcdfe3), enabledBorder: OutlineInputBorder( @@ -134,9 +130,9 @@ class _JobSearchState extends State { return DropdownMenuItem( value: value, child: new Text(value, - style: style.copyWith( + style: TextStyle( color: Colors.black54, - fontSize: 14, + fontSize: 12, fontStyle: FontStyle.normal, letterSpacing: 0.25, )), @@ -168,8 +164,8 @@ class _JobSearchState extends State { }, ), Text('Fulltime', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7))), ], ), @@ -185,8 +181,8 @@ class _JobSearchState extends State { }, ), Text('Partime', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7))), ], ), @@ -206,8 +202,8 @@ class _JobSearchState extends State { }, ), Text('Weekend', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7))), ], ), @@ -223,8 +219,8 @@ class _JobSearchState extends State { }, ), Text('Freelance', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7))), ], ), @@ -238,16 +234,16 @@ class _JobSearchState extends State { child: Row( children: [ Text('Distance', - style: style.copyWith( - fontSize: 14, color: Color(0xff8997a7))), + style: TextStyle( + fontSize: 12, color: Color(0xff8997a7))), Text(' ${_sliderValue.toInt()}', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff22c0e8))), Text(' km', - style: style.copyWith( - fontSize: 14, + style: TextStyle( + fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff22c0e8))), ], @@ -266,32 +262,25 @@ class _JobSearchState extends State { ), ), Container( - padding: EdgeInsets.only(left: 30, right: 30), - child: Material( - elevation: 3.0, - borderRadius: BorderRadius.circular(30.0), + child: MaterialButton( + height: 45, + minWidth: 280, + elevation: 3.0, + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), color: Color(0xff57b22f), - child: MaterialButton( - padding: EdgeInsets.fromLTRB(60.0, 15.0, 20.0, 15.0), onPressed: () { Navigator.push( context, new MaterialPageRoute( builder: (context) => new JobSearchResult())); }, - child: Row( - children: [ - Text('Search for a job', - textAlign: TextAlign.center, - style: style.copyWith(color: Colors.white)), - const Expanded( - child: Icon(Icons.arrow_forward, - color: Colors.white)), - ], - ), + child: Text('Search for a job', + textAlign: TextAlign.center, + style: + TextStyle(color: Colors.white, fontSize: 16)), ), ), - ), + ], ), ), diff --git a/lib/src/ui/seeker/layout/order_item.dart b/lib/src/ui/seeker/layout/order_item.dart index d4e7caa..75c5bc1 100644 --- a/lib/src/ui/seeker/layout/order_item.dart +++ b/lib/src/ui/seeker/layout/order_item.dart @@ -1,79 +1,71 @@ -import 'dart:math'; +// import 'dart:math'; -import 'package:flutter/material.dart'; -import 'package:intl/intl.dart'; +// import 'package:flutter/material.dart'; +// import 'package:intl/intl.dart'; -import '../../../core/models/apply.dart' as ord; +// import '../../../core/models/apply.dart' as ord; -class ApplyItem extends StatefulWidget { - final ord.ApplyItem apply; +// class ApplyItem extends StatefulWidget { +// final ord.ApplyItem apply; - ApplyItem(this.apply); +// ApplyItem(this.apply); - @override - _ApplyItemState createState() => _ApplyItemState(); -} +// @override +// _ApplyItemState createState() => _ApplyItemState(); +// } -class _ApplyItemState extends State { - var _expanded = false; +// class _ApplyItemState extends State { +// var _expanded = false; - @override - Widget build(BuildContext context) { - return AnimatedContainer( - duration: Duration(milliseconds: 300), - height: - _expanded ? min(widget.apply.jobs.length * 20.0 + 110, 200) : 95, - child: Card( - margin: EdgeInsets.all(10), - child: Column( - children: [ - ListTile( - title: Text('\$${widget.apply.amount}'), - subtitle: Text( - DateFormat('dd/MM/yyyy hh:mm').format(widget.apply.dateTime), - ), - trailing: IconButton( - icon: Icon(_expanded ? Icons.expand_less : Icons.expand_more), - onPressed: () { - setState(() { - _expanded = !_expanded; - }); - }, - ), - ), - AnimatedContainer( - duration: Duration(milliseconds: 300), - padding: EdgeInsets.symmetric(horizontal: 15, vertical: 4), - height: _expanded ? min(widget.apply.jobs.length * 20.0 + 10, 100) : 0, - child: ListView( - children: widget.apply.jobs - .map( - (prod) => Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text( - prod.title, - style: TextStyle( - fontSize: 18, - fontWeight: FontWeight.bold, - ), - ), - Text( - '${prod.quantity}x \$${prod.price}', - style: TextStyle( - fontSize: 18, - color: Colors.grey, - ), - ) - ], - ), - ) - .toList(), - ), - ) - ], - ), - ), - ); - } -} +// @override +// Widget build(BuildContext context) { +// return AnimatedContainer( +// duration: Duration(milliseconds: 300), +// height: +// _expanded ? min(widget.apply.job.length * 20.0 + 110, 200) : 95, +// child: Card( +// margin: EdgeInsets.all(10), +// child: Column( +// children: [ +// ListTile( +// subtitle: Text( +// DateFormat('dd/MM/yyyy hh:mm').format(widget.apply.dateTime), +// ), +// trailing: IconButton( +// icon: Icon(_expanded ? Icons.expand_less : Icons.expand_more), +// onPressed: () { +// setState(() { +// _expanded = !_expanded; +// }); +// }, +// ), +// ), +// AnimatedContainer( +// duration: Duration(milliseconds: 300), +// padding: EdgeInsets.symmetric(horizontal: 15, vertical: 4), +// height: _expanded ? min(widget.apply.job.length * 20.0 + 10, 100) : 0, +// child: ListView( +// children: widget.apply.job +// .map( +// (prod) => Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// Text( +// prod.title, +// style: TextStyle( +// fontSize: 18, +// fontWeight: FontWeight.bold, +// ), +// ), +// ], +// ), +// ) +// .toList(), +// ), +// ) +// ], +// ), +// ), +// ); +// } +// } diff --git a/lib/src/ui/seeker/layout/saved_lists.dart b/lib/src/ui/seeker/layout/saved_lists.dart index 29eab93..72cc9af 100644 --- a/lib/src/ui/seeker/layout/saved_lists.dart +++ b/lib/src/ui/seeker/layout/saved_lists.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; import 'package:flutter_money_formatter/flutter_money_formatter.dart'; import 'package:space/src/core/models/job.dart'; +import 'package:space/src/core/models/save.dart'; import 'package:space/src/ui/seeker/layout/job_details.dart'; @@ -12,7 +13,7 @@ class SavePosts extends StatelessWidget { return Dismissible( direction: DismissDirection.endToStart, onDismissed: (direction) { - // Provider.of(context, listen: false).removeItem(jobId); + Provider.of(context, listen: false).removeItem(job.id); }, key: ValueKey(job.id), background: Container( @@ -35,7 +36,7 @@ class SavePosts extends StatelessWidget { alignment: Alignment(1, -1), children: [ ClipOval( - // child: Image.network(imageUrl, fit: BoxFit.cover, height: 40) + child: Image.network(job.imageUrl, fit: BoxFit.cover, height: 40) ), GestureDetector( onTap: () { diff --git a/lib/src/ui/components/seeker_app_bar.dart b/lib/src/ui/seeker/layout/seeker_app_bar.dart similarity index 56% rename from lib/src/ui/components/seeker_app_bar.dart rename to lib/src/ui/seeker/layout/seeker_app_bar.dart index 1224b59..de1dadc 100644 --- a/lib/src/ui/components/seeker_app_bar.dart +++ b/lib/src/ui/seeker/layout/seeker_app_bar.dart @@ -1,15 +1,15 @@ import 'package:flutter/material.dart'; +import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; import 'package:provider/provider.dart'; import 'package:space/src/core/models/cart.dart'; +import 'package:space/src/ui/seeker/layout/cv.dart'; import 'package:space/src/ui/seeker/screens/cart_screen.dart'; -import 'badge.dart'; - - class SeekerAppBar extends StatelessWidget { @override Widget build(BuildContext context) { return SliverAppBar( + iconTheme: IconThemeData(color: Color(0xff3b3b3b)), floating: true, pinned: true, snap: true, @@ -17,34 +17,31 @@ class SeekerAppBar extends StatelessWidget { centerTitle: true, title: SizedBox( child: Image.asset('assets/logo_vertical.png'), - height: 30, + height: 60, ), actions: [ - Consumer( - builder: (_, cart, ch) => Badge( - child: ch, - value: cart.itemCount.toString(), - ), - child: IconButton( - icon: Icon( - Icons.shopping_cart, - ), - onPressed: () { - Navigator.of(context).pushNamed(CartScreen.routeName); - }, - ), - ), + IconButton( + icon: Icon(MdiIcons.accountDetails), + iconSize: 28, + onPressed: () { + Navigator.push( + context, + MaterialPageRoute(builder: (context) => CVSeeker()), + ); + }, + ) ], bottom: TabBar( + unselectedLabelColor: Color(0xff3b3b3b), indicatorColor: Colors.yellow[700], labelColor: Colors.yellow[700], labelStyle: TextStyle(fontSize: 14, color: Colors.yellow[700]), unselectedLabelStyle: TextStyle(color: Color(0xff000000)), tabs: [ - Tab(text: 'New'), - Tab(text: 'Applied'), - Tab(text: 'Saved'), - ], + Tab(text: 'New'), + Tab(text: 'Applied'), + Tab(text: 'Saved'), + ], ), ); } diff --git a/lib/src/ui/seeker/layout/seeker_profile_setting.dart b/lib/src/ui/seeker/layout/seeker_profile_setting.dart index 21cabd9..b8e1814 100644 --- a/lib/src/ui/seeker/layout/seeker_profile_setting.dart +++ b/lib/src/ui/seeker/layout/seeker_profile_setting.dart @@ -144,6 +144,7 @@ class _SettingSeekerProfileState extends State ), ), Container( + height: MediaQuery.of(context).size.height, margin: EdgeInsets.only(top: 15), decoration: BoxDecoration( color: Colors.white, @@ -153,7 +154,6 @@ class _SettingSeekerProfileState extends State ), ), child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, crossAxisAlignment: CrossAxisAlignment.start, children: [ ListTile( diff --git a/lib/src/ui/seeker/screens/applys_screen.dart b/lib/src/ui/seeker/screens/applys_screen.dart index c8f5589..b62e366 100644 --- a/lib/src/ui/seeker/screens/applys_screen.dart +++ b/lib/src/ui/seeker/screens/applys_screen.dart @@ -1,40 +1,40 @@ -import 'package:flutter/material.dart'; -import 'package:provider/provider.dart'; +// import 'package:flutter/material.dart'; +// import 'package:provider/provider.dart'; -import 'package:space/src/core/models/apply.dart' show Applys; -import 'package:space/src/ui/seeker/layout/apply_post.dart'; +// import 'package:space/src/core/models/apply.dart' show Applys; +// import 'package:space/src/ui/seeker/layout/apply_post.dart'; -class ApplysScreen extends StatelessWidget { - static const routeName = '/orders'; +// class ApplysScreen extends StatelessWidget { +// static const routeName = '/Applys'; - @override - Widget build(BuildContext context) { - print('building orders'); - // final applyData = Provider.of(context); - return Scaffold( - body: FutureBuilder( - future: Provider.of(context, listen: false).fetchAndSetApplys(), - builder: (ctx, dataSnapshot) { - if (dataSnapshot.connectionState == ConnectionState.waiting) { - return Center(child: CircularProgressIndicator()); - } else { - if (dataSnapshot.error != null) { - // ... - // Do error handling stuff - return Center( - child: Text('An error occurred!'), - ); - } else { - return Consumer( - builder: (ctx, applyData, child) => ListView.builder( - itemCount: applyData.applys.length, - itemBuilder: (ctx, i) => ApplyItem(applyData.applys[i]), - ), - ); - } - } - }, - ), - ); - } -} +// @override +// Widget build(BuildContext context) { +// print('building Applys'); +// // final applyData = Provider.of(context); +// return Scaffold( +// body: FutureBuilder( +// future: Provider.of(context, listen: false).fetchAndSetApplys(), +// builder: (ctx, dataSnapshot) { +// if (dataSnapshot.connectionState == ConnectionState.waiting) { +// return Center(child: CircularProgressIndicator()); +// } else { +// if (dataSnapshot.error != null) { +// // ... +// // Do error handling stuff +// return Center( +// child: Text('An error occurred!'), +// ); +// } else { +// return Consumer( +// builder: (ctx, applyData, child) => ListView.builder( +// itemCount: applyData.applys.length, +// itemBuilder: (ctx, i) => ApplyPost(applyData.applys[i]), +// ), +// ); +// } +// } +// }, +// ), +// ); +// } +// } diff --git a/lib/src/ui/seeker/screens/cart_screen.dart b/lib/src/ui/seeker/screens/cart_screen.dart index 46dfc02..6320e4b 100644 --- a/lib/src/ui/seeker/screens/cart_screen.dart +++ b/lib/src/ui/seeker/screens/cart_screen.dart @@ -1,102 +1,102 @@ -import 'package:flutter/material.dart'; -import 'package:provider/provider.dart'; -import 'package:space/src/core/models/apply.dart'; +// import 'package:flutter/material.dart'; +// import 'package:provider/provider.dart'; +// import 'package:space/src/core/models/apply.dart'; -import 'package:space/src/core/models/cart.dart' show Cart; -import 'package:space/src/ui/seeker/layout/cart_item.dart'; +// import 'package:space/src/core/models/cart.dart' show Cart; +// import 'package:space/src/ui/seeker/layout/cart_item.dart'; -class CartScreen extends StatelessWidget { - static const routeName = '/cart'; +// class CartScreen extends StatelessWidget { +// static const routeName = '/cart'; - @override - Widget build(BuildContext context) { - final cart = Provider.of(context); - return Scaffold( - appBar: AppBar( - title: Text('Your Cart'), - ), - body: Column( - children: [ - Card( - margin: EdgeInsets.all(15), - child: Padding( - padding: EdgeInsets.all(8), - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text( - 'Total', - style: TextStyle(fontSize: 20), - ), - Spacer(), - Chip( - label: Text( - '\$${cart.totalAmount.toStringAsFixed(2)}', - style: TextStyle( - color: Theme.of(context).primaryTextTheme.title.color, - ), - ), - backgroundColor: Theme.of(context).primaryColor, - ), - OrderButton(cart: cart) - ], - ), - ), - ), - SizedBox(height: 10), - Expanded( - child: ListView.builder( - itemCount: cart.items.length, - itemBuilder: (ctx, i) => CartItem( - cart.items.values.toList()[i].id, - cart.items.keys.toList()[i], - cart.items.values.toList()[i].price, - cart.items.values.toList()[i].quantity, - cart.items.values.toList()[i].title, - ), - ), - ) - ], - ), - ); - } -} +// @override +// Widget build(BuildContext context) { +// final cart = Provider.of(context); +// return Scaffold( +// appBar: AppBar( +// title: Text('Your Cart'), +// ), +// body: Column( +// children: [ +// Card( +// margin: EdgeInsets.all(15), +// child: Padding( +// padding: EdgeInsets.all(8), +// child: Row( +// mainAxisAlignment: MainAxisAlignment.spaceBetween, +// children: [ +// Text( +// 'Total', +// style: TextStyle(fontSize: 20), +// ), +// Spacer(), +// Chip( +// label: Text( +// '\$${cart.totalAmount.toStringAsFixed(2)}', +// style: TextStyle( +// color: Theme.of(context).primaryTextTheme.title.color, +// ), +// ), +// backgroundColor: Theme.of(context).primaryColor, +// ), +// OrderButton(cart: cart) +// ], +// ), +// ), +// ), +// SizedBox(height: 10), +// Expanded( +// child: ListView.builder( +// itemCount: cart.items.length, +// itemBuilder: (ctx, i) => CartItem( +// cart.items.values.toList()[i].id, +// cart.items.keys.toList()[i], +// cart.items.values.toList()[i].price, +// cart.items.values.toList()[i].quantity, +// cart.items.values.toList()[i].title, +// ), +// ), +// ) +// ], +// ), +// ); +// } +// } -class OrderButton extends StatefulWidget { - const OrderButton({ - Key key, - @required this.cart, - }) : super(key: key); +// class OrderButton extends StatefulWidget { +// const OrderButton({ +// Key key, +// @required this.cart, +// }) : super(key: key); - final Cart cart; +// final Cart cart; - @override - _OrderButtonState createState() => _OrderButtonState(); -} +// @override +// _OrderButtonState createState() => _OrderButtonState(); +// } -class _OrderButtonState extends State { - var _isLoading = false; +// class _OrderButtonState extends State { +// var _isLoading = false; - @override - Widget build(BuildContext context) { - return FlatButton( - child: _isLoading ? CircularProgressIndicator() : Text('ORDER NOW'), - onPressed: (widget.cart.totalAmount <= 0 || _isLoading) - ? null - : () async { - setState(() { - _isLoading = true; - }); - await Provider.of(context, listen: false).addApply( - widget.cart.items.values.toList(), - widget.cart.totalAmount, - ); - setState(() { - _isLoading = false; - }); - widget.cart.clear(); - }, - textColor: Theme.of(context).colorScheme.onSecondary, - ); - } -} +// @override +// Widget build(BuildContext context) { +// return FlatButton( +// child: _isLoading ? CircularProgressIndicator() : Text('ORDER NOW'), +// onPressed: (widget.cart.totalAmount <= 0 || _isLoading) +// ? null +// : () async { +// setState(() { +// _isLoading = true; +// }); +// await Provider.of(context, listen: false).addApply( +// widget.cart.items.values.toList(), +// widget.cart.totalAmount, +// ); +// setState(() { +// _isLoading = false; +// }); +// widget.cart.clear(); +// }, +// textColor: Theme.of(context).colorScheme.onSecondary, +// ); +// } +// } diff --git a/lib/src/ui/seeker/screens/jobs_list_screen.dart b/lib/src/ui/seeker/screens/jobs_list_screen.dart index 304f624..b6ff2c6 100644 --- a/lib/src/ui/seeker/screens/jobs_list_screen.dart +++ b/lib/src/ui/seeker/screens/jobs_list_screen.dart @@ -9,25 +9,8 @@ class JobsListScreen extends StatefulWidget { } class _JobsListScreenState extends State { - var _isInit = true; var _isLoading = false; - @override - void didChangeDependencies() { - if (_isInit) { - setState(() { - _isLoading = true; - }); - Provider.of(context).fetchAndSetJobs().then((_) { - setState(() { - _isLoading = false; - }); - }); - } - _isInit = false; - super.didChangeDependencies(); - } - @override Widget build(BuildContext context) { final jobData = Provider.of(context); diff --git a/lib/src/ui/seeker/screens/seeker_tabs.dart b/lib/src/ui/seeker/screens/seeker_tabs.dart index 2ada651..0ae0734 100644 --- a/lib/src/ui/seeker/screens/seeker_tabs.dart +++ b/lib/src/ui/seeker/screens/seeker_tabs.dart @@ -1,7 +1,8 @@ import 'package:flutter/material.dart'; +import 'package:space/src/ui/seeker/layout/apply_post.dart'; +import 'package:space/src/ui/seeker/layout/seeker_app_bar.dart'; import 'package:space/src/ui/seeker/widgets/seeker_app_drawer.dart'; -import 'package:space/src/ui/components/seeker_app_bar.dart'; import 'package:space/src/ui/seeker/screens/applys_screen.dart'; import 'package:space/src/ui/seeker/screens/jobs_list_screen.dart'; import 'package:space/src/ui/seeker/screens/save_screen.dart'; @@ -27,7 +28,7 @@ class SeekerTabs extends StatelessWidget { // }, // child: JobsListScreen(), - ApplysScreen(), + JobsListScreen(), SaveListScreen(_showSaves), ], ), diff --git a/lib/src/ui/settings/setting_payment_method.dart b/lib/src/ui/settings/setting_payment_method.dart index db35924..da08bcc 100644 --- a/lib/src/ui/settings/setting_payment_method.dart +++ b/lib/src/ui/settings/setting_payment_method.dart @@ -166,16 +166,15 @@ class _PaymentMethodState extends State with SingleTickerProvider Text('SAVE CARD', style: style.copyWith(fontSize: 12, fontWeight: FontWeight.bold)), ],), - Padding( - padding: const EdgeInsets.only(right: 155), + Container( + width: 100, child: RaisedButton( shape: RoundedRectangleBorder(borderRadius: new BorderRadius.circular(10.0)), color: Color(0xff22c0e8), child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, + mainAxisAlignment: MainAxisAlignment.center, children: [ Text('ADD CARD', style: style.copyWith(fontSize: 12, color: Colors.white)), - Icon(Icons.arrow_forward, size: 18, color: Colors.white) ],), onPressed: () { if (_formKey.currentState.validate()) { @@ -231,134 +230,137 @@ class _PaymentMethodState extends State with SingleTickerProvider context: context, builder: (BuildContext context) { return AlertDialog( - content: Form( - key: _formKey, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - Text('Add GoPay', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), - Text('Phone Number', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, height: 2)), - Row( - children: [ - Flexible( - child: Container( - width: 40, - margin: EdgeInsets.only(top: 5, right: 10), - child: TextField( - style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), - decoration: InputDecoration( - contentPadding: EdgeInsets.all(10), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(10.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - ), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(10.0), + content: ListView(children: [ + Form( + key: _formKey, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, + children: [ + Text('Add GoPay', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), + Text('Phone Number', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, height: 2)), + Row( + children: [ + Flexible( + child: Container( + width: 40, + margin: EdgeInsets.only(top: 5, right: 10), + child: TextField( + style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), + decoration: InputDecoration( + contentPadding: EdgeInsets.all(10), + enabledBorder: OutlineInputBorder( + borderRadius: BorderRadius.circular(10.0), + borderSide: BorderSide(color: Colors.transparent, width: 1), + ), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), + borderRadius: BorderRadius.circular(10.0), + ), + fillColor: Color(0xffdcdfe3), + filled: true, ), - fillColor: Color(0xffdcdfe3), - filled: true, + ), ), - ), - ), - ), - - Flexible( - child: Container( - margin: EdgeInsets.only(top: 5), - child: TextField( - style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), - decoration: InputDecoration( - focusColor: Colors.yellow, - contentPadding: EdgeInsets.all(10), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(10.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), + ), + + Flexible( + child: Container( + margin: EdgeInsets.only(top: 5), + child: TextField( + style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), + decoration: InputDecoration( + focusColor: Colors.yellow, + contentPadding: EdgeInsets.all(10), + enabledBorder: OutlineInputBorder( + borderRadius: BorderRadius.circular(10.0), + borderSide: BorderSide(color: Colors.transparent, width: 1), + ), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), + borderRadius: BorderRadius.circular(10.0), + ), + fillColor: Color(0xffdcdfe3), + filled: true, ), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(10.0), - ), - fillColor: Color(0xffdcdfe3), - filled: true, + ), ), - ), - ), - ), - ],), - - - - Row(children: [ - Flexible( - child: Container( - padding: EdgeInsets.only(top: 30, bottom: 10, right: 10), - child: RaisedButton( - shape: RoundedRectangleBorder(borderRadius: new BorderRadius.circular(10.0)), - color: Color(0xff22c0e8), - onPressed: () { - if (_formKey.currentState.validate()) { - _formKey.currentState.save(); - } - }, - child: Text('SEND OTP', style: style.copyWith(fontSize: 10, color: Colors.white)), ), - ) - ), - Flexible( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text('OTP', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, height: 2)), - Container( - margin: EdgeInsets.only(right: 30), - child: TextField( - style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), - decoration: InputDecoration( - focusColor: Colors.yellow, - contentPadding: EdgeInsets.all(10), - enabledBorder: OutlineInputBorder( - borderRadius: BorderRadius.circular(10.0), - borderSide: BorderSide(color: Colors.transparent, width: 1), - ), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), - borderRadius: BorderRadius.circular(10.0), + ],), + + + + Row(children: [ + Flexible( + child: Container( + padding: EdgeInsets.only(top: 30, bottom: 10, right: 10), + child: RaisedButton( + shape: RoundedRectangleBorder(borderRadius: new BorderRadius.circular(10.0)), + color: Color(0xff22c0e8), + onPressed: () { + if (_formKey.currentState.validate()) { + _formKey.currentState.save(); + } + }, + child: Text('SEND OTP', style: style.copyWith(fontSize: 10, color: Colors.white)), ), - fillColor: Color(0xffdcdfe3), - filled: true, + ) ), - ), - ), - ],), - ), - ],), - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text('By continuing, you agree to :', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), - Text('- Dreamjob Terms of Service', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), - Text('- GoPay Terms of Service', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold, height: 2)), - ],), - - Container( - width: 400, - padding: EdgeInsets.symmetric(horizontal: 10), - child: RaisedButton( - shape: RoundedRectangleBorder(borderRadius: new BorderRadius.circular(10.0)), - color: Color(0xff22c0e8), - onPressed: () { - if (_formKey.currentState.validate()) { - _formKey.currentState.save(); - } - }, - child: Text('Continue', style: style.copyWith(fontSize: 12, color: Colors.white)), + Flexible( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('OTP', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, height: 2)), + Container( + margin: EdgeInsets.only(right: 30), + child: TextField( + style: style.copyWith(fontSize: 16, color: Color(0xff8997a7)), + decoration: InputDecoration( + focusColor: Colors.yellow, + contentPadding: EdgeInsets.all(10), + enabledBorder: OutlineInputBorder( + borderRadius: BorderRadius.circular(10.0), + borderSide: BorderSide(color: Colors.transparent, width: 1), + ), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: Color(0xff22c0e8), width: 1), + borderRadius: BorderRadius.circular(10.0), + ), + fillColor: Color(0xffdcdfe3), + filled: true, + ), + ), ), - ) - ], - ), - ), + ],), + ), + ],), + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('By continuing, you agree to :', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), + Text('- Dreamjob Terms of Service', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold)), + Text('- GoPay Terms of Service', style: style.copyWith(fontSize: 14, fontWeight: FontWeight.bold, height: 2)), + ],), + + Container( + width: 400, + padding: EdgeInsets.symmetric(horizontal: 10), + child: RaisedButton( + shape: RoundedRectangleBorder(borderRadius: new BorderRadius.circular(10.0)), + color: Color(0xff22c0e8), + onPressed: () { + if (_formKey.currentState.validate()) { + _formKey.currentState.save(); + } + }, + child: Text('Continue', style: style.copyWith(fontSize: 12, color: Colors.white)), + ), + ) + ], + ), + ), + ], + ), ); }); diff --git a/lib/src/ui/settings/setting_ui_help.dart b/lib/src/ui/settings/setting_ui_help.dart index 295bb52..b09e955 100644 --- a/lib/src/ui/settings/setting_ui_help.dart +++ b/lib/src/ui/settings/setting_ui_help.dart @@ -1,20 +1,6 @@ import 'package:flutter/material.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; -void main() => runApp(MyApp()); - -class MyApp extends StatelessWidget { - - @override - Widget build(BuildContext context) { - return MaterialApp( - title: 'Flutter Slidable Demo', - home: SettingUiHelp(title: 'Flutter Slidable Demo'), - ); - } -} - - class SettingUiHelp extends StatefulWidget { const SettingUiHelp({ Key key, String title }) : super(key: key); @override @@ -23,7 +9,7 @@ class SettingUiHelp extends StatefulWidget { class _SettingUiHelpState extends State with SingleTickerProviderStateMixin { - TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 20.0); + TextStyle style = TextStyle(fontFamily: 'VarelaRound', fontSize: 16.0); @override Widget build(BuildContext context) { @@ -34,11 +20,11 @@ class _SettingUiHelpState extends State with SingleTickerProvider onPressed: () { Navigator.pop(context,true); }, - icon: Icon(FeatherIcons.chevronLeft, color: Color(0xff2c4057), size: 16)), + icon: Icon(FeatherIcons.chevronLeft, color: Color(0xff2c4057), size: 14)), elevation: 1, backgroundColor: Colors.white, title: Text('Help', style: style.copyWith(color: Color(0xff2c4057), - fontSize: 14, fontWeight: FontWeight.w500,letterSpacing: 1,)), + fontSize: 12, fontWeight: FontWeight.w500,letterSpacing: 1,)), ), body: Container( @@ -47,12 +33,12 @@ class _SettingUiHelpState extends State with SingleTickerProvider crossAxisAlignment: CrossAxisAlignment.start, children: [ Padding( - padding: EdgeInsets.all(20), + padding: EdgeInsets.all(10), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Text('Help', style: style.copyWith(fontWeight: FontWeight.bold, color: Color(0xff3b3b3b))), - Text('Get in touch', style: style.copyWith(fontSize: 14, color: Color(0xff3b3b3b))), + Text('Help', style: style.copyWith(fontWeight: FontWeight.bold, color: Color(0xff3b3b3b), fontSize: 16)), + Text('Get in touch', style: style.copyWith(fontSize: 12, color: Color(0xff3b3b3b))), ],), ), Container( @@ -61,8 +47,7 @@ class _SettingUiHelpState extends State with SingleTickerProvider ), Container( - width: MediaQuery.of(context).size.width, - margin: EdgeInsets.all(20), + margin: EdgeInsets.all(10), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ @@ -88,9 +73,9 @@ class _SettingUiHelpState extends State with SingleTickerProvider crossAxisAlignment: CrossAxisAlignment.start, children: [ Text('Pontianak West Borneo, Indonesia', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101))), - Text('Dreamjob.id@gmail.com', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), - Text('Dreamjob Indonesia', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), - Text('Dreamjob.id', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), + Text('LogoName.id@gmail.com', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), + Text('LogoName Indonesia', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), + Text('LogoName.id', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), Text('+62 812 3456 7890', style: style.copyWith(fontSize: 11, fontWeight: FontWeight.bold, color: Color(0xff010101), height: 2)), ],), ), diff --git a/lib/src/ui/settings/setting_ui_payment.dart b/lib/src/ui/settings/setting_ui_payment.dart index 5aae15d..f460278 100644 --- a/lib/src/ui/settings/setting_ui_payment.dart +++ b/lib/src/ui/settings/setting_ui_payment.dart @@ -1,31 +1,6 @@ import 'package:flutter/material.dart'; import 'package:feather_icons_flutter/feather_icons_flutter.dart'; import 'package:space/src/ui/settings/setting_payment_method.dart'; - -void main() { - runApp(MaterialApp( - title: 'Named Routes Demo', - initialRoute: '/', - routes: { - '/': (context) => SettingUIPayment(), - 'space/setting_payment_method': (context) => PaymentMethod(), - }, - )); -} - - -class MyApp extends StatelessWidget { - - @override - Widget build(BuildContext context) { - return MaterialApp( - title: 'Flutter Slidable Demo', - home: SettingUIPayment(title: 'Flutter Slidable Demo'), - ); - } -} - - class SettingUIPayment extends StatefulWidget { const SettingUIPayment({ Key key, String title }) : super(key: key); @override diff --git a/pubspec.lock b/pubspec.lock index 29db568..1f9b96e 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -36,6 +36,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.0.5" + carousel_pro: + dependency: "direct main" + description: + name: carousel_pro + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.0" carousel_slider: dependency: "direct main" description: @@ -50,6 +57,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.1.2" + circular_bottom_navigation: + dependency: "direct main" + description: + name: circular_bottom_navigation + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.1" collection: dependency: transitive description: @@ -174,6 +188,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "0.5.4" + flutter_svg: + dependency: "direct main" + description: + name: flutter_svg + url: "https://pub.dartlang.org" + source: hosted + version: "0.14.2" flutter_test: dependency: "direct dev" description: flutter @@ -193,6 +214,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.3.0" + gradient_app_bar: + dependency: "direct main" + description: + name: gradient_app_bar + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.3" http: dependency: "direct main" description: @@ -221,6 +249,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "0.15.8" + intro_views_flutter: + dependency: "direct main" + description: + name: intro_views_flutter + url: "https://pub.dartlang.org" + source: hosted + version: "2.8.0" line_icons: dependency: "direct main" description: @@ -290,7 +325,7 @@ packages: name: package_info url: "https://pub.dartlang.org" source: hosted - version: "0.4.0+6" + version: "0.4.0+7" parse_server_sdk: dependency: "direct main" description: @@ -305,13 +340,27 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.6.4" + path_drawing: + dependency: transitive + description: + name: path_drawing + url: "https://pub.dartlang.org" + source: hosted + version: "0.4.1" + path_parsing: + dependency: transitive + description: + name: path_parsing + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.4" path_provider: dependency: transitive description: name: path_provider url: "https://pub.dartlang.org" source: hosted - version: "1.3.0" + version: "1.3.1" pedantic: dependency: transitive description: @@ -353,7 +402,7 @@ packages: name: rxdart url: "https://pub.dartlang.org" source: hosted - version: "0.22.3" + version: "0.22.4" sembast: dependency: transitive description: @@ -367,7 +416,7 @@ packages: name: shared_preferences url: "https://pub.dartlang.org" source: hosted - version: "0.5.3+4" + version: "0.5.3+5" sky_engine: dependency: transitive description: flutter diff --git a/pubspec.yaml b/pubspec.yaml index 75d9024..3c1730b 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -39,6 +39,11 @@ dependencies: meta: ^1.1.6 dio: ^2.1.0 mask_shifter: ^0.1.0 + gradient_app_bar: ^0.1.3 + carousel_pro: ^1.0.0 + intro_views_flutter: ^2.8.0 + circular_bottom_navigation: ^1.0.1 + flutter_svg: ^0.14.2 dev_dependencies: flutter_test: @@ -83,6 +88,7 @@ flutter: - assets/img_profile-1.png - assets/img_profile-2.png - assets/logo_vertical.png + - assets/logo_vertical2.png - assets/vector-3.png - assets/ellipse_1.png - assets/ellipse_2.png @@ -103,6 +109,7 @@ flutter: - assets/icon15.png - assets/icon16.png - assets/vector-4.png + - assets/vector-5.svg - assets/vector-5.png - assets/vector-6.png - assets/vector-7.png @@ -120,6 +127,41 @@ flutter: - assets/up2u.png - assets/logo-hitam.png - assets/gmail.png + - assets/seeker-1.png + - assets/seeker-2.png + - assets/seeker-3.png + - assets/employer-1.png + - assets/employer-2.png + - assets/employer-3.png + - assets/Corporate.png + - assets/DKV.png + - assets/Fashion.png + - assets/Goverment.png + - assets/IT.png + - assets/market.png + - assets/market-2.png + - assets/others.png + - assets/Startup.png + - assets/Transport.png + - assets/f&b.png + - assets/otp.png + - assets/logo.svg + - assets/dog.svg + - assets/Corporate.svg + - assets/DKV.svg + - assets/Fashion.svg + - assets/Goverment.svg + - assets/IT.svg + - assets/market.svg + - assets/market-2.svg + - assets/others.svg + - assets/Startup.svg + - assets/Transport.svg + - assets/f&b.svg + - assets/dream-cast.svg + - assets/ketapang.svg + - assets/driver.svg + # An image asset can refer to one or more resolution-specific "variants", see # https://flutter.dev/assets-and-images/#resolution-aware. @@ -146,6 +188,9 @@ flutter: - family: TitilliumWeb fonts: - asset: fonts/TitilliumWeb-Regular.ttf + - family: Roboto-Regular + fonts: + - asset: fonts/Roboto-Regular.ttf # fonts: # - family: Schyler # fonts: diff --git a/spaceweb/.gitignore b/spaceweb/.gitignore new file mode 100644 index 0000000..437cb45 --- /dev/null +++ b/spaceweb/.gitignore @@ -0,0 +1,36 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ + +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ +.dart_tool/ +.flutter-plugins +.packages +.pub-cache/ +.pub/ +/build/ + +# Web related +lib/generated_plugin_registrant.dart + +# Exceptions to above rules. +!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages diff --git a/spaceweb/.metadata b/spaceweb/.metadata new file mode 100644 index 0000000..75a3e4a --- /dev/null +++ b/spaceweb/.metadata @@ -0,0 +1,10 @@ +# This file tracks properties of this Flutter project. +# Used by Flutter tool to assess capabilities and perform upgrades etc. +# +# This file should be version controlled and should not be manually edited. + +version: + revision: 1982a5c3ec4e8bed39b90d536002c7597c127036 + channel: master + +project_type: app diff --git a/spaceweb/README.md b/spaceweb/README.md new file mode 100644 index 0000000..4899e14 --- /dev/null +++ b/spaceweb/README.md @@ -0,0 +1,16 @@ +# spaceweb + +A new Flutter project. + +## Getting Started + +This project is a starting point for a Flutter application. + +A few resources to get you started if this is your first Flutter project: + +- [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) +- [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) + +For help getting started with Flutter, view our +[online documentation](https://flutter.dev/docs), which offers tutorials, +samples, guidance on mobile development, and a full API reference. diff --git a/spaceweb/android/.gitignore b/spaceweb/android/.gitignore new file mode 100644 index 0000000..bc2100d --- /dev/null +++ b/spaceweb/android/.gitignore @@ -0,0 +1,7 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java diff --git a/spaceweb/android/app/build.gradle b/spaceweb/android/app/build.gradle new file mode 100644 index 0000000..146a1bf --- /dev/null +++ b/spaceweb/android/app/build.gradle @@ -0,0 +1,67 @@ +def localProperties = new Properties() +def localPropertiesFile = rootProject.file('local.properties') +if (localPropertiesFile.exists()) { + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) + } +} + +def flutterRoot = localProperties.getProperty('flutter.sdk') +if (flutterRoot == null) { + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") +} + +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') +if (flutterVersionCode == null) { + flutterVersionCode = '1' +} + +def flutterVersionName = localProperties.getProperty('flutter.versionName') +if (flutterVersionName == null) { + flutterVersionName = '1.0' +} + +apply plugin: 'com.android.application' +apply plugin: 'kotlin-android' +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" + +android { + compileSdkVersion 28 + + sourceSets { + main.java.srcDirs += 'src/main/kotlin' + } + + lintOptions { + disable 'InvalidPackage' + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId "com.example.spaceweb" + minSdkVersion 16 + targetSdkVersion 28 + versionCode flutterVersionCode.toInteger() + versionName flutterVersionName + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" + } + + buildTypes { + release { + // TODO: Add your own signing config for the release build. + // Signing with the debug keys for now, so `flutter run --release` works. + signingConfig signingConfigs.debug + } + } +} + +flutter { + source '../..' +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" + testImplementation 'junit:junit:4.12' + androidTestImplementation 'androidx.test:runner:1.1.1' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' +} diff --git a/spaceweb/android/app/src/debug/AndroidManifest.xml b/spaceweb/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 0000000..ff0860c --- /dev/null +++ b/spaceweb/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/spaceweb/android/app/src/main/AndroidManifest.xml b/spaceweb/android/app/src/main/AndroidManifest.xml new file mode 100644 index 0000000..3b833ee --- /dev/null +++ b/spaceweb/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + diff --git a/spaceweb/android/app/src/main/kotlin/com/example/spaceweb/MainActivity.kt b/spaceweb/android/app/src/main/kotlin/com/example/spaceweb/MainActivity.kt new file mode 100644 index 0000000..27cdfee --- /dev/null +++ b/spaceweb/android/app/src/main/kotlin/com/example/spaceweb/MainActivity.kt @@ -0,0 +1,12 @@ +package com.example.spaceweb + +import android.os.Bundle +import io.flutter.app.FlutterActivity +import io.flutter.plugins.GeneratedPluginRegistrant + +class MainActivity: FlutterActivity() { + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + GeneratedPluginRegistrant.registerWith(this) + } +} diff --git a/spaceweb/android/app/src/main/res/drawable/launch_background.xml b/spaceweb/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 0000000..304732f --- /dev/null +++ b/spaceweb/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/spaceweb/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/spaceweb/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 0000000..db77bb4 Binary files /dev/null and b/spaceweb/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/spaceweb/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/spaceweb/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 0000000..17987b7 Binary files /dev/null and b/spaceweb/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/spaceweb/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/spaceweb/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 0000000..09d4391 Binary files /dev/null and b/spaceweb/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/spaceweb/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/spaceweb/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 0000000..d5f1c8d Binary files /dev/null and b/spaceweb/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/spaceweb/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/spaceweb/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 0000000..4d6372e Binary files /dev/null and b/spaceweb/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/spaceweb/android/app/src/main/res/values/styles.xml b/spaceweb/android/app/src/main/res/values/styles.xml new file mode 100644 index 0000000..00fa441 --- /dev/null +++ b/spaceweb/android/app/src/main/res/values/styles.xml @@ -0,0 +1,8 @@ + + + + diff --git a/spaceweb/android/app/src/profile/AndroidManifest.xml b/spaceweb/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 0000000..ff0860c --- /dev/null +++ b/spaceweb/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/spaceweb/android/build.gradle b/spaceweb/android/build.gradle new file mode 100644 index 0000000..3100ad2 --- /dev/null +++ b/spaceweb/android/build.gradle @@ -0,0 +1,31 @@ +buildscript { + ext.kotlin_version = '1.3.50' + repositories { + google() + jcenter() + } + + dependencies { + classpath 'com.android.tools.build:gradle:3.5.0' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +allprojects { + repositories { + google() + jcenter() + } +} + +rootProject.buildDir = '../build' +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(':app') +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/spaceweb/android/gradle.properties b/spaceweb/android/gradle.properties new file mode 100644 index 0000000..38c8d45 --- /dev/null +++ b/spaceweb/android/gradle.properties @@ -0,0 +1,4 @@ +org.gradle.jvmargs=-Xmx1536M +android.enableR8=true +android.useAndroidX=true +android.enableJetifier=true diff --git a/spaceweb/android/gradle/wrapper/gradle-wrapper.properties b/spaceweb/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..296b146 --- /dev/null +++ b/spaceweb/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Fri Jun 23 08:50:38 CEST 2017 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip diff --git a/spaceweb/android/settings.gradle b/spaceweb/android/settings.gradle new file mode 100644 index 0000000..5a2f14f --- /dev/null +++ b/spaceweb/android/settings.gradle @@ -0,0 +1,15 @@ +include ':app' + +def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() + +def plugins = new Properties() +def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') +if (pluginsFile.exists()) { + pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } +} + +plugins.each { name, path -> + def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() + include ":$name" + project(":$name").projectDir = pluginDirectory +} diff --git a/spaceweb/ios/.gitignore b/spaceweb/ios/.gitignore new file mode 100644 index 0000000..e96ef60 --- /dev/null +++ b/spaceweb/ios/.gitignore @@ -0,0 +1,32 @@ +*.mode1v3 +*.mode2v3 +*.moved-aside +*.pbxuser +*.perspectivev3 +**/*sync/ +.sconsign.dblite +.tags* +**/.vagrant/ +**/DerivedData/ +Icon? +**/Pods/ +**/.symlinks/ +profile +xcuserdata +**/.generated/ +Flutter/App.framework +Flutter/Flutter.framework +Flutter/Flutter.podspec +Flutter/Generated.xcconfig +Flutter/app.flx +Flutter/app.zip +Flutter/flutter_assets/ +Flutter/flutter_export_environment.sh +ServiceDefinitions.json +Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!default.mode1v3 +!default.mode2v3 +!default.pbxuser +!default.perspectivev3 diff --git a/spaceweb/ios/Flutter/AppFrameworkInfo.plist b/spaceweb/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 0000000..6b4c0f7 --- /dev/null +++ b/spaceweb/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 8.0 + + diff --git a/spaceweb/ios/Flutter/Debug.xcconfig b/spaceweb/ios/Flutter/Debug.xcconfig new file mode 100644 index 0000000..592ceee --- /dev/null +++ b/spaceweb/ios/Flutter/Debug.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/spaceweb/ios/Flutter/Release.xcconfig b/spaceweb/ios/Flutter/Release.xcconfig new file mode 100644 index 0000000..592ceee --- /dev/null +++ b/spaceweb/ios/Flutter/Release.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/spaceweb/ios/Runner.xcodeproj/project.pbxproj b/spaceweb/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 0000000..b7be427 --- /dev/null +++ b/spaceweb/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,518 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */, + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */, + ); + name = "Embed Frameworks"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = ""; }; + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; + 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = ""; }; + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9740EEB11CF90186004384FC /* Flutter */ = { + isa = PBXGroup; + children = ( + 3B80C3931E831B6300D905FE /* App.framework */, + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, + 9740EEBA1CF902C7004384FC /* Flutter.framework */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 9740EEB31CF90195004384FC /* Generated.xcconfig */, + ); + name = Flutter; + sourceTree = ""; + }; + 97C146E51CF9000F007C117D = { + isa = PBXGroup; + children = ( + 9740EEB11CF90186004384FC /* Flutter */, + 97C146F01CF9000F007C117D /* Runner */, + 97C146EF1CF9000F007C117D /* Products */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + ); + name = Products; + sourceTree = ""; + }; + 97C146F01CF9000F007C117D /* Runner */ = { + isa = PBXGroup; + children = ( + 97C146FA1CF9000F007C117D /* Main.storyboard */, + 97C146FD1CF9000F007C117D /* Assets.xcassets */, + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, + 97C147021CF9000F007C117D /* Info.plist */, + 97C146F11CF9000F007C117D /* Supporting Files */, + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, + ); + path = Runner; + sourceTree = ""; + }; + 97C146F11CF9000F007C117D /* Supporting Files */ = { + isa = PBXGroup; + children = ( + ); + name = "Supporting Files"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Runner; + productName = Runner; + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 97C146E61CF9000F007C117D /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1020; + ORGANIZATIONNAME = "The Chromium Authors"; + TargetAttributes = { + 97C146ED1CF9000F007C117D = { + CreatedOnToolsVersion = 7.3.1; + LastSwiftMigration = 1100; + }; + }; + }; + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 97C146E51CF9000F007C117D; + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 97C146ED1CF9000F007C117D /* Runner */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 97C146EC1CF9000F007C117D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin"; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Run Script"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C146FB1CF9000F007C117D /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C147001CF9000F007C117D /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 249021D3217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Profile; + }; + 249021D4217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.spaceweb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 97C147041CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 97C147061CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.spaceweb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + 97C147071CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + LIBRARY_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Flutter", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.spaceweb; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147031CF9000F007C117D /* Debug */, + 97C147041CF9000F007C117D /* Release */, + 249021D3217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147061CF9000F007C117D /* Debug */, + 97C147071CF9000F007C117D /* Release */, + 249021D4217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 97C146E61CF9000F007C117D /* Project object */; +} diff --git a/spaceweb/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/spaceweb/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..1d526a1 --- /dev/null +++ b/spaceweb/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/spaceweb/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/spaceweb/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 0000000..a28140c --- /dev/null +++ b/spaceweb/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/spaceweb/ios/Runner.xcworkspace/contents.xcworkspacedata b/spaceweb/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..1d526a1 --- /dev/null +++ b/spaceweb/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/spaceweb/ios/Runner/AppDelegate.swift b/spaceweb/ios/Runner/AppDelegate.swift new file mode 100644 index 0000000..70693e4 --- /dev/null +++ b/spaceweb/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import UIKit +import Flutter + +@UIApplicationMain +@objc class AppDelegate: FlutterAppDelegate { + override func application( + _ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? + ) -> Bool { + GeneratedPluginRegistrant.register(with: self) + return super.application(application, didFinishLaunchingWithOptions: launchOptions) + } +} diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..d36b1fa --- /dev/null +++ b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,122 @@ +{ + "images" : [ + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@3x.png", + "scale" : "3x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@3x.png", + "scale" : "3x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@3x.png", + "scale" : "3x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@2x.png", + "scale" : "2x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@3x.png", + "scale" : "3x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@1x.png", + "scale" : "1x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@1x.png", + "scale" : "1x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@1x.png", + "scale" : "1x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@2x.png", + "scale" : "2x" + }, + { + "size" : "83.5x83.5", + "idiom" : "ipad", + "filename" : "Icon-App-83.5x83.5@2x.png", + "scale" : "2x" + }, + { + "size" : "1024x1024", + "idiom" : "ios-marketing", + "filename" : "Icon-App-1024x1024@1x.png", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 0000000..dc9ada4 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 0000000..28c6bf0 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 0000000..2ccbfd9 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 0000000..f091b6b Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 0000000..4cde121 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 0000000..d0ef06e Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 0000000..dcdc230 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 0000000..2ccbfd9 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 0000000..c8f9ed8 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 0000000..a6d6b86 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 0000000..a6d6b86 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 0000000..75b2d16 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 0000000..c4df70d Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 0000000..6a84f41 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 0000000..d0e1f58 Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 0000000..0bedcf2 --- /dev/null +++ b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "LaunchImage.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@3x.png", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 0000000..9da19ea Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 0000000..9da19ea Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 0000000..9da19ea Binary files /dev/null and b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 0000000..89c2725 --- /dev/null +++ b/spaceweb/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# Launch Screen Assets + +You can customize the launch screen with your own desired assets by replacing the image files in this directory. + +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. \ No newline at end of file diff --git a/spaceweb/ios/Runner/Base.lproj/LaunchScreen.storyboard b/spaceweb/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 0000000..f2e259c --- /dev/null +++ b/spaceweb/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/spaceweb/ios/Runner/Base.lproj/Main.storyboard b/spaceweb/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 0000000..f3c2851 --- /dev/null +++ b/spaceweb/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/spaceweb/ios/Runner/Info.plist b/spaceweb/ios/Runner/Info.plist new file mode 100644 index 0000000..4024770 --- /dev/null +++ b/spaceweb/ios/Runner/Info.plist @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + spaceweb + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UIViewControllerBasedStatusBarAppearance + + + diff --git a/spaceweb/ios/Runner/Runner-Bridging-Header.h b/spaceweb/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 0000000..7335fdf --- /dev/null +++ b/spaceweb/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" \ No newline at end of file diff --git a/spaceweb/lib/main.dart b/spaceweb/lib/main.dart new file mode 100644 index 0000000..5a7af45 --- /dev/null +++ b/spaceweb/lib/main.dart @@ -0,0 +1,111 @@ +import 'package:flutter/material.dart'; + +void main() => runApp(MyApp()); + +class MyApp extends StatelessWidget { + // This widget is the root of your application. + @override + Widget build(BuildContext context) { + return MaterialApp( + title: 'Flutter Demo', + theme: ThemeData( + // This is the theme of your application. + // + // Try running your application with "flutter run". You'll see the + // application has a blue toolbar. Then, without quitting the app, try + // changing the primarySwatch below to Colors.green and then invoke + // "hot reload" (press "r" in the console where you ran "flutter run", + // or simply save your changes to "hot reload" in a Flutter IDE). + // Notice that the counter didn't reset back to zero; the application + // is not restarted. + primarySwatch: Colors.blue, + ), + home: MyHomePage(title: 'Flutter Demo Home Page'), + ); + } +} + +class MyHomePage extends StatefulWidget { + MyHomePage({Key key, this.title}) : super(key: key); + + // This widget is the home page of your application. It is stateful, meaning + // that it has a State object (defined below) that contains fields that affect + // how it looks. + + // This class is the configuration for the state. It holds the values (in this + // case the title) provided by the parent (in this case the App widget) and + // used by the build method of the State. Fields in a Widget subclass are + // always marked "final". + + final String title; + + @override + _MyHomePageState createState() => _MyHomePageState(); +} + +class _MyHomePageState extends State { + int _counter = 0; + + void _incrementCounter() { + setState(() { + // This call to setState tells the Flutter framework that something has + // changed in this State, which causes it to rerun the build method below + // so that the display can reflect the updated values. If we changed + // _counter without calling setState(), then the build method would not be + // called again, and so nothing would appear to happen. + _counter++; + }); + } + + @override + Widget build(BuildContext context) { + // This method is rerun every time setState is called, for instance as done + // by the _incrementCounter method above. + // + // The Flutter framework has been optimized to make rerunning build methods + // fast, so that you can just rebuild anything that needs updating rather + // than having to individually change instances of widgets. + return Scaffold( + appBar: AppBar( + // Here we take the value from the MyHomePage object that was created by + // the App.build method, and use it to set our appbar title. + title: Text(widget.title), + ), + body: Center( + // Center is a layout widget. It takes a single child and positions it + // in the middle of the parent. + child: Column( + // Column is also a layout widget. It takes a list of children and + // arranges them vertically. By default, it sizes itself to fit its + // children horizontally, and tries to be as tall as its parent. + // + // Invoke "debug painting" (press "p" in the console, choose the + // "Toggle Debug Paint" action from the Flutter Inspector in Android + // Studio, or the "Toggle Debug Paint" command in Visual Studio Code) + // to see the wireframe for each widget. + // + // Column has various properties to control how it sizes itself and + // how it positions its children. Here we use mainAxisAlignment to + // center the children vertically; the main axis here is the vertical + // axis because Columns are vertical (the cross axis would be + // horizontal). + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text( + 'You have pushed the button this many times:', + ), + Text( + '$_counter', + style: Theme.of(context).textTheme.display1, + ), + ], + ), + ), + floatingActionButton: FloatingActionButton( + onPressed: _incrementCounter, + tooltip: 'Increment', + child: Icon(Icons.add), + ), // This trailing comma makes auto-formatting nicer for build methods. + ); + } +} diff --git a/spaceweb/pubspec.lock b/spaceweb/pubspec.lock new file mode 100644 index 0000000..d0de369 --- /dev/null +++ b/spaceweb/pubspec.lock @@ -0,0 +1,195 @@ +# Generated by pub +# See https://dart.dev/tools/pub/glossary#lockfile +packages: + archive: + dependency: transitive + description: + name: archive + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.10" + args: + dependency: transitive + description: + name: args + url: "https://pub.dartlang.org" + source: hosted + version: "1.5.2" + async: + dependency: transitive + description: + name: async + url: "https://pub.dartlang.org" + source: hosted + version: "2.3.0" + boolean_selector: + dependency: transitive + description: + name: boolean_selector + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + charcode: + dependency: transitive + description: + name: charcode + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.2" + collection: + dependency: transitive + description: + name: collection + url: "https://pub.dartlang.org" + source: hosted + version: "1.14.11" + convert: + dependency: transitive + description: + name: convert + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.1" + crypto: + dependency: transitive + description: + name: crypto + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.3" + cupertino_icons: + dependency: "direct main" + description: + name: cupertino_icons + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.2" + flutter: + dependency: "direct main" + description: flutter + source: sdk + version: "0.0.0" + flutter_test: + dependency: "direct dev" + description: flutter + source: sdk + version: "0.0.0" + image: + dependency: transitive + description: + name: image + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.4" + matcher: + dependency: transitive + description: + name: matcher + url: "https://pub.dartlang.org" + source: hosted + version: "0.12.5" + meta: + dependency: transitive + description: + name: meta + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.7" + path: + dependency: transitive + description: + name: path + url: "https://pub.dartlang.org" + source: hosted + version: "1.6.4" + pedantic: + dependency: transitive + description: + name: pedantic + url: "https://pub.dartlang.org" + source: hosted + version: "1.8.0+1" + petitparser: + dependency: transitive + description: + name: petitparser + url: "https://pub.dartlang.org" + source: hosted + version: "2.4.0" + quiver: + dependency: transitive + description: + name: quiver + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.5" + sky_engine: + dependency: transitive + description: flutter + source: sdk + version: "0.0.99" + source_span: + dependency: transitive + description: + name: source_span + url: "https://pub.dartlang.org" + source: hosted + version: "1.5.5" + stack_trace: + dependency: transitive + description: + name: stack_trace + url: "https://pub.dartlang.org" + source: hosted + version: "1.9.3" + stream_channel: + dependency: transitive + description: + name: stream_channel + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.0" + string_scanner: + dependency: transitive + description: + name: string_scanner + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + term_glyph: + dependency: transitive + description: + name: term_glyph + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.0" + test_api: + dependency: transitive + description: + name: test_api + url: "https://pub.dartlang.org" + source: hosted + version: "0.2.5" + typed_data: + dependency: transitive + description: + name: typed_data + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.6" + vector_math: + dependency: transitive + description: + name: vector_math + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.8" + xml: + dependency: transitive + description: + name: xml + url: "https://pub.dartlang.org" + source: hosted + version: "3.5.0" +sdks: + dart: ">=2.4.0 <3.0.0" diff --git a/spaceweb/pubspec.yaml b/spaceweb/pubspec.yaml new file mode 100644 index 0000000..05c2dc9 --- /dev/null +++ b/spaceweb/pubspec.yaml @@ -0,0 +1,72 @@ +name: spaceweb +description: A new Flutter project. + +# The following defines the version and build number for your application. +# A version number is three numbers separated by dots, like 1.2.43 +# followed by an optional build number separated by a +. +# Both the version and the builder number may be overridden in flutter +# build by specifying --build-name and --build-number, respectively. +# In Android, build-name is used as versionName while build-number used as versionCode. +# Read more about Android versioning at https://developer.android.com/studio/publish/versioning +# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. +# Read more about iOS versioning at +# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html +version: 1.0.0+1 + +environment: + sdk: ">=2.1.0 <3.0.0" + +dependencies: + flutter: + sdk: flutter + + # The following adds the Cupertino Icons font to your application. + # Use with the CupertinoIcons class for iOS style icons. + cupertino_icons: ^0.1.2 + +dev_dependencies: + flutter_test: + sdk: flutter + + +# For information on the generic Dart part of this file, see the +# following page: https://dart.dev/tools/pub/pubspec + +# The following section is specific to Flutter. +flutter: + + # The following line ensures that the Material Icons font is + # included with your application, so that you can use the icons in + # the material Icons class. + uses-material-design: true + + # To add assets to your application, add an assets section, like this: + # assets: + # - images/a_dot_burr.jpeg + # - images/a_dot_ham.jpeg + + # An image asset can refer to one or more resolution-specific "variants", see + # https://flutter.dev/assets-and-images/#resolution-aware. + + # For details regarding adding assets from package dependencies, see + # https://flutter.dev/assets-and-images/#from-packages + + # To add custom fonts to your application, add a fonts section here, + # in this "flutter" section. Each entry in this list should have a + # "family" key with the font family name, and a "fonts" key with a + # list giving the asset and other descriptors for the font. For + # example: + # fonts: + # - family: Schyler + # fonts: + # - asset: fonts/Schyler-Regular.ttf + # - asset: fonts/Schyler-Italic.ttf + # style: italic + # - family: Trajan Pro + # fonts: + # - asset: fonts/TrajanPro.ttf + # - asset: fonts/TrajanPro_Bold.ttf + # weight: 700 + # + # For details regarding fonts from package dependencies, + # see https://flutter.dev/custom-fonts/#from-packages diff --git a/spaceweb/test/widget_test.dart b/spaceweb/test/widget_test.dart new file mode 100644 index 0000000..1e45c12 --- /dev/null +++ b/spaceweb/test/widget_test.dart @@ -0,0 +1,30 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility that Flutter provides. For example, you can send tap and scroll +// gestures. You can also use WidgetTester to find child widgets in the widget +// tree, read text, and verify that the values of widget properties are correct. + +import 'package:flutter/material.dart'; +import 'package:flutter_test/flutter_test.dart'; + +import 'package:spaceweb/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(MyApp()); + + // Verify that our counter starts at 0. + expect(find.text('0'), findsOneWidget); + expect(find.text('1'), findsNothing); + + // Tap the '+' icon and trigger a frame. + await tester.tap(find.byIcon(Icons.add)); + await tester.pump(); + + // Verify that our counter has incremented. + expect(find.text('0'), findsNothing); + expect(find.text('1'), findsOneWidget); + }); +} diff --git a/spaceweb/web/index.html b/spaceweb/web/index.html new file mode 100644 index 0000000..fbbfa5b --- /dev/null +++ b/spaceweb/web/index.html @@ -0,0 +1,10 @@ + + + + + spaceweb + + + + + diff --git a/web/index.html b/web/index.html new file mode 100644 index 0000000..90fe2cf --- /dev/null +++ b/web/index.html @@ -0,0 +1,10 @@ + + + + + space + + + + +