]> git.proxmox.com Git - flutter/pve_flutter_frontend.git/blob - lib/widgets/firstWelcomeScreen/pve_welcome_last.dart
tree-wide: prefer sized box for whitespace
[flutter/pve_flutter_frontend.git] / lib / widgets / firstWelcomeScreen / pve_welcome_last.dart
1 import 'package:flutter/material.dart';
2 import 'package:url_launcher/url_launcher.dart';
3 import 'package:pve_flutter_frontend/utils/proxmox_colors.dart';
4
5 // goodbye
6 class PveWelcomePageLast extends StatelessWidget {
7 const PveWelcomePageLast({super.key, this.onDone});
8
9 final VoidCallback? onDone;
10
11 @override
12 Widget build(BuildContext context) {
13 return Container(child: LayoutBuilder(
14 builder: (BuildContext context, BoxConstraints viewportConstraints) {
15 return SingleChildScrollView(
16 child: ConstrainedBox(
17 constraints: BoxConstraints(minHeight: viewportConstraints.maxHeight),
18 child: IntrinsicHeight(
19 child: Padding(
20 padding: const EdgeInsets.fromLTRB(15.0, 15.0, 15.0, 0.0),
21 child: Column(
22 mainAxisAlignment: MainAxisAlignment.spaceBetween,
23 children: [
24 const Spacer(flex: 3),
25 Column(
26 mainAxisAlignment: MainAxisAlignment.center,
27 children: [
28 const Text("Enjoy the app"),
29 const Padding(
30 padding: EdgeInsets.all(8.0),
31 child: Icon(
32 Icons.emoji_people_rounded,
33 color: Colors.white,
34 size: 70,
35 ),
36 ),
37 Padding(
38 padding: const EdgeInsets.all(8.0),
39 child: ElevatedButton(
40 onPressed: () => {onDone!()},
41 style: ElevatedButton.styleFrom(
42 backgroundColor: ProxmoxColors.orange,
43 foregroundColor: Colors.white,
44 ),
45 child: const Text("Start"),
46 ),
47 ),
48 ],
49 ),
50 const Spacer(flex: 1),
51 ConstrainedBox(
52 constraints: const BoxConstraints(maxWidth: 500),
53 child: Column(
54 children: [
55 const Text(
56 'If you have suggestions or experience any problems, please contact us via',
57 textAlign: TextAlign.center,
58 ),
59 Row(
60 mainAxisAlignment: MainAxisAlignment.spaceEvenly,
61 children: [
62 OutlinedButton(
63 onPressed: () =>
64 {launch('https://forum.proxmox.com')},
65 style: OutlinedButton.styleFrom(
66 side: const BorderSide(
67 color: ProxmoxColors.supportGrey),
68 foregroundColor: Colors.white,
69 ),
70 child: const Text('Forum'),
71 ),
72 OutlinedButton(
73 onPressed: () => {
74 launch(
75 'https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-user')
76 },
77 style: OutlinedButton.styleFrom(
78 side: const BorderSide(
79 color: ProxmoxColors.supportGrey),
80 foregroundColor: Colors.white,
81 ),
82 child: const Text('User Mailing List'),
83 ),
84 ],
85 ),
86 ],
87 ),
88 ),
89 const Spacer(
90 flex: 2,
91 )
92 ],
93 ),
94 ),
95 ),
96 ),
97 );
98 }));
99 }
100 }