first commit
This commit is contained in:
BIN
lib/mainpage/.DS_Store
vendored
Normal file
BIN
lib/mainpage/.DS_Store
vendored
Normal file
Binary file not shown.
44
lib/mainpage/account/account_model.dart
Normal file
44
lib/mainpage/account/account_model.dart
Normal file
@@ -0,0 +1,44 @@
|
||||
import '/components/appbar_widget.dart';
|
||||
import '/components/nav_bar1_widget.dart';
|
||||
import '/flutterlib/flutter_theme.dart';
|
||||
import '/flutterlib/flutter_util.dart';
|
||||
import '/flutterlib/flutter_widgets.dart';
|
||||
import 'account_widget.dart' show AccountWidget;
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class AccountModel extends FlutterModel<AccountWidget> {
|
||||
/// State fields for stateful widgets in this page.
|
||||
|
||||
final unfocusNode = FocusNode();
|
||||
// State field(s) for Checkbox widget.
|
||||
bool? checkboxValue1;
|
||||
// State field(s) for Checkbox widget.
|
||||
bool? checkboxValue2;
|
||||
// State field(s) for Checkbox widget.
|
||||
bool? checkboxValue3;
|
||||
// Model for NavBar1 component.
|
||||
late NavBar1Model navBar1Model;
|
||||
// Model for appbar component.
|
||||
late AppbarModel appbarModel;
|
||||
|
||||
/// Initialization and disposal methods.
|
||||
|
||||
void initState(BuildContext context) {
|
||||
navBar1Model = createModel(context, () => NavBar1Model());
|
||||
appbarModel = createModel(context, () => AppbarModel());
|
||||
}
|
||||
|
||||
void dispose() {
|
||||
unfocusNode.dispose();
|
||||
navBar1Model.dispose();
|
||||
appbarModel.dispose();
|
||||
}
|
||||
|
||||
/// Action blocks are added here.
|
||||
|
||||
/// Additional helper methods are added here.
|
||||
}
|
||||
924
lib/mainpage/account/account_widget.dart
Normal file
924
lib/mainpage/account/account_widget.dart
Normal file
@@ -0,0 +1,924 @@
|
||||
import '/components/appbar_widget.dart';
|
||||
import '/components/nav_bar1_widget.dart';
|
||||
import '/flutterlib/flutter_theme.dart';
|
||||
import '/flutterlib/flutter_util.dart';
|
||||
import '/flutterlib/flutter_widgets.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'account_model.dart';
|
||||
export 'account_model.dart';
|
||||
|
||||
class AccountWidget extends StatefulWidget {
|
||||
const AccountWidget({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
_AccountWidgetState createState() => _AccountWidgetState();
|
||||
}
|
||||
|
||||
class _AccountWidgetState extends State<AccountWidget> {
|
||||
late AccountModel _model;
|
||||
|
||||
final scaffoldKey = GlobalKey<ScaffoldState>();
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_model = createModel(context, () => AccountModel());
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
_model.dispose();
|
||||
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (isiOS) {
|
||||
SystemChrome.setSystemUIOverlayStyle(
|
||||
SystemUiOverlayStyle(
|
||||
statusBarBrightness: Theme.of(context).brightness,
|
||||
systemStatusBarContrastEnforced: true,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
context.watch<FFAppState>();
|
||||
|
||||
return GestureDetector(
|
||||
onTap: () => _model.unfocusNode.canRequestFocus
|
||||
? FocusScope.of(context).requestFocus(_model.unfocusNode)
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: Scaffold(
|
||||
key: scaffoldKey,
|
||||
backgroundColor: Color(0xFFEBEBE4),
|
||||
drawer: Container(
|
||||
width: 180.0,
|
||||
child: Drawer(
|
||||
elevation: 16.0,
|
||||
child: Container(
|
||||
width: 100.0,
|
||||
height: 100.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(0.0, 80.0, 0.0, 0.0),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('account');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 8.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: 40.0,
|
||||
height: 40.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterTheme.of(context)
|
||||
.secondaryBackground,
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
child: Align(
|
||||
alignment:
|
||||
AlignmentDirectional(0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/company.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 8.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'bh939q0w' /* ABC Ltd */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('account1');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/Group_2640.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
5.0, 0.0, 0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: Image.asset(
|
||||
'assets/images/account.png',
|
||||
width: 50.0,
|
||||
height: 50.0,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
8.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'0q5lq88q' /* Account */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('tnc');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/document.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/tnc.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
17.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'a2izwr60' /* T&C */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/Group_2640.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.fitHeight,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('policy');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/Group_2640.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/pp.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'lz3njh18' /* Privacy
|
||||
Policy */
|
||||
,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('language');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/Group_2640.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/language.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'eq1cxgpy' /* Languages */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(
|
||||
width: 180.0,
|
||||
height: 61.0,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFF009B9A),
|
||||
),
|
||||
child: InkWell(
|
||||
splashColor: Colors.transparent,
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('setting');
|
||||
},
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: [
|
||||
ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/Group_2640.svg',
|
||||
width: 0.0,
|
||||
height: 0.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 0.0, 0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/setting-2.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'8jhkd8wt' /* Settings */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
appBar: PreferredSize(
|
||||
preferredSize: Size.fromHeight(0.0),
|
||||
child: AppBar(
|
||||
backgroundColor: Color(0xFFE7E36B),
|
||||
automaticallyImplyLeading: false,
|
||||
actions: [],
|
||||
centerTitle: false,
|
||||
elevation: 0.0,
|
||||
),
|
||||
),
|
||||
body: SafeArea(
|
||||
top: true,
|
||||
child: Stack(
|
||||
children: [
|
||||
Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(0.0, 24.0, 0.0, 0.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
children: [
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
0.0, 60.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: () {
|
||||
if (MediaQuery.sizeOf(context).width < 428.0) {
|
||||
return 330.0;
|
||||
} else if (MediaQuery.sizeOf(context).width >=
|
||||
428.0) {
|
||||
return 358.0;
|
||||
} else {
|
||||
return 340.0;
|
||||
}
|
||||
}(),
|
||||
height: 250.0,
|
||||
decoration: BoxDecoration(
|
||||
color: FlutterTheme.of(context)
|
||||
.secondaryBackground,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
blurRadius: 4.0,
|
||||
color: Color(0x33000000),
|
||||
offset: Offset(0.0, 2.0),
|
||||
)
|
||||
],
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Expanded(
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 8.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: 40.0,
|
||||
height: 40.0,
|
||||
decoration: BoxDecoration(
|
||||
color:
|
||||
FlutterTheme.of(context)
|
||||
.secondaryBackground,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
blurRadius: 4.0,
|
||||
color: Color(0x33000000),
|
||||
offset: Offset(0.0, 2.0),
|
||||
)
|
||||
],
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
child: Align(
|
||||
alignment: AlignmentDirectional(
|
||||
0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/company.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'4pmg51ah' /* ABC Ltd */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Align(
|
||||
alignment:
|
||||
AlignmentDirectional(1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional
|
||||
.fromSTEB(
|
||||
0.0, 0.0, 30.0, 0.0),
|
||||
child: Theme(
|
||||
data: ThemeData(
|
||||
checkboxTheme:
|
||||
CheckboxThemeData(
|
||||
visualDensity:
|
||||
VisualDensity.compact,
|
||||
materialTapTargetSize:
|
||||
MaterialTapTargetSize
|
||||
.shrinkWrap,
|
||||
shape:
|
||||
RoundedRectangleBorder(
|
||||
borderRadius:
|
||||
BorderRadius.circular(
|
||||
4.0),
|
||||
),
|
||||
),
|
||||
unselectedWidgetColor:
|
||||
Colors.white,
|
||||
),
|
||||
child: Checkbox(
|
||||
value: _model
|
||||
.checkboxValue1 ??= true,
|
||||
onChanged: (newValue) async {
|
||||
setState(() =>
|
||||
_model.checkboxValue1 =
|
||||
newValue!);
|
||||
},
|
||||
activeColor: Colors.white,
|
||||
checkColor: Color(0xFF009B9A),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 330.0,
|
||||
child: Divider(
|
||||
thickness: 1.0,
|
||||
color: Color(0xFFE8E8E8),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 8.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: 40.0,
|
||||
height: 40.0,
|
||||
decoration: BoxDecoration(
|
||||
color:
|
||||
FlutterTheme.of(context)
|
||||
.secondaryBackground,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
blurRadius: 4.0,
|
||||
color: Color(0x33000000),
|
||||
offset: Offset(0.0, 2.0),
|
||||
)
|
||||
],
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
child: Align(
|
||||
alignment: AlignmentDirectional(
|
||||
0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/company.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'jwvblj03' /* DCE Food Delivery Ltd */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Align(
|
||||
alignment:
|
||||
AlignmentDirectional(1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional
|
||||
.fromSTEB(
|
||||
0.0, 0.0, 30.0, 0.0),
|
||||
child: Theme(
|
||||
data: ThemeData(
|
||||
checkboxTheme:
|
||||
CheckboxThemeData(
|
||||
visualDensity:
|
||||
VisualDensity.compact,
|
||||
materialTapTargetSize:
|
||||
MaterialTapTargetSize
|
||||
.shrinkWrap,
|
||||
shape:
|
||||
RoundedRectangleBorder(
|
||||
borderRadius:
|
||||
BorderRadius.circular(
|
||||
4.0),
|
||||
),
|
||||
),
|
||||
unselectedWidgetColor:
|
||||
Colors.white,
|
||||
),
|
||||
child: Checkbox(
|
||||
value: _model
|
||||
.checkboxValue2 ??= false,
|
||||
onChanged: (newValue) async {
|
||||
setState(() =>
|
||||
_model.checkboxValue2 =
|
||||
newValue!);
|
||||
},
|
||||
activeColor: Colors.white,
|
||||
checkColor: Color(0xFF009B9A),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 330.0,
|
||||
child: Divider(
|
||||
thickness: 1.0,
|
||||
color: Color(0xFFE8E8E8),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
16.0, 8.0, 0.0, 0.0),
|
||||
child: Container(
|
||||
width: 40.0,
|
||||
height: 40.0,
|
||||
decoration: BoxDecoration(
|
||||
color:
|
||||
FlutterTheme.of(context)
|
||||
.secondaryBackground,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
blurRadius: 4.0,
|
||||
color: Color(0x33000000),
|
||||
offset: Offset(0.0, 2.0),
|
||||
)
|
||||
],
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
child: Align(
|
||||
alignment: AlignmentDirectional(
|
||||
0.0, 0.0),
|
||||
child: ClipRRect(
|
||||
borderRadius:
|
||||
BorderRadius.circular(8.0),
|
||||
child: SvgPicture.asset(
|
||||
'assets/images/company.svg',
|
||||
width: 30.0,
|
||||
height: 30.0,
|
||||
fit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(
|
||||
15.0, 0.0, 0.0, 0.0),
|
||||
child: Text(
|
||||
FFLocalizations.of(context).getText(
|
||||
'uqi4vsbg' /* XYZ Ltd */,
|
||||
),
|
||||
style: FlutterTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: 16.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Align(
|
||||
alignment:
|
||||
AlignmentDirectional(1.0, 0.0),
|
||||
child: Padding(
|
||||
padding: EdgeInsetsDirectional
|
||||
.fromSTEB(
|
||||
0.0, 0.0, 30.0, 0.0),
|
||||
child: Theme(
|
||||
data: ThemeData(
|
||||
checkboxTheme:
|
||||
CheckboxThemeData(
|
||||
visualDensity:
|
||||
VisualDensity.compact,
|
||||
materialTapTargetSize:
|
||||
MaterialTapTargetSize
|
||||
.shrinkWrap,
|
||||
shape:
|
||||
RoundedRectangleBorder(
|
||||
borderRadius:
|
||||
BorderRadius.circular(
|
||||
4.0),
|
||||
),
|
||||
),
|
||||
unselectedWidgetColor:
|
||||
Colors.white,
|
||||
),
|
||||
child: Checkbox(
|
||||
value: _model
|
||||
.checkboxValue3 ??= false,
|
||||
onChanged: (newValue) async {
|
||||
setState(() =>
|
||||
_model.checkboxValue3 =
|
||||
newValue!);
|
||||
},
|
||||
activeColor: Colors.white,
|
||||
checkColor: Color(0xFF009B9A),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsetsDirectional.fromSTEB(0.0, 150.0, 0.0, 0.0),
|
||||
child: FFButtonWidget(
|
||||
onPressed: () async {
|
||||
context.pushNamed('login');
|
||||
},
|
||||
text: FFLocalizations.of(context).getText(
|
||||
'tmhmsjyc' /* Log Out this Account */,
|
||||
),
|
||||
options: FFButtonOptions(
|
||||
width: 339.0,
|
||||
height: 50.0,
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
24.0, 0.0, 24.0, 0.0),
|
||||
iconPadding:
|
||||
EdgeInsetsDirectional.fromSTEB(0.0, 0.0, 0.0, 0.0),
|
||||
color: Color(0xFF9B0025),
|
||||
textStyle:
|
||||
FlutterTheme.of(context).titleSmall.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 20.0,
|
||||
),
|
||||
elevation: 3.0,
|
||||
borderSide: BorderSide(
|
||||
color: Colors.transparent,
|
||||
width: 1.0,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(40.0),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, 1.0),
|
||||
child: wrapWithModel(
|
||||
model: _model.navBar1Model,
|
||||
updateCallback: () => setState(() {}),
|
||||
child: NavBar1Widget(),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: AlignmentDirectional(0.0, -1.0),
|
||||
child: wrapWithModel(
|
||||
model: _model.appbarModel,
|
||||
updateCallback: () => setState(() {}),
|
||||
child: AppbarWidget(),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
35
lib/mainpage/menu/menu_model.dart
Normal file
35
lib/mainpage/menu/menu_model.dart
Normal file
@@ -0,0 +1,35 @@
|
||||
import '/components/nav_bar1_widget.dart';
|
||||
import '/flutterlib/flutter_theme.dart';
|
||||
import '/flutterlib/flutter_util.dart';
|
||||
import '/flutterlib/flutter_widgets.dart';
|
||||
import 'menu_widget.dart' show MenuWidget;
|
||||
import 'package:badges/badges.dart' as badges;
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class MenuModel extends FlutterModel<MenuWidget> {
|
||||
/// State fields for stateful widgets in this page.
|
||||
|
||||
final unfocusNode = FocusNode();
|
||||
// Model for NavBar1 component.
|
||||
late NavBar1Model navBar1Model;
|
||||
|
||||
/// Initialization and disposal methods.
|
||||
|
||||
void initState(BuildContext context) {
|
||||
navBar1Model = createModel(context, () => NavBar1Model());
|
||||
}
|
||||
|
||||
void dispose() {
|
||||
unfocusNode.dispose();
|
||||
navBar1Model.dispose();
|
||||
}
|
||||
|
||||
/// Action blocks are added here.
|
||||
|
||||
/// Additional helper methods are added here.
|
||||
}
|
||||
1259
lib/mainpage/menu/menu_widget.dart
Normal file
1259
lib/mainpage/menu/menu_widget.dart
Normal file
File diff suppressed because it is too large
Load Diff
38
lib/mainpage/notification/notification_model.dart
Normal file
38
lib/mainpage/notification/notification_model.dart
Normal file
@@ -0,0 +1,38 @@
|
||||
import '/components/appbar_widget.dart';
|
||||
import '/components/nav_bar1_widget.dart';
|
||||
import '/flutterlib/flutter_theme.dart';
|
||||
import '/flutterlib/flutter_util.dart';
|
||||
import '/flutterlib/flutter_widgets.dart';
|
||||
import 'notification_widget.dart' show NotificationWidget;
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
class NotificationModel extends FlutterModel<NotificationWidget> {
|
||||
/// State fields for stateful widgets in this page.
|
||||
|
||||
final unfocusNode = FocusNode();
|
||||
// Model for appbar component.
|
||||
late AppbarModel appbarModel;
|
||||
// Model for NavBar1 component.
|
||||
late NavBar1Model navBar1Model;
|
||||
|
||||
/// Initialization and disposal methods.
|
||||
|
||||
void initState(BuildContext context) {
|
||||
appbarModel = createModel(context, () => AppbarModel());
|
||||
navBar1Model = createModel(context, () => NavBar1Model());
|
||||
}
|
||||
|
||||
void dispose() {
|
||||
unfocusNode.dispose();
|
||||
appbarModel.dispose();
|
||||
navBar1Model.dispose();
|
||||
}
|
||||
|
||||
/// Action blocks are added here.
|
||||
|
||||
/// Additional helper methods are added here.
|
||||
}
|
||||
1232
lib/mainpage/notification/notification_widget.dart
Normal file
1232
lib/mainpage/notification/notification_widget.dart
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user