Skip to content

Commit 0a53ade

Browse files
committed
poll: Add missing padding for options placeholder text
Previously, the 5px bottom padding only existed when there were option rows. This padding should be applied to the placeholder text as well. Signed-off-by: Zixuan James Li <[email protected]>
1 parent c55582c commit 0a53ade

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

lib/widgets/poll.dart

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,11 @@ class _PollWidgetState extends State<PollWidget> {
113113
children: [
114114
Padding(padding: const EdgeInsets.only(bottom: 6), child: question),
115115
if (widget.poll.options.isEmpty)
116-
Text(zulipLocalizations.pollWidgetOptionsMissing,
117-
style: textStyleVoterNames.copyWith(fontStyle: FontStyle.italic)),
116+
Padding(
117+
// This is consistent with the option rows' bottom padding.
118+
padding: const EdgeInsets.only(bottom: 5),
119+
child: Text(zulipLocalizations.pollWidgetOptionsMissing,
120+
style: textStyleVoterNames.copyWith(fontStyle: FontStyle.italic))),
118121
for (final option in widget.poll.options)
119122
buildOptionItem(option),
120123
]);

0 commit comments

Comments
 (0)