mirror of
https://git.selfprivacy.org/kherel/selfprivacy.org.app.git
synced 2025-01-23 17:26:35 +00:00
feat(about): Add privacy policy and licenses
This commit is contained in:
parent
12de989df6
commit
d1c4aa9fc6
|
@ -54,7 +54,8 @@
|
||||||
"about_application_page": {
|
"about_application_page": {
|
||||||
"title": "About",
|
"title": "About",
|
||||||
"application_version_text": "Application version v.{}",
|
"application_version_text": "Application version v.{}",
|
||||||
"api_version_text": "Server API version v.{}"
|
"api_version_text": "Server API version v.{}",
|
||||||
|
"privacy_policy": "Privacy policy"
|
||||||
},
|
},
|
||||||
"application_settings": {
|
"application_settings": {
|
||||||
"title": "Application settings",
|
"title": "Application settings",
|
||||||
|
|
|
@ -54,7 +54,8 @@
|
||||||
"about_application_page": {
|
"about_application_page": {
|
||||||
"title": "О приложении",
|
"title": "О приложении",
|
||||||
"application_version_text": "Версия приложения v.{}",
|
"application_version_text": "Версия приложения v.{}",
|
||||||
"api_version_text": "Версия API сервера v.{}"
|
"api_version_text": "Версия API сервера v.{}",
|
||||||
|
"privacy_policy": "Политика конфиденциальности"
|
||||||
},
|
},
|
||||||
"application_settings": {
|
"application_settings": {
|
||||||
"title": "Настройки приложения",
|
"title": "Настройки приложения",
|
||||||
|
|
|
@ -5,6 +5,7 @@ import 'package:selfprivacy/ui/components/brand_header/brand_header.dart';
|
||||||
import 'package:selfprivacy/ui/components/brand_text/brand_text.dart';
|
import 'package:selfprivacy/ui/components/brand_text/brand_text.dart';
|
||||||
import 'package:package_info/package_info.dart';
|
import 'package:package_info/package_info.dart';
|
||||||
import 'package:easy_localization/easy_localization.dart';
|
import 'package:easy_localization/easy_localization.dart';
|
||||||
|
import 'package:url_launcher/url_launcher.dart';
|
||||||
|
|
||||||
class AboutApplicationPage extends StatelessWidget {
|
class AboutApplicationPage extends StatelessWidget {
|
||||||
const AboutApplicationPage({super.key});
|
const AboutApplicationPage({super.key});
|
||||||
|
@ -37,6 +38,26 @@ class AboutApplicationPage extends StatelessWidget {
|
||||||
.tr(args: [snapshot.data.toString()]),
|
.tr(args: [snapshot.data.toString()]),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
const SizedBox(height: 10),
|
||||||
|
// Button to call showAboutDialog
|
||||||
|
TextButton(
|
||||||
|
onPressed: () => showAboutDialog(
|
||||||
|
context: context,
|
||||||
|
applicationName: 'SelfPrivacy',
|
||||||
|
applicationLegalese: '© 2022 SelfPrivacy',
|
||||||
|
// Link to privacy policy
|
||||||
|
children: [
|
||||||
|
TextButton(
|
||||||
|
onPressed: () => launchUrl(
|
||||||
|
Uri.parse('https://selfprivacy.ru/privacy-policy'),
|
||||||
|
mode: LaunchMode.externalApplication,
|
||||||
|
),
|
||||||
|
child: Text('about_application_page.privacy_policy'.tr()),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
child: const Text('Show about dialog'),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
@ -122,7 +122,8 @@ class InitializingPage extends StatelessWidget {
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
if (cubit.state is ServerInstallationEmpty)
|
if (cubit.state is ServerInstallationEmpty ||
|
||||||
|
cubit.state is ServerInstallationNotFinished)
|
||||||
Container(
|
Container(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
child: BrandButton.text(
|
child: BrandButton.text(
|
||||||
|
|
Loading…
Reference in a new issue