Improved accessibility

This commit is contained in:
Jakob Meier 2023-03-17 21:06:54 +01:00
parent 6aab88bbfd
commit 4c9f9b7627
No known key found for this signature in database
GPG key ID: 66BDC7E6A01A6152

View file

@ -38,10 +38,15 @@ class _WelcomePageState extends State<WelcomePage> {
} else if (_currentPage == 4 - 1) {
fabText = "Sign up";
}
String fabTooltip = "Continue Tour";
if (_currentPage == 0) {
fabTooltip = "Take Tour";
} else if (_currentPage == 4 - 1) {
fabTooltip = "Create an account";
}
double width = MediaQuery.of(context).size.width;
double height = MediaQuery.of(context).size.height;
double smallest = min(width, height);
return Scaffold(
@ -128,7 +133,7 @@ class _WelcomePageState extends State<WelcomePage> {
floatingActionButton: FloatingActionButton.extended(
icon: const Icon(Icons.chevron_right),
label: Text(fabText),
tooltip: 'Continue tour',
tooltip: fabTooltip,
onPressed: () {
if (controller.page == 4 - 1) {
// open signup screen