Notrufnummern-Datenbasis, Ländererkennung, State-Management und Lokalisierung (AP1-AP7)

Implementiert den kompletten Kern-Flow der Emergency App gemäß docs/plan.md:
- Notrufnummern-Datenbasis für 199 Länder + Modelle/Repository (AP1)
- DialerService für tel:-Notrufe ohne Auto-Dial (AP2)
- Statisches UI mit Panik-Button-Fallback (AP3)
- Priorisierte Ländererkennung: SIM/Netz -> GPS/Geocoding -> Cache (AP4)
- EmergencyProvider verdrahtet Repository/LocationService mit der UI (AP5)
- Manuelle Länderauswahl als Fallback samt eigener Priorität (AP6)
- UI-Lokalisierung (de/en/fr/es), an erkanntes Land gekoppelt (AP7)

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
root
2026-07-24 11:29:38 +02:00
co-authored by Claude Sonnet 5
parent 40e95cc495
commit e3aa088bc2
54 changed files with 7550 additions and 145 deletions
@@ -0,0 +1,35 @@
import 'package:flutter/material.dart';
import '../../../models/country.dart';
/// Kompakter Header, der Flagge und Name eines [Country] anzeigt.
class CountryHeader extends StatelessWidget {
const CountryHeader({super.key, required this.country});
final Country country;
/// Wählt `nameDe`/`nameEn` (AP1-Datenfeld, keine ARB-Übersetzung die
/// Notrufnummern-Datenbasis kennt bewusst nur diese zwei Sprachen, siehe
/// `docs/plan.md` Abschnitt 4) passend zur aktuellen App-Locale aus.
String _localizedName(BuildContext context) {
final languageCode = Localizations.localeOf(context).languageCode;
return languageCode == 'de' ? country.nameDe : country.nameEn;
}
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.symmetric(vertical: 12),
child: Row(
children: [
Text(country.flag, style: const TextStyle(fontSize: 32)),
const SizedBox(width: 12),
Text(
_localizedName(context),
style: Theme.of(context).textTheme.titleLarge,
),
],
),
);
}
}