From f0cf278683d1eb00e8910abaf739bd010fdc3fc4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20Ku=C3=9Fowski?= Date: Mon, 17 Nov 2025 10:52:51 +0100 Subject: [PATCH] chore: Update start poll design --- lib/pages/chat/start_poll_bottom_sheet.dart | 33 +++++++-------------- 1 file changed, 11 insertions(+), 22 deletions(-) diff --git a/lib/pages/chat/start_poll_bottom_sheet.dart b/lib/pages/chat/start_poll_bottom_sheet.dart index 9c16c13ea..bc05a2a6e 100644 --- a/lib/pages/chat/start_poll_bottom_sheet.dart +++ b/lib/pages/chat/start_poll_bottom_sheet.dart @@ -79,28 +79,6 @@ class _StartPollBottomSheetState extends State { body: ListView( padding: const EdgeInsets.symmetric(horizontal: 32, vertical: 16), children: [ - SegmentedButton( - selected: {_pollKind}, - multiSelectionEnabled: false, - onSelectionChanged: (pollKind) => setState(() { - _pollKind = pollKind.first; - }), - segments: [ - ButtonSegment( - value: PollKind.disclosed, - label: Text( - L10n.of(context).answersVisible, - ), - ), - ButtonSegment( - value: PollKind.undisclosed, - label: Text( - L10n.of(context).answersHidden, - ), - ), - ], - ), - const SizedBox(height: 32), TextField( controller: _bodyController, minLines: 1, @@ -147,6 +125,17 @@ class _StartPollBottomSheetState extends State { label: Text(L10n.of(context).addAnswerOption), ), ), + const Divider(height: 32), + ListTile( + contentPadding: EdgeInsets.zero, + leading: Switch.adaptive( + value: _pollKind == PollKind.disclosed, + onChanged: (allow) => setState(() { + _pollKind = allow ? PollKind.disclosed : PollKind.undisclosed; + }), + ), + title: Text(L10n.of(context).answersVisible), + ), ListTile( contentPadding: EdgeInsets.zero, leading: Switch.adaptive(