diff --git a/lib/localizations/de.json b/lib/localizations/de.json index 01a02ca..afecd28 100644 --- a/lib/localizations/de.json +++ b/lib/localizations/de.json @@ -309,6 +309,27 @@ "selectMapLayer": "Kartenschicht Auswählen", "noTileProvidersAvailable": "Keine Kachel-Anbieter verfügbar" }, + "advancedEdit": { + "title": "Erweiterte Bearbeitungsoptionen", + "subtitle": "Diese Editoren bieten erweiterte Funktionen für komplexe Bearbeitungen.", + "webEditors": "Web-Editoren", + "mobileEditors": "Mobile Editoren", + "iDEditor": "iD Editor", + "iDEditorSubtitle": "Voll ausgestatteter Web-Editor - funktioniert immer", + "rapidEditor": "RapiD Editor", + "rapidEditorSubtitle": "KI-unterstütztes Bearbeiten mit Facebook-Daten", + "vespucci": "Vespucci", + "vespucciSubtitle": "Erweiterte Android OSM-Editor", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "Umfragebasierte Mapping-App", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "Schnelle POI-Bearbeitung", + "goMap": "Go Map!!", + "goMapSubtitle": "iOS OSM-Editor", + "couldNotOpenEditor": "Editor konnte nicht geöffnet werden - App möglicherweise nicht installiert", + "couldNotOpenURL": "URL konnte nicht geöffnet werden", + "couldNotOpenOSMWebsite": "OSM-Website konnte nicht geöffnet werden" + }, "networkStatus": { "showIndicator": "Netzwerkstatus-Anzeige anzeigen", "showIndicatorSubtitle": "Netzwerk-Ladestatus und Fehlerstatus auf der Karte anzeigen", diff --git a/lib/localizations/es.json b/lib/localizations/es.json index ac78f5a..fc09955 100644 --- a/lib/localizations/es.json +++ b/lib/localizations/es.json @@ -327,6 +327,27 @@ "selectMapLayer": "Seleccionar Capa del Mapa", "noTileProvidersAvailable": "No hay proveedores de teselas disponibles" }, + "advancedEdit": { + "title": "Opciones de Edición Avanzada", + "subtitle": "Estos editores ofrecen funciones más avanzadas para ediciones complejas.", + "webEditors": "Editores Web", + "mobileEditors": "Editores Móviles", + "iDEditor": "Editor iD", + "iDEditorSubtitle": "Editor web completo - siempre funciona", + "rapidEditor": "Editor RapiD", + "rapidEditorSubtitle": "Edición asistida por IA con datos de Facebook", + "vespucci": "Vespucci", + "vespucciSubtitle": "Editor OSM avanzado para Android", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "Aplicación de mapeo basada en encuestas", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "Edición rápida de POI", + "goMap": "Go Map!!", + "goMapSubtitle": "Editor OSM para iOS", + "couldNotOpenEditor": "No se pudo abrir el editor - la aplicación puede no estar instalada", + "couldNotOpenURL": "No se pudo abrir la URL", + "couldNotOpenOSMWebsite": "No se pudo abrir el sitio web de OSM" + }, "networkStatus": { "showIndicator": "Mostrar indicador de estado de red", "showIndicatorSubtitle": "Mostrar estado de carga y errores de red en el mapa", diff --git a/lib/localizations/fr.json b/lib/localizations/fr.json index af46e49..f4eb673 100644 --- a/lib/localizations/fr.json +++ b/lib/localizations/fr.json @@ -327,6 +327,27 @@ "selectMapLayer": "Sélectionner la Couche de Carte", "noTileProvidersAvailable": "Aucun fournisseur de tuiles disponible" }, + "advancedEdit": { + "title": "Options d'Édition Avancées", + "subtitle": "Ces éditeurs offrent des fonctionnalités plus avancées pour les modifications complexes.", + "webEditors": "Éditeurs Web", + "mobileEditors": "Éditeurs Mobiles", + "iDEditor": "Éditeur iD", + "iDEditorSubtitle": "Éditeur web complet - fonctionne toujours", + "rapidEditor": "Éditeur RapiD", + "rapidEditorSubtitle": "Édition assistée par IA avec des données Facebook", + "vespucci": "Vespucci", + "vespucciSubtitle": "Éditeur OSM avancé Android", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "Application de cartographie basée sur des enquêtes", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "Édition rapide de POI", + "goMap": "Go Map!!", + "goMapSubtitle": "Éditeur OSM iOS", + "couldNotOpenEditor": "Impossible d'ouvrir l'éditeur - l'application peut ne pas être installée", + "couldNotOpenURL": "Impossible d'ouvrir l'URL", + "couldNotOpenOSMWebsite": "Impossible d'ouvrir le site web OSM" + }, "networkStatus": { "showIndicator": "Afficher l'indicateur de statut réseau", "showIndicatorSubtitle": "Afficher l'état de chargement et d'erreur réseau sur la carte", diff --git a/lib/localizations/it.json b/lib/localizations/it.json index 31851a0..3a5db4a 100644 --- a/lib/localizations/it.json +++ b/lib/localizations/it.json @@ -327,6 +327,27 @@ "selectMapLayer": "Seleziona Livello Mappa", "noTileProvidersAvailable": "Nessun fornitore di tile disponibile" }, + "advancedEdit": { + "title": "Opzioni di Modifica Avanzate", + "subtitle": "Questi editor offrono funzionalità più avanzate per modifiche complesse.", + "webEditors": "Editor Web", + "mobileEditors": "Editor Mobili", + "iDEditor": "Editor iD", + "iDEditorSubtitle": "Editor web completo - funziona sempre", + "rapidEditor": "Editor RapiD", + "rapidEditorSubtitle": "Modifica assistita da IA con dati Facebook", + "vespucci": "Vespucci", + "vespucciSubtitle": "Editor OSM avanzato Android", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "App di mappatura basata su sondaggi", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "Modifica rapida POI", + "goMap": "Go Map!!", + "goMapSubtitle": "Editor OSM iOS", + "couldNotOpenEditor": "Impossibile aprire l'editor - l'app potrebbe non essere installata", + "couldNotOpenURL": "Impossibile aprire l'URL", + "couldNotOpenOSMWebsite": "Impossibile aprire il sito web OSM" + }, "networkStatus": { "showIndicator": "Mostra indicatore di stato di rete", "showIndicatorSubtitle": "Visualizza lo stato di caricamento e errori di rete sulla mappa", diff --git a/lib/localizations/pt.json b/lib/localizations/pt.json index 8730981..564185e 100644 --- a/lib/localizations/pt.json +++ b/lib/localizations/pt.json @@ -327,6 +327,27 @@ "selectMapLayer": "Selecionar Camada do Mapa", "noTileProvidersAvailable": "Nenhum provedor de tiles disponível" }, + "advancedEdit": { + "title": "Opções de Edição Avançada", + "subtitle": "Estes editores oferecem recursos mais avançados para edições complexas.", + "webEditors": "Editores Web", + "mobileEditors": "Editores Móveis", + "iDEditor": "Editor iD", + "iDEditorSubtitle": "Editor web completo - sempre funciona", + "rapidEditor": "Editor RapiD", + "rapidEditorSubtitle": "Edição assistida por IA com dados do Facebook", + "vespucci": "Vespucci", + "vespucciSubtitle": "Editor OSM avançado para Android", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "Aplicativo de mapeamento baseado em pesquisas", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "Edição rápida de POI", + "goMap": "Go Map!!", + "goMapSubtitle": "Editor OSM iOS", + "couldNotOpenEditor": "Não foi possível abrir o editor - aplicativo pode não estar instalado", + "couldNotOpenURL": "Não foi possível abrir a URL", + "couldNotOpenOSMWebsite": "Não foi possível abrir o site do OSM" + }, "networkStatus": { "showIndicator": "Exibir indicador de status de rede", "showIndicatorSubtitle": "Mostrar status de carregamento e erro de rede no mapa", diff --git a/lib/localizations/zh.json b/lib/localizations/zh.json index 912e6f9..66cad4d 100644 --- a/lib/localizations/zh.json +++ b/lib/localizations/zh.json @@ -327,6 +327,27 @@ "selectMapLayer": "选择地图图层", "noTileProvidersAvailable": "无可用瓦片提供商" }, + "advancedEdit": { + "title": "高级编辑选项", + "subtitle": "这些编辑器为复杂编辑提供更高级的功能。", + "webEditors": "网页编辑器", + "mobileEditors": "移动编辑器", + "iDEditor": "iD 编辑器", + "iDEditorSubtitle": "功能完整的网页编辑器 - 始终有效", + "rapidEditor": "RapiD 编辑器", + "rapidEditorSubtitle": "使用Facebook数据的AI辅助编辑", + "vespucci": "Vespucci", + "vespucciSubtitle": "高级Android OSM编辑器", + "streetComplete": "StreetComplete", + "streetCompleteSubtitle": "基于调查的地图应用", + "everyDoor": "EveryDoor", + "everyDoorSubtitle": "快速POI编辑", + "goMap": "Go Map!!", + "goMapSubtitle": "iOS OSM编辑器", + "couldNotOpenEditor": "无法打开编辑器 - 应用可能未安装", + "couldNotOpenURL": "无法打开URL", + "couldNotOpenOSMWebsite": "无法打开OSM网站" + }, "networkStatus": { "showIndicator": "显示网络状态指示器", "showIndicatorSubtitle": "在地图上显示网络加载和错误状态", diff --git a/lib/widgets/suspected_location_sheet.dart b/lib/widgets/suspected_location_sheet.dart index dfa24e7..d739403 100644 --- a/lib/widgets/suspected_location_sheet.dart +++ b/lib/widgets/suspected_location_sheet.dart @@ -20,8 +20,6 @@ class SuspectedLocationSheet extends StatelessWidget { final appState = context.watch(); final locService = LocalizationService.instance; - - // Get all fields except location and ticket_no final displayData = {}; for (final entry in location.allFields.entries) { @@ -55,52 +53,56 @@ class SuspectedLocationSheet extends StatelessWidget { children: [ // Display all fields ...displayData.entries.map( - (e) => Padding( - padding: const EdgeInsets.symmetric(vertical: 2), - child: Row( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - e.key, - style: TextStyle( - fontWeight: FontWeight.w500, - color: Theme.of(context).colorScheme.onSurface, - ), - ), - const SizedBox(width: 8), - Expanded( - child: e.key.toLowerCase().contains('url') && e.value.isNotEmpty - ? GestureDetector( - onTap: () async { - final uri = Uri.parse(e.value); - if (await canLaunchUrl(uri)) { - await launchUrl(uri, mode: LaunchMode.externalApplication); - } else { - if (context.mounted) { - ScaffoldMessenger.of(context).showSnackBar( - SnackBar( - content: Text('Could not open URL: ${e.value}'), - ), - ); - } - } - }, - child: Text( - e.value, - style: TextStyle( - color: Theme.of(context).colorScheme.primary, - decoration: TextDecoration.underline, - ), - softWrap: true, - ), - ) - : Text( - e.value, + (e) => Padding( + padding: const EdgeInsets.symmetric(vertical: 2), + child: Row( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + e.key, style: TextStyle( - color: Theme.of(context).colorScheme.onSurface.withOpacity(0.7), + fontWeight: FontWeight.w500, + color: Theme.of(context).colorScheme.onSurface, ), - softWrap: true, ), + const SizedBox(width: 8), + Expanded( + child: e.key.toLowerCase().contains('url') && e.value.isNotEmpty + ? GestureDetector( + onTap: () async { + final uri = Uri.parse(e.value); + if (await canLaunchUrl(uri)) { + await launchUrl(uri, mode: LaunchMode.externalApplication); + } else { + if (context.mounted) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar( + content: Text('Could not open URL: ${e.value}'), + ), + ); + } + } + }, + child: Text( + e.value, + style: TextStyle( + color: Theme.of(context).colorScheme.primary, + decoration: TextDecoration.underline, + ), + softWrap: true, + ), + ) + : Text( + e.value, + style: TextStyle( + color: Theme.of(context).colorScheme.onSurface.withOpacity(0.7), + ), + softWrap: true, + ), + ), + ], + ), + ), ), ], ), diff --git a/pubspec.lock b/pubspec.lock index 31e9d8c..ab57390 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -166,6 +166,14 @@ packages: url: "https://pub.dev" source: hosted version: "0.14.4" + flutter_linkify: + dependency: "direct main" + description: + name: flutter_linkify + sha256: "74669e06a8f358fee4512b4320c0b80e51cffc496607931de68d28f099254073" + url: "https://pub.dev" + source: hosted + version: "6.0.0" flutter_local_notifications: dependency: "direct main" description: @@ -395,6 +403,14 @@ packages: url: "https://pub.dev" source: hosted version: "0.9.1" + linkify: + dependency: transitive + description: + name: linkify + sha256: "4139ea77f4651ab9c315b577da2dd108d9aa0bd84b5d03d33323f1970c645832" + url: "https://pub.dev" + source: hosted + version: "5.0.0" lists: dependency: transitive description: