app: privacy policy link in the settings sheet
- new lib/src/ui/links.dart holds kPrivacyPolicyUrl (single source of truth for the app, the store listing and the compliance docs) - settings sheet: "Datenschutzerklaerung" tile opens the policy in the browser via url_launcher; manifest grown a <queries> VIEW/https intent so Android 11+ can resolve it - verified on device: tap sends ACTION_VIEW for the URL and Chrome comes up - guard: tools/build_release.sh aborts while links.dart still contains the example.invalid placeholder, so a release cannot ship without a policy URL - docs: compliance row updated (in-app entry done, only the public URL missing)
This commit is contained in:
@@ -3,6 +3,7 @@ import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
import 'src/ads/ads_service.dart';
|
||||
import 'src/game/iron_arc_game.dart';
|
||||
@@ -10,6 +11,7 @@ import 'src/native/native_match.dart';
|
||||
import 'src/net/api_client.dart';
|
||||
import 'src/net/match_session.dart';
|
||||
import 'src/net/offline_queue.dart';
|
||||
import 'src/ui/links.dart';
|
||||
import 'src/ui/splash_screen.dart';
|
||||
import 'src/ui/widgets.dart';
|
||||
|
||||
@@ -183,6 +185,20 @@ class _MatchScreenState extends State<MatchScreen> {
|
||||
if (mounted) _toast('Consent: ${_ads.consentLabel}');
|
||||
},
|
||||
),
|
||||
ListTile(
|
||||
leading: const Icon(Icons.description_outlined),
|
||||
title: const Text('Datenschutzerklärung'),
|
||||
subtitle: const Text('Öffnet die Webseite'),
|
||||
trailing: const Icon(Icons.open_in_new, size: 18),
|
||||
onTap: () async {
|
||||
Navigator.pop(sheetContext);
|
||||
final ok = await launchUrl(
|
||||
Uri.parse(kPrivacyPolicyUrl),
|
||||
mode: LaunchMode.externalApplication,
|
||||
);
|
||||
if (!ok && mounted) _toast('Keine App zum Öffnen gefunden');
|
||||
},
|
||||
),
|
||||
ListTile(
|
||||
leading: const Icon(Icons.campaign_outlined),
|
||||
title: const Text('Werbe-Status'),
|
||||
|
||||
Reference in New Issue
Block a user