Skip to content

Commit

Permalink
Accessibility fix #50
Browse files Browse the repository at this point in the history
  • Loading branch information
matejkepes committed Nov 16, 2024
1 parent 12fa6d6 commit bf08e11
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 13 deletions.
2 changes: 1 addition & 1 deletion lib/ui/screens/settings_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ class _ValueListenableBoundTile<T> extends StatelessWidget {
);

return AlertDialog(
title: Text(title),
title: Semantics(header: true, child: Text(title)),
content: content,
);
},
Expand Down
28 changes: 16 additions & 12 deletions lib/ui/widgets/option_picker.dart
Original file line number Diff line number Diff line change
Expand Up @@ -55,18 +55,22 @@ class OptionPicker<T> extends StatelessWidget {
),
);

return Material(
child: InkWell(
onTap: () {
onValueChanged(value);
},
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
radio,
const SizedBox(width: 8),
label,
],
return Semantics(
checked: value == selectedValue,
inMutuallyExclusiveGroup: true,
child: Material(
child: InkWell(
onTap: () {
onValueChanged(value);
},
child: Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
ExcludeSemantics(child: radio),
const SizedBox(width: 8),
label,
],
),
),
),
);
Expand Down

0 comments on commit bf08e11

Please sign in to comment.