glanzlicht / Meinweimar_Tourguide

Intelligenter Tourguide für Weimar

Verified secure showcase
167 Files 833 KB Public size 12 Redacted Dart · Markdown · YAML · HTML · JSON · GITIGNORE

Project overview

Meinweimar_Tourguide is a verified code showcase with 167 visible project entries across 5 top-level modules. The primary detected language is Dart; protected files remain visible in the structure while their contents stay private.

README

MeinWeimar Tourguide

MeinWeimar Tourguide

Eine produktionsnahe Flutter-App fuer Stadtentdeckung, Tourplanung und Sprachlernen in Weimar. Die App verbindet eine responsive mobile und webfaehige Oberflaeche mit einer WordPress-REST-API und macht aus redaktionellen Inhalten konkrete Wege, Orte und Empfehlungen.

Dieses Repository zeigt neben der UI auch die technische Produktarbeit dahinter: API-Integration, Offline-tolerante Datenhaltung, Lokalisierung, Routing, Audio/TTS, Analytics, Deep Links und automatisierte Qualitaetssicherung.

App-Eindruecke

Start · Entdecken · Touren · Karte · Mehr

Produktumfang

  • Entdecken: POIs, Touren, Veranstaltungen, Partner und Themen mit Suche,
  • Filtern und fehlertoleranter Trefferlogik.

  • Unterwegs: Kartenansicht, Standort, Fussgaenger-Routing, Tourfortschritt,
  • Favoriten und eine persoenliche Route aus der eigenen Weimar-Liste.

  • Mehrsprachigkeit: UI und CMS-Inhalte in Deutsch, Englisch,
  • Niederlaendisch, Franzoesisch, Polnisch, Italienisch, Spanisch und Tschechisch.

  • Audio und Lernen: Guide-Audio, Flutter TTS sowie SprachGuide-Kurse und
  • Lern-Touren.

  • Redaktion und Betrieb: WordPress REST API, Oeffnungszeiten mit
  • Zeitzonenlogik, Kampagnen, Partnerplatzierungen, Deep Links und First-Party- Analytics.

  • Responsive UX: kleine Displays, grosse Systemschrift, dynamische
  • Kartenhoehen und versionierte Web-Releases ohne veraltete Service-Worker- Assets.

Technischer Steckbrief

BereichUmsetzung
FrameworkFlutter / Dart 3.4+
PlattformeniOS, Android und Web
DatenWordPress REST API, typisierte Models und Repositories
Kartenflutter_map, latlong2, Standort und Fussgaenger-Routing
Audiojust_audio, flutter_tts
Lokaler ZustandShared Preferences, begrenztes Caching und Analytics-Puffer
QualitaetFlutter Analyzer, Widget- und Service-Tests, Lokalisierungs- und API-Modelltests

Die Codebasis ist nach Verantwortlichkeiten gegliedert:

lib/
	core/          gemeinsame API-, Lokalisierungs- und Navigationslogik
	data/          Datenzugriff und DTO-nahe Strukturen
	features/      produktbezogene Screens und Flows
	models/        fachliche Modelle
	repositories/  Datenzugriff hinter stabilen Schnittstellen
	services/      Routing, Audio, Analytics und Plattformdienste
	widgets/       wiederverwendbare UI-Bausteine
test/            fokussierte Tests fuer Services, Modelle und Widgets

Lokal starten

Voraussetzungen: aktuelles Flutter SDK und das darin enthaltene Dart SDK.

flutter pub get
flutter analyze
flutter test
flutter run -d chrome

Die Anwendung verwendet standardmaessig die oeffentliche API: https://tour.meinweimar.de/wp-json/meinweimar/v1

Web-Release

Fuer einen Web-Release das versionierte Build-Skript verwenden:

./tool/build_web_release.sh

Das Skript legt den Runtime-Build unter build/web/releases/<release-id>/ ab. Launcher und Versionsendpunkt bleiben bewusst nicht cachebar, damit Browser nach einem Reload die aktuelle Version auflosen. Startup-Diagnostik ist nur mit ?mwdebug=1 aktiv.

Dokumentation

  • [Deep Links](DEEP_LINKS.md) - Web-Routen fuer Bereiche, Touren und POIs
  • [Projektstatus](PROJECT_STATE.md) - aktueller Funktions- und Integrationsstand
  • [Changelog](CHANGELOG.md) - nachvollziehbare Produkt- und UX-Iterationen
  • [API-Integration](docs/API_INTEGRATION.md) - technische Integrationsnotizen
