a11y toast msg

This commit is contained in:
Dennis Fokin 2024-07-30 08:49:42 +02:00
parent c90ba130ce
commit f4fe5ff8ba
No known key found for this signature in database
GPG Key ID: 870B88256690D8BC

View File

@ -17,6 +17,7 @@
import 'dart:async';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
class Toast extends StatefulWidget {
final String message;
@ -149,5 +150,7 @@ void Function() showToast(
Overlay.of(context).insert(entry!);
});
SemanticsService.announce(message, TextDirection.ltr);
return close;
}