This repository has been archived on 2023-08-16. You can view files and clone it, but cannot push or open issues or pull requests.
LocalSpend-Tracker/lib/common/widgets/awesome_drawer.dart

71 lines
1.5 KiB
Dart

import 'package:flutter/material.dart';
import 'dart:io' show Platform;
class AwesomeDrawer {
Widget getDrawer(BuildContext context) {
return new Container(
width: 250,
color: Colors.white,
// padding: EdgeInsets.fromLTRB(32, 25, 32, 0),
child: ListView(
children: <Widget> [
Container(
padding: const EdgeInsets.fromLTRB(0, 15, 0, 0),
child :
FlatButton(onPressed: () => Navigator.of(context).pushReplacementNamed("/ReceiptPage"),
child:
Text("Submit Receipt",
textAlign: Platform.isIOS ? TextAlign.right : TextAlign.left,
style: new TextStyle(
fontSize: 32.0,
color: Colors.black,
),
),
),
),
Container(
padding: const EdgeInsets.fromLTRB(0, 15, 0, 0),
child :
FlatButton(onPressed: () => Navigator.of(context).pushReplacementNamed("/StatsPage"), child:
Text("Statistics",
textAlign: Platform.isIOS ? TextAlign.right : TextAlign.left,
style: new TextStyle(
fontSize: 32.0,
color: Colors.black,
),
),
),
),
Container(
padding: const EdgeInsets.fromLTRB(0, 15, 0, 0),
child :
FlatButton(onPressed: () => Navigator.of(context).pushReplacementNamed("/MorePage"), child:
Text("More",
style: new TextStyle(
fontSize: 32.0,
color: Colors.black,
),
),
),
),
Container(
padding: const EdgeInsets.fromLTRB(0, 15, 0, 0),
child :
FlatButton(onPressed: () => debugPrint("pressed"), child:
Text("reeeeeeeeee",
style: new TextStyle(
fontSize: 32.0,
color: Colors.black,
),
),
),
),
]
),
);
}
}