Skip to content

Commit

Permalink
Chat view refresh fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
IQuinteros committed Jun 29, 2021
1 parent 6948326 commit 154ae05
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lib/views/chat_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -152,13 +152,15 @@ class _ChatViewState extends State<ChatView> {
final scroll = SingleChildScrollView(
clipBehavior: Clip.none,
dragStartBehavior: DragStartBehavior.down,
physics: AlwaysScrollableScrollPhysics(),
controller: widget.scrollController,
child: Container(
margin: EdgeInsets.symmetric(
horizontal: 10
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.stretch,
mainAxisSize: MainAxisSize.max,
children: messagesWidget,
),
),
Expand Down Expand Up @@ -259,7 +261,12 @@ class _ChatViewState extends State<ChatView> {
children: [
SafeArea(
child: chatToUse != null? RefreshIndicator(
child: scroll,
child: Container(
child: scroll,
constraints: BoxConstraints(
minHeight: MediaQuery.of(context).size.height
),
),
onRefresh: () async => await updateChat(context, chatToUse)
) : _NoChatView(store: widget.store, purchase: widget.purchase,)
),
Expand Down

0 comments on commit 154ae05

Please sign in to comment.