Skip to content

Commit c339844

Browse files
author
MritunjayTiwari14
committed
poll: Simplify UI feedback on poll delay logic.
In this commit, we have traversed the decoration property of the Ink Widget to Material and Remove the Ink Widget. The Splash leaking out of the border has been fixed. Fixes: #1808 # Conflicts: # lib/widgets/poll.dart
1 parent f5c17a6 commit c339844

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

lib/widgets/poll.dart

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -97,18 +97,19 @@ class _PollWidgetState extends State<PollWidget> {
9797
padding: const EdgeInsetsDirectional.only(
9898
end: 5, top: verticalPadding, bottom: verticalPadding),
9999
child: Material(
100-
color: Colors.transparent,
100+
shape: RoundedRectangleBorder(
101+
borderRadius: BorderRadius.circular(3),
102+
side: BorderSide(color: theme.colorPollVoteCountBorder)),
103+
color: theme.colorPollVoteCountBackground,
104+
type: MaterialType.transparency,
105+
clipBehavior: Clip.antiAlias,
101106
child: InkWell(
102107
onTap: () => _toggleVote(option),
103-
child: Ink(
108+
child: Padding(
104109
// Inner padding preserves whitespace even when the text's
105110
// width approaches the button's min-width (e.g. because
106111
// there are more than three digits).
107112
padding: const EdgeInsets.symmetric(horizontal: 4),
108-
decoration: BoxDecoration(
109-
color: theme.colorPollVoteCountBackground,
110-
border: Border.all(color: theme.colorPollVoteCountBorder),
111-
borderRadius: BorderRadius.circular(3)),
112113
child: Center(
113114
child: Text(option.voters.length.toString(),
114115
style: textStyleBold.copyWith(

0 commit comments

Comments
 (0)