|
1 | 1 | import 'package:flutter/cupertino.dart'; |
2 | 2 | import 'package:flutter/material.dart'; |
| 3 | +import 'package:flutter_html/rich_text_parser.dart'; |
3 | 4 | import 'package:morea/Widgets/standart/moreaTextStyle.dart'; |
4 | 5 | import 'package:morea/morealayout.dart'; |
5 | | -import 'package:share/share.dart'; |
| 6 | +import 'package:morea/services/utilities/url_launcher.dart'; |
6 | 7 |
|
7 | 8 | class AboutThisApp extends StatelessWidget { |
| 9 | + final Urllauncher urllauncher = Urllauncher(); |
| 10 | + final String aboutText = |
| 11 | + "Warum haben wir eine App für die Pfadi Morea kreiert?\nHeutzutage will man alles mit dem Handy machen können, vom chatten bis zum eBanking. Also wollten wir euch dies auch für die Pfadi ermöglichen. Unser Ziel ist es, gewisse Abläufe für euch zu vereinfachen. So haben wir den E-Mail-Verteiler in die App integriert, so dass ihr automatisch in den Verteiler aufgenommen werdet, wenn ihr euch für die App registriert.\nDie App soll in Zukunft erweitert werden mit Funktionen, die euch das Leben in der Pfadi weiter vereinfachen.\nFalls ihr Ideen für die Weiterentwicklung der App habt oder wenn ihr Fehler findet, dann schreibt uns auf "; |
| 12 | + |
8 | 13 | @override |
9 | 14 | Widget build(BuildContext context) { |
10 | 15 | return new Scaffold( |
11 | 16 | appBar: new AppBar( |
12 | | - title: new Text("Über dieses App"), |
| 17 | + title: new Text("Über dieses App", style: MoreaTextStyle.lable,), |
13 | 18 | ), |
14 | 19 | body: MoreaBackgroundContainer( |
15 | 20 | child: SingleChildScrollView( |
16 | 21 | child: MoreaShadowContainer( |
17 | 22 | child: Column( |
18 | 23 | children: <Widget>[ |
19 | 24 | Padding( |
20 | | - padding: const EdgeInsets.all(20.0), |
21 | | - child: new Text("Gefällt dir die App?", style: MoreaTextStyle.lable,), |
| 25 | + padding: EdgeInsets.all(20), |
| 26 | + child: RichText( |
| 27 | + text: TextSpan(text: 'Die Pfadi Morea hat eine App!?', style: TextStyle( |
| 28 | + color: MoreaColors.violett, |
| 29 | + fontWeight: FontWeight.w600, |
| 30 | + fontSize: 18, |
| 31 | + letterSpacing: 0.15)), |
| 32 | + ), |
22 | 33 | ), |
23 | | - new Row( |
24 | | - mainAxisAlignment: MainAxisAlignment.center, |
25 | | - children: <Widget>[ |
26 | | - new Text("Erzähle allen davon!"), |
27 | | - new IconButton( |
28 | | - icon: Icon(Icons.share), |
29 | | - onPressed: () => { |
30 | | - Share.share("Möchtest du auch in die Pfadi? Lade dir unsere Pfadi Morea App im Playstore/Applestore herunter und komm vorbei!") |
31 | | - }, |
32 | | - ), |
33 | | - ], |
| 34 | + Padding( |
| 35 | + padding: const EdgeInsets.only(right: 20.0, left: 20.0,), |
| 36 | + child: RichText( |
| 37 | + text: TextSpan( |
| 38 | + text: aboutText, |
| 39 | + style: MoreaTextStyle.normal, |
| 40 | + children: <TextSpan>[ |
| 41 | + LinkTextSpan(text: 'it@morea.ch', style: MoreaTextStyle.link, onLinkTap: (url){urllauncher.openMail('it@morea.ch');}, url: 'mailto:<it@morea.ch>'), |
| 42 | + TextSpan(text: '.\nAzb Jarvis und Roran', style: MoreaTextStyle.normal) |
| 43 | + ] |
| 44 | + ) |
| 45 | + ), |
34 | 46 | ), |
35 | | - |
36 | 47 | Padding( |
37 | 48 | padding: EdgeInsets.only(bottom: 20), |
38 | 49 | ) |
|
0 commit comments