diff --git a/.dart_tool/package_config.json b/.dart_tool/package_config.json index 6a79b0d..5ec4839 100644 --- a/.dart_tool/package_config.json +++ b/.dart_tool/package_config.json @@ -1130,7 +1130,7 @@ "languageVersion": "3.7" } ], - "generated": "2025-06-16T17:17:10.994308Z", + "generated": "2025-06-16T19:03:33.328096Z", "generator": "pub", "generatorVersion": "3.7.0", "flutterRoot": "file:///Users/vitalijnecitajlo/fvm/versions/3.29.0", diff --git a/.flutter-plugins-dependencies b/.flutter-plugins-dependencies index 733bb28..7ea77c9 100644 --- a/.flutter-plugins-dependencies +++ b/.flutter-plugins-dependencies @@ -1 +1 @@ -{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage-9.2.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_foundation","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false}],"android":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"],"dev_dependency":false},{"name":"flutter_displaymode","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_displaymode-0.6.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_plugin_android_lifecycle","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.27/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage-9.2.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_android","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_android-2.2.16/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false}],"macos":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_macos","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_macos-3.1.3/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_foundation","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false}],"linux":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_linux-1.2.2/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"path_provider_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":false,"dependencies":["url_launcher_linux"],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"url_launcher_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_linux-3.2.1/","native_build":true,"dependencies":[],"dev_dependency":false}],"windows":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_windows-3.1.2/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"path_provider_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_windows-2.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":["url_launcher_windows"],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"url_launcher_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.4/","native_build":true,"dependencies":[],"dev_dependency":false}],"web":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_web","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_web-1.2.1/","dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","dependencies":["url_launcher_web"],"dev_dependency":false},{"name":"url_launcher_web","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_web-2.4.0/","dependencies":[],"dev_dependency":false}]},"dependencyGraph":[{"name":"file_picker","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"flutter_displaymode","dependencies":[]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"flutter_secure_storage","dependencies":["flutter_secure_storage_linux","flutter_secure_storage_macos","flutter_secure_storage_web","flutter_secure_storage_windows"]},{"name":"flutter_secure_storage_linux","dependencies":[]},{"name":"flutter_secure_storage_macos","dependencies":[]},{"name":"flutter_secure_storage_web","dependencies":[]},{"name":"flutter_secure_storage_windows","dependencies":["path_provider"]},{"name":"fluttertoast","dependencies":[]},{"name":"package_info_plus","dependencies":[]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"share_plus","dependencies":["url_launcher_web","url_launcher_windows","url_launcher_linux"]},{"name":"sqlite3_flutter_libs","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]}],"date_created":"2025-06-16 20:17:09.466652","version":"3.29.0","swift_package_manager_enabled":{"ios":false,"macos":false}} \ No newline at end of file +{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage-9.2.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_foundation","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false}],"android":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"],"dev_dependency":false},{"name":"flutter_displaymode","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_displaymode-0.6.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_plugin_android_lifecycle","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.27/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage-9.2.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_android","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_android-2.2.16/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false}],"macos":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_macos","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_macos-3.1.3/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"path_provider_foundation","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","shared_darwin_source":true,"native_build":true,"dependencies":[],"dev_dependency":false}],"linux":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_linux-1.2.2/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"path_provider_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":false,"dependencies":["url_launcher_linux"],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"url_launcher_linux","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_linux-3.2.1/","native_build":true,"dependencies":[],"dev_dependency":false}],"windows":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_windows-3.1.2/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"path_provider_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/path_provider_windows-2.3.0/","native_build":false,"dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","native_build":true,"dependencies":["url_launcher_windows"],"dev_dependency":false},{"name":"sqlite3_flutter_libs","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/sqlite3_flutter_libs-0.5.32/","native_build":true,"dependencies":[],"dev_dependency":false},{"name":"url_launcher_windows","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.4/","native_build":true,"dependencies":[],"dev_dependency":false}],"web":[{"name":"file_picker","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/file_picker-10.0.0/","dependencies":[],"dev_dependency":false},{"name":"flutter_secure_storage_web","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/flutter_secure_storage_web-1.2.1/","dependencies":[],"dev_dependency":false},{"name":"fluttertoast","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/fluttertoast-8.2.12/","dependencies":[],"dev_dependency":false},{"name":"package_info_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/package_info_plus-8.3.0/","dependencies":[],"dev_dependency":false},{"name":"share_plus","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/share_plus-10.1.4/","dependencies":["url_launcher_web"],"dev_dependency":false},{"name":"url_launcher_web","path":"/Users/vitalijnecitajlo/.pub-cache/hosted/pub.dev/url_launcher_web-2.4.0/","dependencies":[],"dev_dependency":false}]},"dependencyGraph":[{"name":"file_picker","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"flutter_displaymode","dependencies":[]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"flutter_secure_storage","dependencies":["flutter_secure_storage_linux","flutter_secure_storage_macos","flutter_secure_storage_web","flutter_secure_storage_windows"]},{"name":"flutter_secure_storage_linux","dependencies":[]},{"name":"flutter_secure_storage_macos","dependencies":[]},{"name":"flutter_secure_storage_web","dependencies":[]},{"name":"flutter_secure_storage_windows","dependencies":["path_provider"]},{"name":"fluttertoast","dependencies":[]},{"name":"package_info_plus","dependencies":[]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"share_plus","dependencies":["url_launcher_web","url_launcher_windows","url_launcher_linux"]},{"name":"sqlite3_flutter_libs","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]}],"date_created":"2025-06-16 22:03:31.911393","version":"3.29.0","swift_package_manager_enabled":{"ios":false,"macos":false}} \ No newline at end of file diff --git a/assets/icons/settings_about.png b/assets/icons/settings_about.png new file mode 100644 index 0000000..3d4ae07 Binary files /dev/null and b/assets/icons/settings_about.png differ diff --git a/assets/icons/settings_exit.png b/assets/icons/settings_exit.png new file mode 100644 index 0000000..6bad5cb Binary files /dev/null and b/assets/icons/settings_exit.png differ diff --git a/assets/icons/settings_faq.png b/assets/icons/settings_faq.png new file mode 100644 index 0000000..d1f2e37 Binary files /dev/null and b/assets/icons/settings_faq.png differ diff --git a/assets/icons/settings_mail.png b/assets/icons/settings_mail.png new file mode 100644 index 0000000..7c07dae Binary files /dev/null and b/assets/icons/settings_mail.png differ diff --git a/assets/icons/settings_name.png b/assets/icons/settings_name.png new file mode 100644 index 0000000..16b678c Binary files /dev/null and b/assets/icons/settings_name.png differ diff --git a/assets/icons/settings_notification.png b/assets/icons/settings_notification.png new file mode 100644 index 0000000..4583f4a Binary files /dev/null and b/assets/icons/settings_notification.png differ diff --git a/assets/icons/settings_phone.png b/assets/icons/settings_phone.png new file mode 100644 index 0000000..d36e37a Binary files /dev/null and b/assets/icons/settings_phone.png differ diff --git a/assets/icons/settings_profile.png b/assets/icons/settings_profile.png new file mode 100644 index 0000000..178b796 Binary files /dev/null and b/assets/icons/settings_profile.png differ diff --git a/assets/icons/settings_share.png b/assets/icons/settings_share.png new file mode 100644 index 0000000..e2a7b14 Binary files /dev/null and b/assets/icons/settings_share.png differ diff --git a/assets/icons/settings_trash.png b/assets/icons/settings_trash.png new file mode 100644 index 0000000..85de286 Binary files /dev/null and b/assets/icons/settings_trash.png differ diff --git a/lib/gen/assets.gen.dart b/lib/gen/assets.gen.dart index b0fcf60..872fcdc 100644 --- a/lib/gen/assets.gen.dart +++ b/lib/gen/assets.gen.dart @@ -21,6 +21,46 @@ class $AssetsIconsGen { /// File path: assets/icons/mail.png AssetGenImage get mail => const AssetGenImage('assets/icons/mail.png'); + /// File path: assets/icons/settings_about.png + AssetGenImage get settingsAbout => + const AssetGenImage('assets/icons/settings_about.png'); + + /// File path: assets/icons/settings_exit.png + AssetGenImage get settingsExit => + const AssetGenImage('assets/icons/settings_exit.png'); + + /// File path: assets/icons/settings_faq.png + AssetGenImage get settingsFaq => + const AssetGenImage('assets/icons/settings_faq.png'); + + /// File path: assets/icons/settings_mail.png + AssetGenImage get settingsMail => + const AssetGenImage('assets/icons/settings_mail.png'); + + /// File path: assets/icons/settings_name.png + AssetGenImage get settingsName => + const AssetGenImage('assets/icons/settings_name.png'); + + /// File path: assets/icons/settings_notification.png + AssetGenImage get settingsNotification => + const AssetGenImage('assets/icons/settings_notification.png'); + + /// File path: assets/icons/settings_phone.png + AssetGenImage get settingsPhone => + const AssetGenImage('assets/icons/settings_phone.png'); + + /// File path: assets/icons/settings_profile.png + AssetGenImage get settingsProfile => + const AssetGenImage('assets/icons/settings_profile.png'); + + /// File path: assets/icons/settings_share.png + AssetGenImage get settingsShare => + const AssetGenImage('assets/icons/settings_share.png'); + + /// File path: assets/icons/settings_trash.png + AssetGenImage get settingsTrash => + const AssetGenImage('assets/icons/settings_trash.png'); + /// File path: assets/icons/type=arrow_down.png AssetGenImage get typeArrowDown => const AssetGenImage('assets/icons/type=arrow_down.png'); @@ -221,6 +261,16 @@ class $AssetsIconsGen { back, call, mail, + settingsAbout, + settingsExit, + settingsFaq, + settingsMail, + settingsName, + settingsNotification, + settingsPhone, + settingsProfile, + settingsShare, + settingsTrash, typeArrowDown, typeBack, typeBold, diff --git a/lib/i18n/strings.g.dart b/lib/i18n/strings.g.dart index ad70738..d08ccee 100644 --- a/lib/i18n/strings.g.dart +++ b/lib/i18n/strings.g.dart @@ -6,7 +6,7 @@ /// Locales: 2 /// Strings: 20 (10 per locale) /// -/// Built on 2025-06-16 at 17:17 UTC +/// Built on 2025-06-16 at 19:03 UTC // coverage:ignore-file // ignore_for_file: type=lint, unused_import diff --git a/lib/screens/settings/cubit/settings_cubit.dart b/lib/screens/settings/cubit/settings_cubit.dart new file mode 100644 index 0000000..666ed86 --- /dev/null +++ b/lib/screens/settings/cubit/settings_cubit.dart @@ -0,0 +1,29 @@ +import 'package:bloc/bloc.dart'; +import 'package:freezed_annotation/freezed_annotation.dart'; + +part 'settings_state.dart'; +part 'settings_cubit.freezed.dart'; + +class SettingsCubit extends Cubit { + SettingsCubit() : super(SettingsState.initial()); + + Future toInitialState() async { + emit(SettingsState.initial()); + } + + Future toProfileState() async { + emit(SettingsState.profile()); + } + + Future toNotificationsState() async { + emit(SettingsState.notifications()); + } + + Future toFaqState() async { + emit(SettingsState.faq()); + } + + Future toAboutState() async { + emit(SettingsState.about()); + } +} diff --git a/lib/screens/settings/cubit/settings_cubit.freezed.dart b/lib/screens/settings/cubit/settings_cubit.freezed.dart new file mode 100644 index 0000000..2b321b5 --- /dev/null +++ b/lib/screens/settings/cubit/settings_cubit.freezed.dart @@ -0,0 +1,713 @@ +// coverage:ignore-file +// GENERATED CODE - DO NOT MODIFY BY HAND +// ignore_for_file: type=lint +// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark + +part of 'settings_cubit.dart'; + +// ************************************************************************** +// FreezedGenerator +// ************************************************************************** + +T _$identity(T value) => value; + +final _privateConstructorUsedError = UnsupportedError( + 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models', +); + +/// @nodoc +mixin _$SettingsState { + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) => throw _privateConstructorUsedError; + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) => throw _privateConstructorUsedError; + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) => throw _privateConstructorUsedError; + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) => throw _privateConstructorUsedError; + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) => throw _privateConstructorUsedError; + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) => throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $SettingsStateCopyWith<$Res> { + factory $SettingsStateCopyWith( + SettingsState value, + $Res Function(SettingsState) then, + ) = _$SettingsStateCopyWithImpl<$Res, SettingsState>; +} + +/// @nodoc +class _$SettingsStateCopyWithImpl<$Res, $Val extends SettingsState> + implements $SettingsStateCopyWith<$Res> { + _$SettingsStateCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc +abstract class _$$InitialImplCopyWith<$Res> { + factory _$$InitialImplCopyWith( + _$InitialImpl value, + $Res Function(_$InitialImpl) then, + ) = __$$InitialImplCopyWithImpl<$Res>; +} + +/// @nodoc +class __$$InitialImplCopyWithImpl<$Res> + extends _$SettingsStateCopyWithImpl<$Res, _$InitialImpl> + implements _$$InitialImplCopyWith<$Res> { + __$$InitialImplCopyWithImpl( + _$InitialImpl _value, + $Res Function(_$InitialImpl) _then, + ) : super(_value, _then); + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc + +class _$InitialImpl implements _Initial { + const _$InitialImpl(); + + @override + String toString() { + return 'SettingsState.initial()'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && other is _$InitialImpl); + } + + @override + int get hashCode => runtimeType.hashCode; + + @override + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) { + return initial(); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) { + return initial?.call(); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) { + if (initial != null) { + return initial(); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) { + return initial(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) { + return initial?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) { + if (initial != null) { + return initial(this); + } + return orElse(); + } +} + +abstract class _Initial implements SettingsState { + const factory _Initial() = _$InitialImpl; +} + +/// @nodoc +abstract class _$$ProfileImplCopyWith<$Res> { + factory _$$ProfileImplCopyWith( + _$ProfileImpl value, + $Res Function(_$ProfileImpl) then, + ) = __$$ProfileImplCopyWithImpl<$Res>; +} + +/// @nodoc +class __$$ProfileImplCopyWithImpl<$Res> + extends _$SettingsStateCopyWithImpl<$Res, _$ProfileImpl> + implements _$$ProfileImplCopyWith<$Res> { + __$$ProfileImplCopyWithImpl( + _$ProfileImpl _value, + $Res Function(_$ProfileImpl) _then, + ) : super(_value, _then); + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc + +class _$ProfileImpl implements _Profile { + const _$ProfileImpl(); + + @override + String toString() { + return 'SettingsState.profile()'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && other is _$ProfileImpl); + } + + @override + int get hashCode => runtimeType.hashCode; + + @override + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) { + return profile(); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) { + return profile?.call(); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) { + if (profile != null) { + return profile(); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) { + return profile(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) { + return profile?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) { + if (profile != null) { + return profile(this); + } + return orElse(); + } +} + +abstract class _Profile implements SettingsState { + const factory _Profile() = _$ProfileImpl; +} + +/// @nodoc +abstract class _$$NotificationsImplCopyWith<$Res> { + factory _$$NotificationsImplCopyWith( + _$NotificationsImpl value, + $Res Function(_$NotificationsImpl) then, + ) = __$$NotificationsImplCopyWithImpl<$Res>; +} + +/// @nodoc +class __$$NotificationsImplCopyWithImpl<$Res> + extends _$SettingsStateCopyWithImpl<$Res, _$NotificationsImpl> + implements _$$NotificationsImplCopyWith<$Res> { + __$$NotificationsImplCopyWithImpl( + _$NotificationsImpl _value, + $Res Function(_$NotificationsImpl) _then, + ) : super(_value, _then); + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc + +class _$NotificationsImpl implements _Notifications { + const _$NotificationsImpl(); + + @override + String toString() { + return 'SettingsState.notifications()'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && other is _$NotificationsImpl); + } + + @override + int get hashCode => runtimeType.hashCode; + + @override + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) { + return notifications(); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) { + return notifications?.call(); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) { + if (notifications != null) { + return notifications(); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) { + return notifications(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) { + return notifications?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) { + if (notifications != null) { + return notifications(this); + } + return orElse(); + } +} + +abstract class _Notifications implements SettingsState { + const factory _Notifications() = _$NotificationsImpl; +} + +/// @nodoc +abstract class _$$FaqImplCopyWith<$Res> { + factory _$$FaqImplCopyWith(_$FaqImpl value, $Res Function(_$FaqImpl) then) = + __$$FaqImplCopyWithImpl<$Res>; +} + +/// @nodoc +class __$$FaqImplCopyWithImpl<$Res> + extends _$SettingsStateCopyWithImpl<$Res, _$FaqImpl> + implements _$$FaqImplCopyWith<$Res> { + __$$FaqImplCopyWithImpl(_$FaqImpl _value, $Res Function(_$FaqImpl) _then) + : super(_value, _then); + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc + +class _$FaqImpl implements _Faq { + const _$FaqImpl(); + + @override + String toString() { + return 'SettingsState.faq()'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && other is _$FaqImpl); + } + + @override + int get hashCode => runtimeType.hashCode; + + @override + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) { + return faq(); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) { + return faq?.call(); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) { + if (faq != null) { + return faq(); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) { + return faq(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) { + return faq?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) { + if (faq != null) { + return faq(this); + } + return orElse(); + } +} + +abstract class _Faq implements SettingsState { + const factory _Faq() = _$FaqImpl; +} + +/// @nodoc +abstract class _$$AboutImplCopyWith<$Res> { + factory _$$AboutImplCopyWith( + _$AboutImpl value, + $Res Function(_$AboutImpl) then, + ) = __$$AboutImplCopyWithImpl<$Res>; +} + +/// @nodoc +class __$$AboutImplCopyWithImpl<$Res> + extends _$SettingsStateCopyWithImpl<$Res, _$AboutImpl> + implements _$$AboutImplCopyWith<$Res> { + __$$AboutImplCopyWithImpl( + _$AboutImpl _value, + $Res Function(_$AboutImpl) _then, + ) : super(_value, _then); + + /// Create a copy of SettingsState + /// with the given fields replaced by the non-null parameter values. +} + +/// @nodoc + +class _$AboutImpl implements _About { + const _$AboutImpl(); + + @override + String toString() { + return 'SettingsState.about()'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && other is _$AboutImpl); + } + + @override + int get hashCode => runtimeType.hashCode; + + @override + @optionalTypeArgs + TResult when({ + required TResult Function() initial, + required TResult Function() profile, + required TResult Function() notifications, + required TResult Function() faq, + required TResult Function() about, + }) { + return about(); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function()? initial, + TResult? Function()? profile, + TResult? Function()? notifications, + TResult? Function()? faq, + TResult? Function()? about, + }) { + return about?.call(); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function()? initial, + TResult Function()? profile, + TResult Function()? notifications, + TResult Function()? faq, + TResult Function()? about, + required TResult orElse(), + }) { + if (about != null) { + return about(); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(_Initial value) initial, + required TResult Function(_Profile value) profile, + required TResult Function(_Notifications value) notifications, + required TResult Function(_Faq value) faq, + required TResult Function(_About value) about, + }) { + return about(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(_Initial value)? initial, + TResult? Function(_Profile value)? profile, + TResult? Function(_Notifications value)? notifications, + TResult? Function(_Faq value)? faq, + TResult? Function(_About value)? about, + }) { + return about?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(_Initial value)? initial, + TResult Function(_Profile value)? profile, + TResult Function(_Notifications value)? notifications, + TResult Function(_Faq value)? faq, + TResult Function(_About value)? about, + required TResult orElse(), + }) { + if (about != null) { + return about(this); + } + return orElse(); + } +} + +abstract class _About implements SettingsState { + const factory _About() = _$AboutImpl; +} diff --git a/lib/screens/settings/cubit/settings_state.dart b/lib/screens/settings/cubit/settings_state.dart new file mode 100644 index 0000000..77b732c --- /dev/null +++ b/lib/screens/settings/cubit/settings_state.dart @@ -0,0 +1,10 @@ +part of 'settings_cubit.dart'; + +@freezed +class SettingsState with _$SettingsState { + const factory SettingsState.initial() = _Initial; + const factory SettingsState.profile() = _Profile; + const factory SettingsState.notifications() = _Notifications; + const factory SettingsState.faq() = _Faq; + const factory SettingsState.about() = _About; +} diff --git a/lib/screens/settings/settings_screen.dart b/lib/screens/settings/settings_screen.dart index 88be885..ad6761d 100644 --- a/lib/screens/settings/settings_screen.dart +++ b/lib/screens/settings/settings_screen.dart @@ -1,5 +1,20 @@ import 'package:auto_route/auto_route.dart'; +import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/functions.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/common/widgets/wspace.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/gen/assets.gen.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; +import 'package:remever/screens/settings/states/about.dart'; +import 'package:remever/screens/settings/states/faq.dart'; +import 'package:remever/screens/settings/states/initial.dart'; +import 'package:remever/screens/settings/states/notifications.dart'; +import 'package:remever/screens/settings/states/profile.dart'; +import 'package:remever/widgets/primary_button.dart'; @RoutePage() class SettingsScreen extends StatelessWidget { @@ -7,6 +22,29 @@ class SettingsScreen extends StatelessWidget { @override Widget build(BuildContext context) { - return const Placeholder(color: Colors.red); + return BlocProvider( + create: (BuildContext context) => SettingsCubit(), + child: _buildMain(), + ); + } + + /// + /// Построение основного блока + /// + Widget _buildMain() { + return PopScope( + canPop: false, + child: BlocBuilder( + builder: (BuildContext context, state) { + return state.when( + initial: () => InitialSettingsState(), + profile: () => ProfileSettingsState(), + notifications: () => NotificationsSettingsState(), + faq: () => FaqSettingsState(), + about: () => AboutSettingsState(), + ); + }, + ), + ); } } diff --git a/lib/screens/settings/states/about.dart b/lib/screens/settings/states/about.dart new file mode 100644 index 0000000..14789d8 --- /dev/null +++ b/lib/screens/settings/states/about.dart @@ -0,0 +1,81 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/functions.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/common/widgets/wspace.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/gen/assets.gen.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; +import 'package:remever/widgets/primary_button.dart'; + +class AboutSettingsState extends StatelessWidget { + const AboutSettingsState({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bg, + appBar: AppBar( + toolbarHeight: 66.h, + backgroundColor: AppColors.white, + shadowColor: Colors.transparent, + centerTitle: true, + title: AppTypography('О приложении', type: SemiBold20px()), + leading: IconButton( + onPressed: () { + context.read().toInitialState(); + }, + icon: Icon(CupertinoIcons.left_chevron), + color: Colors.black, + ), + actions: [ + IconButton( + onPressed: () { + showInfoToast('тут будет sharing'); + }, + icon: Assets.icons.settingsShare.image(height: 24.h, width: 24.w), + color: Colors.black, + ), + ], + ), + body: Padding( + padding: const EdgeInsets.all(16).r, + child: Column( + children: [ + Spacer(), + Assets.images.logo.image(width: 308.w, height: 100.h), + AppTypography( + 'Версия приложения: 1.10.12\nот 23.05.2025', + type: Regular12px(), + maxLines: 2, + textAlign: TextAlign.center, + ), + Spacer(), + AppTypography( + 'Лицензионное соглашение', + type: Regular14px(), + color: AppColors.primary, + ), + HSpace(10), + AppTypography( + 'Политика конфиденциальности', + type: Regular14px(), + color: AppColors.primary, + ), + HSpace(60), + PrimaryButton( + onTap: () {}, + child: AppTypography( + 'Обновить приложение', + type: Medium14px(), + color: AppColors.white, + ), + ), + ], + ), + ), + ); + } +} diff --git a/lib/screens/settings/states/faq.dart b/lib/screens/settings/states/faq.dart new file mode 100644 index 0000000..5fc698c --- /dev/null +++ b/lib/screens/settings/states/faq.dart @@ -0,0 +1,92 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/typography.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/common/widgets/wspace.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; +import 'package:remever/widgets/primary_button.dart'; + +class FaqSettingsState extends StatelessWidget { + const FaqSettingsState({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bg, + appBar: _buildAppBar(context), + body: Padding( + padding: const EdgeInsets.all(16).r, + child: Column( + children: [ + Expanded( + child: Container( + width: double.infinity, + decoration: BoxDecoration( + color: AppColors.white, + borderRadius: BorderRadius.all(Radius.circular(12)).r, + ), + child: _buildFaqList(), + ), + ), + HSpace(16), + PrimaryButton( + onTap: () {}, + child: AppTypography( + 'Задать свой вопрос', + type: Medium14px(), + color: AppColors.white, + ), + ), + ], + ), + ), + ); + } + + Widget _buildFaqList() { + return ListView( + children: [ + _buildExpansion('Есть ли ограничения по количеству коллекций?', 'Нет'), + Divider(thickness: 1, height: 1, color: AppColors.bg), + _buildExpansion( + 'Как поделиться коллекцией с друзьями?', + 'Другу необходимо установить приложение Remever на свой телефон, после этого вы сможете обмениваться друг с другом коллекциями', + ), + Divider(thickness: 1, height: 1, color: AppColors.bg), + _buildExpansion('Можно ли пользоваться бесплатно?', 'Пока да'), + Divider(thickness: 1, height: 1, color: AppColors.bg), + ], + ); + } + + /// AppBar экрана FAQ + AppBar _buildAppBar(BuildContext context) { + return AppBar( + toolbarHeight: 66.h, + backgroundColor: AppColors.white, + shadowColor: Colors.transparent, + centerTitle: true, + title: AppTypography('FAQ', type: SemiBold20px()), + leading: IconButton( + onPressed: () => context.read().toInitialState(), + icon: Icon(CupertinoIcons.left_chevron), + color: Colors.black, + ), + ); + } + + Widget _buildExpansion(String title, String answer) { + return ExpansionTile( + title: AppTypography(title, type: Medium16px(), maxLines: 2), + textColor: Colors.black, + children: [ + ListTile( + title: AppTypography(answer, type: Regular14px(), maxLines: 99), + ), + ], + ); + } +} diff --git a/lib/screens/settings/states/initial.dart b/lib/screens/settings/states/initial.dart new file mode 100644 index 0000000..82bc426 --- /dev/null +++ b/lib/screens/settings/states/initial.dart @@ -0,0 +1,136 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/functions.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/common/widgets/wspace.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/gen/assets.gen.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; +import 'package:remever/widgets/primary_button.dart'; + +class InitialSettingsState extends StatelessWidget { + const InitialSettingsState({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bg, + appBar: _buildAppBar(context), + body: Padding( + padding: EdgeInsets.all(16.r), + child: Column( + children: [ + _buildSettingsItem( + context, + Assets.icons.settingsProfile, + 'Профиль', + SettingsCubitType.profile, + ), + HSpace(8), + _buildSettingsItem( + context, + Assets.icons.settingsNotification, + 'Уведомления', + SettingsCubitType.notifications, + ), + HSpace(8), + _buildSettingsItem( + context, + Assets.icons.settingsFaq, + 'FAQ', + SettingsCubitType.faq, + ), + HSpace(8), + _buildSettingsItem( + context, + Assets.icons.settingsAbout, + 'О приложении', + SettingsCubitType.about, + ), + const Spacer(), + _buildContactDeveloperButton(), + ], + ), + ), + ); + } + + /// AppBar экрана настроек + AppBar _buildAppBar(BuildContext context) { + return AppBar( + toolbarHeight: 66.h, + backgroundColor: AppColors.white, + shadowColor: Colors.transparent, + centerTitle: true, + leadingWidth: 0, + title: AppTypography('Настройки', type: SemiBold20px()), + actions: [ + IconButton( + onPressed: () => showInfoToast('Тут будет выход'), + icon: Assets.icons.settingsExit.image(height: 24.h, width: 24.w), + color: Colors.black, + ), + ], + ); + } + + /// Общий метод для построения пункта меню + Widget _buildSettingsItem( + BuildContext context, + AssetGenImage icon, + String title, + SettingsCubitType cubitType, + ) { + return GestureDetector( + onTap: () => _navigateToSection(context, cubitType), + child: Container( + width: double.infinity, + decoration: BoxDecoration( + color: AppColors.white, + borderRadius: BorderRadius.circular(12.r), + ), + margin: EdgeInsets.zero, + padding: EdgeInsets.symmetric(vertical: 16.r, horizontal: 12.r), + child: Row( + children: [ + icon.image(height: 24.h, width: 24.w), + WSpace(8), + AppTypography(title, type: Regular16px()), + ], + ), + ), + ); + } + + /// Метод для навигации к разделу через Cubit + void _navigateToSection(BuildContext context, SettingsCubitType cubitType) { + switch (cubitType) { + case SettingsCubitType.initial: + context.read().toInitialState(); + case SettingsCubitType.profile: + context.read().toProfileState(); + case SettingsCubitType.notifications: + context.read().toNotificationsState(); + case SettingsCubitType.faq: + context.read().toFaqState(); + case SettingsCubitType.about: + context.read().toAboutState(); + } + } + + /// Кнопка "Написать разработчику" + Widget _buildContactDeveloperButton() { + return PrimaryButton( + child: AppTypography( + 'Написать разработчику', + color: AppColors.white, + type: Medium14px(), + ), + onTap: () {}, + ); + } +} + +/// Перечисление типов состояний для SettingsCubit +enum SettingsCubitType { initial, profile, notifications, faq, about } diff --git a/lib/screens/settings/states/notifications.dart b/lib/screens/settings/states/notifications.dart new file mode 100644 index 0000000..ff70502 --- /dev/null +++ b/lib/screens/settings/states/notifications.dart @@ -0,0 +1,103 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; + +class NotificationsSettingsState extends StatelessWidget { + const NotificationsSettingsState({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bg, + appBar: AppBar( + toolbarHeight: 66.h, + backgroundColor: AppColors.white, + shadowColor: Colors.transparent, + centerTitle: true, + title: AppTypography('Уведомления', type: SemiBold20px()), + leading: IconButton( + onPressed: () { + context.read().toInitialState(); + }, + icon: Icon(CupertinoIcons.left_chevron), + color: Colors.black, + ), + ), + body: Padding( + padding: const EdgeInsets.all(16).r, + child: Column( + spacing: 10, + children: [ + _buildInfoLine( + context, + 'Напоминание о тренировке', + 'Начнешь тренировку вовремя для эффективного запоминания. Уведомления будут приходить в период с 9:00 до 23:00', + ), + _buildInfoLine( + context, + 'От разработчика', + 'Обновление приложения, скидки и акции', + ), + _buildInfoLine( + context, + 'Мои коллекции', + 'Появление новых карточек в избранных коллекциях и новых коллекций у любимых авторов', + ), + _buildInfoLine( + context, + 'Авторам коллекций', + 'Новые подписчики в ваших публичных коллекциях и предложенные ими карточки', + ), + ], + ), + ), + ); + } + + Widget _buildInfoLine(BuildContext context, String title, String subTitle) { + return GestureDetector( + onTap: () {}, + child: Container( + width: double.infinity, + decoration: BoxDecoration( + color: AppColors.white, + borderRadius: BorderRadius.all(Radius.circular(12)).r, + ), + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 16).r, + child: Row( + children: [ + Expanded( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + AppTypography( + title, + type: Regular16px(), + color: Colors.black, + ), + AppTypography( + subTitle, + type: Regular12px(), + color: AppColors.disabled, + maxLines: 99, + ), + ], + ), + ), + CupertinoSwitch( + value: true, + onChanged: (value) {}, + activeTrackColor: AppColors.primary, + ), + ], + ), + ), + ), + ); + } +} diff --git a/lib/screens/settings/states/profile.dart b/lib/screens/settings/states/profile.dart new file mode 100644 index 0000000..a3385c2 --- /dev/null +++ b/lib/screens/settings/states/profile.dart @@ -0,0 +1,130 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:remever/common/resources.dart'; +import 'package:remever/common/widgets/typography.dart'; +import 'package:remever/common/widgets/wspace.dart'; +import 'package:remever/components/extensions/context.dart'; +import 'package:remever/gen/assets.gen.dart'; +import 'package:remever/screens/settings/cubit/settings_cubit.dart'; +import 'package:remever/common/functions.dart'; + +class ProfileSettingsState extends StatelessWidget { + const ProfileSettingsState({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bg, + appBar: _buildAppBar(context), + body: Padding( + padding: EdgeInsets.all(16.r), + child: Container( + width: double.infinity, + height: 410.h, + decoration: BoxDecoration( + color: AppColors.white, + borderRadius: BorderRadius.circular(12.r), + ), + child: Column( + children: [ + HSpace(32), + _buildAvatar(), + HSpace(12), + _buildInfoLine( + context, + Assets.icons.settingsName, + 'Антон Городецкий', + Colors.black, + () {}, + ), + _buildDivider(), + _buildInfoLine( + context, + Assets.icons.settingsMail, + 'anton.gorod@gmail.com', + Colors.black, + () {}, + ), + _buildDivider(), + _buildInfoLine( + context, + Assets.icons.settingsPhone, + '+7 900 123 45 67', + Colors.black, + () {}, + ), + _buildDivider(thickness: 3), + _buildInfoLine( + context, + Assets.icons.settingsTrash, + 'Удалить профиль', + AppColors.danger, + () {}, + ), + ], + ), + ), + ), + ); + } + + /// AppBar экрана профиля + AppBar _buildAppBar(BuildContext context) { + return AppBar( + toolbarHeight: 66.h, + backgroundColor: AppColors.white, + shadowColor: Colors.transparent, + centerTitle: true, + title: AppTypography('Профиль', type: SemiBold20px()), + leading: IconButton( + onPressed: () => context.read().toInitialState(), + icon: const Icon(CupertinoIcons.left_chevron), + color: Colors.black, + ), + actions: [ + IconButton( + onPressed: () => showInfoToast('Тут будет выход'), + icon: Assets.icons.settingsExit.image(height: 24.h, width: 24.w), + color: Colors.black, + ), + ], + ); + } + + /// Аватар пользователя + Widget _buildAvatar() { + return CircleAvatar( + backgroundImage: Assets.images.imgCard.provider(), + radius: 82.r, + ); + } + + /// Общий элемент информации + Widget _buildInfoLine( + BuildContext context, + AssetGenImage icon, + String title, + Color color, + void Function()? onTap, + ) { + return GestureDetector( + onTap: onTap, + child: Padding( + padding: EdgeInsets.all(16.r), + child: Row( + children: [ + icon.image(height: 20.h, width: 20.w), + WSpace(12), + AppTypography(title, type: Medium16px(), color: color), + ], + ), + ), + ); + } + + /// Переиспользуемый разделитель + Widget _buildDivider({double thickness = 1}) { + return Divider(height: 1, thickness: thickness); + } +}