File tree Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -704,13 +704,21 @@ class _MessageListState extends State<MessageList> with PerAccountStoreAwareStat
704
704
}
705
705
706
706
Widget _buildEndCap () {
707
- return Column (crossAxisAlignment: CrossAxisAlignment .stretch, children: [
708
- TypingStatusWidget (narrow: widget.narrow),
709
- MarkAsReadWidget (narrow: widget.narrow),
710
- // To reinforce that the end of the feed has been reached:
711
- // https://chat.zulip.org/#narrow/stream/243-mobile-team/topic/flutter.3A.20Mark-as-read/near/1680603
712
- const SizedBox (height: 36 ),
713
- ]);
707
+ if (model.haveNewest) {
708
+ return Column (crossAxisAlignment: CrossAxisAlignment .stretch, children: [
709
+ TypingStatusWidget (narrow: widget.narrow),
710
+ // TODO perhaps offer mark-as-read even when not done fetching?
711
+ MarkAsReadWidget (narrow: widget.narrow),
712
+ // To reinforce that the end of the feed has been reached:
713
+ // https://chat.zulip.org/#narrow/stream/243-mobile-team/topic/flutter.3A.20Mark-as-read/near/1680603
714
+ const SizedBox (height: 36 ),
715
+ ]);
716
+ } else if (model.busyFetchingMore) {
717
+ // See [_buildStartCap] for why this condition shows a loading indicator.
718
+ return const _MessageListLoadingMore ();
719
+ } else {
720
+ return SizedBox .shrink ();
721
+ }
714
722
}
715
723
716
724
Widget _buildItem (MessageListItem data) {
You can’t perform that action at this time.
0 commit comments