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/learning/learning_home_page.dartDart
import 'package:flutter/material.dart';
import '../../core/localization/app_localizations.dart';
import '../../core/theme/app_colors.dart';
import '../../data/app_data_scope.dart';
import '../../models/ad_campaign.dart';
import '../../widgets/sponsored_banner.dart';
import '../../models/learning_course.dart';
import '../../repositories/learning_repository.dart';
import '../../services/learning_progress_service.dart';
import '../../services/analytics_service.dart';
import 'language_learning_tours_page.dart';
import 'learning_course_page.dart';
class LearningHomePage extends StatefulWidget {
const LearningHomePage({super.key});
@override
State<LearningHomePage> createState() => _LearningHomePageState();
}
class _LearningHomePageState extends State<LearningHomePage> {
final _repository = LearningRepository();
final _progress = LearningProgressService();
Future<List<LearningCourse>>? _future;
String? _lang;
@override
void initState() {
super.initState();
AnalyticsService.instance.screenView('learning_home');
}
@override
void didChangeDependencies() {
super.didChangeDependencies();
final lang = Localizations.localeOf(context).languageCode;
if (_future == null || lang != _lang) {
_lang = lang;
_future = _repository.fetchCourses(languageCode: lang);
}
}
Future<void> _refresh() async {
final lang = Localizations.localeOf(context).languageCode;
final future = _repository.fetchCourses(languageCode: lang);
setState(() => _future = future);
await future;
}
@override
void dispose() {
_repository.dispose();
super.dispose();
}
@override
Widget build(BuildContext context) {
final l10n = AppLocalizations.of(context);
final appAd = AppDataScope.of(context).campaignFor(AdPlacement.appBanner);
final learningAd = appAd?.supportsScreen('learning') == true ? appAd : null;
return Scaffold(
appBar: AppBar(title: Text(l10n.t('extrasLanguageGuideTitle'))),
body: RefreshIndicator(
onRefresh: _refresh,
child: ListView(
padding: const EdgeInsets.fromLTRB(20, 8, 20, 30),
children: [
Container(
padding: const EdgeInsets.all(18),
decoration: BoxDecoration(
color: AppColors.ink,
borderRadius: BorderRadius.circular(24)),
child:
Row(crossAxisAlignment: CrossAxisAlignment.start, children: [
const CircleAvatar(
radius: 25,
backgroundColor: Colors.white,
child: Icon(Icons.translate_rounded, color: AppColors.ink)),
const SizedBox(width: 14),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(l10n.t('learnGerman'),
style: const TextStyle(
color: Colors.white,
fontSize: 22,
fontWeight: FontWeight.w900)),
const SizedBox(height: 5),
Text(l10n.t('learnGermanTeaser'),
style: const TextStyle(
color: Colors.white70, height: 1.35)),
])),
]),
),
const SizedBox(height: 14),
if (learningAd != null) ...[
SponsoredBanner(
campaign: learningAd,
compact: true,
placement: 'app_banner_learning'),
const SizedBox(height: 16),
],
FutureBuilder<int>(
future: _progress.streak(),
builder: (context, snapshot) => Row(children: [
const Icon(Icons.local_fire_department_rounded,
color: AppColors.heartRed, size: 20),
const SizedBox(width: 6),
Text(l10n.tf('learningStreak', {'n': '${snapshot.data ?? 0}'}),
style: const TextStyle(fontWeight: FontWeight.w800)),
]),
),
const SizedBox(height: 24),
Text(l10n.t('learningToursTitle'),
style: Theme.of(context)
.textTheme
.titleLarge
?.copyWith(fontWeight: FontWeight.w900)),
const SizedBox(height: 6),
Text(l10n.t('learningToursHomeTeaser'),
style: const TextStyle(color: AppColors.mutedInk)),
const SizedBox(height: 12),
Material(
color: AppColors.softRed,
borderRadius: BorderRadius.circular(22),
child: InkWell(
borderRadius: BorderRadius.circular(22),
onTap: () {
AnalyticsService.instance.track('learning_tours_open');
Navigator.of(context).push(MaterialPageRoute(
builder: (_) => const LanguageLearningToursPage()));
},
child: Padding(
padding: const EdgeInsets.all(16),
child: Row(children: [
const CircleAvatar(
radius: 24,
backgroundColor: AppColors.heartRed,
child: Icon(Icons.route_rounded, color: Colors.white)),
const SizedBox(width: 14),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(l10n.t('learningToursCta'),
style: const TextStyle(
fontSize: 17, fontWeight: FontWeight.w900)),
const SizedBox(height: 4),
Text(l10n.t('learningToursCtaSubtitle'),
style: const TextStyle(
color: AppColors.mutedInk, height: 1.3)),
])),
const Icon(Icons.chevron_right_rounded),
]),
),
),
),
const SizedBox(height: 28),
Text(l10n.t('learningCourses'),
style: Theme.of(context)
.textTheme
.titleLarge
?.copyWith(fontWeight: FontWeight.w900)),
const SizedBox(height: 12),
FutureBuilder<List<LearningCourse>>(
future: _future,
builder: (context, snapshot) {
if (snapshot.connectionState != ConnectionState.done) {
return const Center(
child: Padding(
padding: EdgeInsets.all(30),
child: CircularProgressIndicator()));
}
if (snapshot.hasError) return _ErrorCard(onRetry: _refresh);
final courses = snapshot.data ?? const [];
if (courses.isEmpty) return Text(l10n.t('learningComingSoon'));
return Column(children: [
for (final course in courses)
Padding(
padding: const EdgeInsets.only(bottom: 12),
child: _CourseCard(
course: course,
onTap: () {
AnalyticsService.instance.track(
'learning_course_open',
properties: {'course_id': course.id});
Navigator.of(context).push(MaterialPageRoute(
builder: (_) =>
LearningCoursePage(courseId: course.id)));
},
),
),
]);
},
),
],
),
),
);
}
}
class _CourseCard extends StatelessWidget {
const _CourseCard({required this.course, required this.onTap});
final LearningCourse course;
final VoidCallback onTap;
@override
Widget build(BuildContext context) => Card(
child: InkWell(
borderRadius: BorderRadius.circular(18),
onTap: onTap,
child: Padding(
padding: const EdgeInsets.all(16),
child: Row(crossAxisAlignment: CrossAxisAlignment.start, children: [
CircleAvatar(
child:
Text(course.levels.isEmpty ? 'DE' : course.levels.first)),
const SizedBox(width: 14),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(course.title,
style: const TextStyle(
fontWeight: FontWeight.w900, fontSize: 16)),
const SizedBox(height: 4),
Text(course.description,
maxLines: 3, overflow: TextOverflow.ellipsis),
const SizedBox(height: 7),
Text(
AppLocalizations.of(context).tf('learningUnitsMinutes', {
'units': '${course.unitCount}',
'minutes': '${course.durationMinutes}'
}),
style: const TextStyle(
color: AppColors.mutedInk, fontSize: 12),
),
])),
const SizedBox(width: 6),
const Padding(
padding: EdgeInsets.only(top: 2),
child: Icon(Icons.chevron_right_rounded)),
]),
),
),
);
}
class _ErrorCard extends StatelessWidget {
const _ErrorCard({required this.onRetry});
final Future<void> Function() onRetry;
@override
Widget build(BuildContext context) => Card(
child: Padding(
padding: const EdgeInsets.all(18),
child: Column(children: [
Text(AppLocalizations.of(context).t('learningLoadError')),
TextButton(
onPressed: () => onRetry(),
child: Text(AppLocalizations.of(context).t('retry'))),
]),
),
);
}

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%