File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed
packages/ubuntu_widgets/lib/src Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -8,13 +8,16 @@ import 'package:yaru/yaru.dart';
8
8
/// * [ValidatedFormField]
9
9
class SuccessIcon extends StatelessWidget {
10
10
/// Creates a success icon.
11
- const SuccessIcon ({super .key});
11
+ const SuccessIcon ({super .key, this .semanticLabel});
12
+
13
+ final String ? semanticLabel;
12
14
13
15
@override
14
16
Widget build (BuildContext context) {
15
17
return Icon (
16
18
Icons .check_circle,
17
19
color: Theme .of (context).colorScheme.success,
20
+ semanticLabel: semanticLabel,
18
21
);
19
22
}
20
23
}
@@ -25,10 +28,16 @@ class SuccessIcon extends StatelessWidget {
25
28
/// * [ValidatedFormField]
26
29
class ErrorIcon extends StatelessWidget {
27
30
/// Creates an error icon.
28
- const ErrorIcon ({super .key});
31
+ const ErrorIcon ({super .key, this .semanticLabel});
32
+
33
+ final String ? semanticLabel;
29
34
30
35
@override
31
36
Widget build (BuildContext context) {
32
- return Icon (Icons .error, color: Theme .of (context).colorScheme.error);
37
+ return Icon (
38
+ Icons .error,
39
+ color: Theme .of (context).colorScheme.error,
40
+ semanticLabel: semanticLabel,
41
+ );
33
42
}
34
43
}
You can’t perform that action at this time.
0 commit comments