Skip to content

Commit

Permalink
Merge pull request #51 from PAException/feature/instagram-listTile
Browse files Browse the repository at this point in the history
Added instagram list tile to about page
  • Loading branch information
PAException authored Apr 9, 2024
2 parents b898d3f + 6965e08 commit 58807b2
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/src/services/firebase/firebase_config.dart
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ class FirebaseConfig {
"enable_firebase": false,
"app_store_url": "https://apps.apple.com/app/engelsburg-planer/id6469040581",
"play_store_url": "https://play.google.com/store/apps/details?id=de.paulhuerkamp.engelsburg_planer",
"instagram": "https://www.instagram.com/engelsburg.planer/",
"support_email": "[email protected]",
});
}
Expand Down
10 changes: 10 additions & 0 deletions lib/src/view/pages/util/about_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import 'package:engelsburg_planer/src/view/routing/templates/page_base.dart';
import 'package:engelsburg_planer/src/view/widgets/app_icon.dart';
import 'package:firebase_remote_config/firebase_remote_config.dart';
import 'package:flutter/material.dart';
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
import 'package:package_info_plus/package_info_plus.dart';
import 'package:url_launcher/url_launcher.dart' as url_launcher;

Expand All @@ -23,6 +24,7 @@ class AboutPage extends PageBase {
builder: (context, snapshot) {
final packageInfo = snapshot.data;
var supportEmail = FirebaseRemoteConfig.instance.getString("support_email");
var instagram = FirebaseRemoteConfig.instance.getString("instagram");

String storeUrl = "";
if (Platform.isIOS) {
Expand Down Expand Up @@ -56,6 +58,14 @@ class AboutPage extends PageBase {
Uri.parse(storeUrl),
),
),
if (instagram.isNotEmpty)
ListTile(
leading: const Icon(FontAwesomeIcons.instagram),
title: const Text("Instagram"),
onTap: () => url_launcher.launchUrl(
Uri.parse(instagram),
),
),
ListTile(
leading: const Icon(Icons.mail),
title: Text(context.l10n.sendAnEmail),
Expand Down
1 change: 1 addition & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ dependencies:
introduction_screen: ^3.1.7
crypto: ^3.0.2
convert: ^3.1.1
font_awesome_flutter: ^10.7.0

# Util
html_unescape: ^2.0.0
Expand Down

0 comments on commit 58807b2

Please sign in to comment.