lib/features/events/event_detail_page.dartDart
import 'package:flutter/material.dart';
import '../../core/theme/app_colors.dart';
import '../../data/app_data_scope.dart';
import '../../models/event.dart';
import '../../repositories/event_repository.dart';
import '../../services/external_link_service.dart';
import '../../services/external_navigation_service.dart';
import '../../widgets/remote_image.dart';
import 'event_ui_text.dart';
class EventDetailPage extends StatefulWidget {
const EventDetailPage({super.key, required this.event});
final Event event;
@override
State<EventDetailPage> createState() => _EventDetailPageState();
}
class _EventDetailPageState extends State<EventDetailPage> {
late Event _event;
bool _loadingDetail = true;
EventActionUrls? _actions;
@override
void initState() {
super.initState();
_event = widget.event;
WidgetsBinding.instance.addPostFrameCallback((_) {
_loadDetail();
_loadActions();
});
}
Future<void> _loadActions() async {
try {
final actions =
await AppDataScope.read(context).eventActions(widget.event.id);
if (!mounted) return;
setState(() => _actions = actions);
} catch (_) {
// Keep any action URLs that arrived with the event feed as fallback.
}
}
Future<void> _loadDetail() async {
try {
final detail =
await AppDataScope.read(context).eventDetail(widget.event.id);
if (!mounted) return;
setState(() {
_event = detail;
_loadingDetail = false;
});
} catch (_) {
if (!mounted) return;
setState(() => _loadingDetail = false);
}
}
@override
Widget build(BuildContext context) {
final event = _event;
final lang = Localizations.localeOf(context).languageCode;
final t = EventUiText(lang);
final title = event.title.get(lang);
final short = event.shortDescription.get(lang);
final description = event.description.get(lang);
final dateLabel = eventDateRangeLabel(context, event);
final timeLabel = eventTimeRangeLabel(context, event);
final priceLabel = _priceLabel(event, t);
final ticketActionUrl =
_nonEmptyUrl(_actions?.ticketUrl ?? event.ticketUrl);
final websiteActionUrl =
_nonEmptyUrl(_actions?.websiteUrl ?? event.websiteUrl);
final onlineActionUrl =
_nonEmptyUrl(_actions?.onlineUrl ?? event.onlineUrl);
final organizerActionUrl =
_nonEmptyUrl(_actions?.organizerUrl ?? event.organizerUrl);
final hasRoute = event.latitude != null &&
event.longitude != null &&
(event.latitude!.abs() > 0.000001 || event.longitude!.abs() > 0.000001);
final locationValue = [event.venueName, event.formattedAddress]
.where((v) => v?.trim().isNotEmpty == true)
.join('\n');
return Scaffold(
appBar: AppBar(title: Text(t.event)),
body: ListView(
padding: const EdgeInsets.only(bottom: 36),
children: [
if (_loadingDetail) const LinearProgressIndicator(minHeight: 2),
RemoteImage(
url: event.imageUrl,
width: double.infinity,
height: 260,
fit: BoxFit.cover,
fallbackIcon: Icons.event_rounded,
semanticLabel: title,
),
Padding(
padding: const EdgeInsets.fromLTRB(20, 20, 20, 0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Wrap(
spacing: 8,
runSpacing: 8,
children: [
_Pill(icon: Icons.calendar_month_rounded, label: dateLabel),
if (!event.allDay && timeLabel.isNotEmpty)
_Pill(icon: Icons.schedule_rounded, label: timeLabel),
if (event.categories.isNotEmpty)
_Pill(
icon: Icons.local_activity_outlined,
label: event.categories.first.name,
),
],
),
const SizedBox(height: 18),
Text(
title,
style: Theme.of(context).textTheme.headlineMedium?.copyWith(
fontWeight: FontWeight.w900,
height: 1.08,
),
),
if (short.isNotEmpty) ...[
const SizedBox(height: 10),
Text(
short,
style: Theme.of(context).textTheme.bodyLarge?.copyWith(
color: AppColors.mutedInk,
height: 1.45,
),
),
],
if (event.postponed || event.soldOut) ...[
const SizedBox(height: 14),
_StatusBanner(
text: event.postponed ? t.postponed : t.soldOut,
),
],
const SizedBox(height: 22),
_InfoRow(
icon: Icons.calendar_today_outlined,
title: t.date,
value: event.allDay
? '$dateLabel · ${t.allDayLower}'
: (timeLabel.isEmpty
? dateLabel
: '$dateLabel · $timeLabel'),
),
_InfoRow(
icon: Icons.location_on_outlined,
title: t.location,
value: locationValue,
),
if (priceLabel.isNotEmpty)
_InfoRow(
icon: Icons.confirmation_number_outlined,
title: t.admission,
value: priceLabel,
),
if (event.organizerName?.trim().isNotEmpty == true)
_InfoRow(
icon: Icons.apartment_rounded,
title: t.organizer,
value: event.organizerName!,
),
if (event.bookingRequired)
_InfoRow(
icon: Icons.event_available_outlined,
title: t.booking,
value: t.bookingRequired,
),
if (event.accessible)
_InfoRow(
icon: Icons.accessible_rounded,
title: t.accessibility,
value: t.accessible,
),
if (description.isNotEmpty) ...[
const SizedBox(height: 18),
Text(
t.about,
style: Theme.of(context)
.textTheme
.titleLarge
?.copyWith(fontWeight: FontWeight.w900),
),
const SizedBox(height: 8),
Text(
description,
style: const TextStyle(height: 1.55, fontSize: 16),
),
],
if (ticketActionUrl != null ||
websiteActionUrl != null ||
onlineActionUrl != null ||
organizerActionUrl != null ||
hasRoute) ...[
const SizedBox(height: 24),
if (ticketActionUrl != null)
SizedBox(
width: double.infinity,
child: FilledButton.icon(
onPressed: () =>
const ExternalLinkService().open(ticketActionUrl),
icon: const Icon(Icons.confirmation_number_rounded),
label: Text(t.tickets),
),
),
if (websiteActionUrl != null) ...[
const SizedBox(height: 8),
SizedBox(
width: double.infinity,
child: OutlinedButton.icon(
onPressed: () =>
const ExternalLinkService().open(websiteActionUrl),
icon: const Icon(Icons.language_rounded),
label: Text(t.eventWebsite),
),
),
],
if (hasRoute) ...[
const SizedBox(height: 8),
SizedBox(
width: double.infinity,
child: OutlinedButton.icon(
onPressed: () => ExternalNavigationService.navigateTo(
latitude: event.latitude!,
longitude: event.longitude!,
label: title,
),
icon: const Icon(Icons.directions_rounded),
label: Text(t.routeThere),
),
),
],
if (onlineActionUrl != null) ...[
const SizedBox(height: 8),
SizedBox(
width: double.infinity,
child: OutlinedButton.icon(
onPressed: () =>
const ExternalLinkService().open(onlineActionUrl),
icon: const Icon(Icons.live_tv_rounded),
label: Text(t.joinOnline),
),
),
],
if (organizerActionUrl != null &&
organizerActionUrl != websiteActionUrl) ...[
const SizedBox(height: 8),
SizedBox(
width: double.infinity,
child: OutlinedButton.icon(
onPressed: () => const ExternalLinkService()
.open(organizerActionUrl),
icon: const Icon(Icons.language_rounded),
label: Text(t.organizerWebsite),
),
),
],
],
],
),
),
],
),
);
}
}
String? _nonEmptyUrl(String? value) {
final trimmed = value?.trim();
return trimmed == null || trimmed.isEmpty ? null : trimmed;
}
class _Pill extends StatelessWidget {
const _Pill({required this.icon, required this.label});
final IconData icon;
final String label;
@override
Widget build(BuildContext context) => Container(
padding: const EdgeInsets.symmetric(horizontal: 11, vertical: 8),
decoration: BoxDecoration(
color: AppColors.softRed,
borderRadius: BorderRadius.circular(999),
),
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Icon(icon, size: 17, color: AppColors.heartRed),
const SizedBox(width: 6),
Text(label, style: const TextStyle(fontWeight: FontWeight.w800)),
],
),
);
}
class _InfoRow extends StatelessWidget {
const _InfoRow(
{required this.icon, required this.title, required this.value});
final IconData icon;
final String title;
final String value;
@override
Widget build(BuildContext context) {
if (value.trim().isEmpty) return const SizedBox.shrink();
return Padding(
padding: const EdgeInsets.only(bottom: 15),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Icon(icon, color: AppColors.heartRed),
const SizedBox(width: 12),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(title,
style: const TextStyle(fontWeight: FontWeight.w900)),
const SizedBox(height: 2),
Text(
value,
style:
const TextStyle(color: AppColors.mutedInk, height: 1.35),
),
],
),
),
],
),
);
}
}
class _StatusBanner extends StatelessWidget {
const _StatusBanner({required this.text});
final String text;
@override
Widget build(BuildContext context) => Container(
width: double.infinity,
padding: const EdgeInsets.all(12),
decoration: BoxDecoration(
color: AppColors.softRed,
borderRadius: BorderRadius.circular(14),
),
child: Text(
text,
style: const TextStyle(
fontWeight: FontWeight.w800,
color: AppColors.heartRed,
),
),
);
}
String _priceLabel(Event event, EventUiText t) {
if (event.free) return t.freeAdmission;
final min = event.priceMin;
final max = event.priceMax;
if (min == null && max == null) return '';
String money(double v) => v == v.roundToDouble()
? v.toStringAsFixed(0)
: v.toStringAsFixed(2).replaceAll('.', ',');
if (min != null && max != null && min != max) {
return '${money(min)}–${money(max)} ${event.currency}';
}
return '${money(min ?? max!)} ${event.currency}';
}

Architecture

High-level modules detected from the verified public snapshot. Protected implementation details are intentionally omitted.

libmodule
testmodule
docsmodule
webmodule
toolmodule

Technology stack

DartMarkdownLOCKHTMLShellHTACCESSFlutter / Dart
Dart89.9%
Markdown3.9%
LOCK3.1%
HTML1.7%
Shell0.8%
HTACCESS0.2%
YAML0.1%
METADATA0.1%