diff --git a/lib/main.dart b/lib/main.dart index 7c4a150..6fd4b8a 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -7,6 +7,7 @@ import '/pages/income.dart'; import '/pages/asset.dart'; import '/pages/report.dart'; import '/pages/settings.dart'; +import '/pages/help.dart'; import '/db.dart'; void main() { @@ -70,6 +71,8 @@ class _HomePageState extends State { page = ProjectionPage(); case 4: page = SettingsPage(); + case 5: + page = HelpPage(); default: throw UnimplementedError('No widget for page $pageSelected yet!'); } @@ -118,6 +121,10 @@ class _HomePageState extends State { icon: Icon(Icons.settings), label: Text('Settings'), ), + NavigationRailDestination( + icon: Icon(Icons.help), + label: Text('Help'), + ), ], selectedIndex: pageSelected, onDestinationSelected: (value) { diff --git a/lib/pages/help.dart b/lib/pages/help.dart new file mode 100644 index 0000000..16feec6 --- /dev/null +++ b/lib/pages/help.dart @@ -0,0 +1,72 @@ +import 'package:flutter/material.dart'; + +class HelpPage extends StatelessWidget { + const HelpPage({ + super.key, + }); + + @override + Widget build(BuildContext context) { + final theme = Theme.of(context); + + return Column( + children: [ + Expanded( + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(4), + color: theme.colorScheme.onPrimary, + ), + child: Column( + children: [ + Text("This app is meant to be a simple budgeting tool," + " allowing you to view your income and expenses at a high level" + " without micro managing specific budget items or adding receipts."), + //Text("Another paragraph.") + ], + ), + ), + ), + ), + Row( + children: [ + Expanded( + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(4), + color: theme.colorScheme.onPrimary, + ), + child: TextButton.icon( + onPressed: () {}, + icon: Icon(Icons.code), + label: Text("Code Repository"), + ), + ), + ), + ), + Expanded( + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(4), + color: theme.colorScheme.onPrimary, + ), + child: TextButton.icon( + onPressed: () {}, + icon: Icon(Icons.web_asset), + label: Text("Personal Website"), + ), + ), + ), + ), + ], + ) + ], + ); + } +}