Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Settings menu #17

Merged
merged 62 commits into from
May 20, 2024
Merged
Changes from 1 commit
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
01b11e9
ci: only run build pipeline on develop and main
RedCommander735 May 18, 2024
c44a8ae
feat: implement new custom number formatter
RedCommander735 May 18, 2024
3c5bd90
fix: fixed some formatting bugs with the new formatter
RedCommander735 May 18, 2024
82ddb80
fix: all number displays should now work correctly
RedCommander735 May 18, 2024
df99d3a
ci: add pr pipeline
RedCommander735 May 18, 2024
6654b5c
Merge pull request #13 from RedCommander735/12-error-in-price-display
RedCommander735 May 18, 2024
b5a3801
fix: minor display issue
RedCommander735 May 19, 2024
a939080
feat: added settings icon
RedCommander735 May 19, 2024
ecdba7b
chore: update changelog
RedCommander735 May 19, 2024
e90b5fd
style: adjusted 'filter active' text
RedCommander735 May 19, 2024
98fabca
refactor: grouped filter with settings internally
RedCommander735 May 19, 2024
8a1f403
style: darkmode background now fully black
RedCommander735 May 20, 2024
a9bb9b3
style: centered page titles
RedCommander735 May 20, 2024
a3bc767
ci: new dependency to read app version
RedCommander735 May 20, 2024
0e75420
feat: first enty on about page in settings
RedCommander735 May 20, 2024
4e2cc12
chore: bump version number
RedCommander735 May 20, 2024
75c5abd
chore: update changelog
RedCommander735 May 20, 2024
d8ab85c
ci: only run build pipeline on develop and main
RedCommander735 May 18, 2024
d5c0f36
feat: implement new custom number formatter
RedCommander735 May 18, 2024
3698d20
fix: fixed some formatting bugs with the new formatter
RedCommander735 May 18, 2024
dc5ac43
fix: all number displays should now work correctly
RedCommander735 May 18, 2024
0b74236
ci: add pr pipeline
RedCommander735 May 18, 2024
b250bd5
Merge branch 'develop' of https://github.com/RedCommander735/Spritver…
RedCommander735 May 20, 2024
73463b0
fix: minor display issue
RedCommander735 May 19, 2024
4140443
feat: added settings icon
RedCommander735 May 19, 2024
59ab311
chore: update changelog
RedCommander735 May 19, 2024
f0950f9
style: adjusted 'filter active' text
RedCommander735 May 19, 2024
b13ba61
refactor: grouped filter with settings internally
RedCommander735 May 19, 2024
b65c0ec
style: darkmode background now fully black
RedCommander735 May 20, 2024
2af2149
style: centered page titles
RedCommander735 May 20, 2024
860d8b6
ci: new dependency to read app version
RedCommander735 May 20, 2024
4938892
feat: first enty on about page in settings
RedCommander735 May 20, 2024
74c7190
chore: bump version number
RedCommander735 May 20, 2024
37234c5
chore: update changelog
RedCommander735 May 20, 2024
eb4ecad
Merge branch '15-settings-page' of https://github.com/RedCommander735…
RedCommander735 May 20, 2024
d8dba6f
wip: started with settings group
RedCommander735 May 20, 2024
49662e2
Merge remote-tracking branch 'origin/main' into develop
RedCommander735 May 20, 2024
fdefbe2
Merge remote-tracking branch 'origin/develop' into 15-settings-page
RedCommander735 May 20, 2024
ebee75f
feat: add settings group and license info
RedCommander735 May 20, 2024
76dfbd3
fix: typo in license
RedCommander735 May 20, 2024
b45cdb6
chore: removed cuppertino_icons and added url_launcher and fontawesom…
RedCommander735 May 20, 2024
9c3c6e3
feat: add fontawesome 5 brands
RedCommander735 May 20, 2024
e26e481
fix: add all applicable licenses
RedCommander735 May 20, 2024
3a103b2
feat: finished about page in settings
RedCommander735 May 20, 2024
308ffc2
chore: update changelog
RedCommander735 May 20, 2024
1df6ae1
refactor: move all settings components to their own file
RedCommander735 May 20, 2024
4a2900c
chore: format all documents
RedCommander735 May 20, 2024
91f6aa0
chore: update changelog
RedCommander735 May 20, 2024
e7648b9
feat: added general settings page
RedCommander735 May 20, 2024
c6d8199
style: changed all icons to their rounded variants
RedCommander735 May 20, 2024
5762a63
style: added spacing below group headline
RedCommander735 May 20, 2024
b54a6e4
chore: add csv and storage perm handler
RedCommander735 May 20, 2024
b961667
feat: new deleteAll and createItems methods
RedCommander735 May 20, 2024
01f260f
feat: csv ex and import
RedCommander735 May 20, 2024
3f170f9
chore: update readme
RedCommander735 May 20, 2024
fe43f60
chore: update readme
RedCommander735 May 20, 2024
c295f60
feat: confirmation dialog to prevent accidental loads
RedCommander735 May 20, 2024
e966c73
chore: update changelog
RedCommander735 May 20, 2024
ddf8a22
Merge pull request #16 from RedCommander735/15-settings-page
RedCommander735 May 20, 2024
0f5f295
chore: bump version
RedCommander735 May 20, 2024
2512a8b
chore: update pubspec
RedCommander735 May 20, 2024
30bc8c3
ci: workflow was failing
RedCommander735 May 20, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
feat: added general settings page
  • Loading branch information
RedCommander735 committed May 20, 2024
commit e7648b968a6ca22cd6075d9fa664fdff8efc69af
58 changes: 58 additions & 0 deletions lib/src/settings/pages/general.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
import 'package:flutter/material.dart';
import 'package:package_info_plus/package_info_plus.dart';
import 'package:spritverbrauch/src/components/font_awesome.dart';
import 'package:spritverbrauch/src/components/settings/settings_group.dart';
import 'package:spritverbrauch/src/components/settings/settings_item.dart';
import 'package:spritverbrauch/src/components/settings/settings_topic_page.dart';
import 'package:spritverbrauch/src/utils/url_launcher.dart';

class General extends StatefulWidget {
General({super.key});

@override
State<General> createState() => _GeneralState();
}

class _GeneralState extends State<General> {
String appName = '';
String version = '';
String buildNumber = '';

@override
void initState() {
super.initState();
asyncInitState();
}

void asyncInitState() async {
PackageInfo packageInfo = await PackageInfo.fromPlatform();

setState(() {
appName = packageInfo.appName;
version = packageInfo.version;
buildNumber = packageInfo.buildNumber;
});
}

@override
Widget build(BuildContext context) {
return SettingsTopicPage(title: 'Informationen', children: [
SettingsGroup(title: 'Backup', children: [
SettingsItem(
icon: Icons.save_rounded,
title: 'Backup',
subtitle: 'Als csv speichern',
onTap: () {
},
),
SettingsItem(
icon: Icons.upload_file_rounded,
title: 'Laden',
subtitle: 'Aus csv Datei laden',
onTap: () {
},
),
])
]);
}
}