From 5e145837d2a16d0cc0dce2fe3afab0ebe2f50861 Mon Sep 17 00:00:00 2001 From: ggurdin Date: Tue, 3 Sep 2024 10:43:26 -0400 Subject: [PATCH 1/2] add padding to reaction picker --- .../chat/message_selection_overlay.dart | 25 ++++++++++++++----- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/lib/pangea/widgets/chat/message_selection_overlay.dart b/lib/pangea/widgets/chat/message_selection_overlay.dart index 6f3100b24..744863187 100644 --- a/lib/pangea/widgets/chat/message_selection_overlay.dart +++ b/lib/pangea/widgets/chat/message_selection_overlay.dart @@ -190,10 +190,12 @@ class MessageSelectionOverlayState extends State { ), ); - final bool showDetails = Matrix.of(context) - .store - .getBool(SettingKeys.displayChatDetailsColumn) ?? - false; + final bool showDetails = (Matrix.of(context) + .store + .getBool(SettingKeys.displayChatDetailsColumn) ?? + false) && + FluffyThemes.isThreeColumnMode(context) && + widget.controller.room.membership == Membership.join; return Expanded( child: Stack( @@ -212,10 +214,21 @@ class MessageSelectionOverlayState extends State { ), Align( alignment: Alignment.bottomCenter, - child: Column( + child: Row( mainAxisSize: MainAxisSize.min, children: [ - OverlayFooter(controller: widget.controller), + Expanded( + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + OverlayFooter(controller: widget.controller), + ], + ), + ), + if (showDetails) + const SizedBox( + width: FluffyThemes.columnWidth, + ), ], ), ), From 660c49873b297f8310f0e2843e65cf9f30d04a0a Mon Sep 17 00:00:00 2001 From: ggurdin Date: Tue, 3 Sep 2024 11:22:17 -0400 Subject: [PATCH 2/2] removed expanded widget wrapping overlay stack that caused crash in release mode --- .../chat/message_selection_overlay.dart | 72 +++++++++---------- 1 file changed, 35 insertions(+), 37 deletions(-) diff --git a/lib/pangea/widgets/chat/message_selection_overlay.dart b/lib/pangea/widgets/chat/message_selection_overlay.dart index 744863187..e7c391a5b 100644 --- a/lib/pangea/widgets/chat/message_selection_overlay.dart +++ b/lib/pangea/widgets/chat/message_selection_overlay.dart @@ -197,46 +197,44 @@ class MessageSelectionOverlayState extends State { FluffyThemes.isThreeColumnMode(context) && widget.controller.room.membership == Membership.join; - return Expanded( - child: Stack( - children: [ - AnimatedPositioned( - duration: FluffyThemes.animationDuration, - left: 0, - right: showDetails ? FluffyThemes.columnWidth : 0, - bottom: adjustedOverlayBottomOffset == -1 - ? overlayBottomOffset - : adjustedOverlayBottomOffset, - child: Align( - alignment: Alignment.center, - child: overlayMessage, - ), + return Stack( + children: [ + AnimatedPositioned( + duration: FluffyThemes.animationDuration, + left: 0, + right: showDetails ? FluffyThemes.columnWidth : 0, + bottom: adjustedOverlayBottomOffset == -1 + ? overlayBottomOffset + : adjustedOverlayBottomOffset, + child: Align( + alignment: Alignment.center, + child: overlayMessage, ), - Align( - alignment: Alignment.bottomCenter, - child: Row( - mainAxisSize: MainAxisSize.min, - children: [ - Expanded( - child: Column( - mainAxisSize: MainAxisSize.min, - children: [ - OverlayFooter(controller: widget.controller), - ], - ), + ), + Align( + alignment: Alignment.bottomCenter, + child: Row( + mainAxisSize: MainAxisSize.min, + children: [ + Expanded( + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + OverlayFooter(controller: widget.controller), + ], ), - if (showDetails) - const SizedBox( - width: FluffyThemes.columnWidth, - ), - ], - ), + ), + if (showDetails) + const SizedBox( + width: FluffyThemes.columnWidth, + ), + ], ), - Material( - child: OverlayHeader(controller: widget.controller), - ), - ], - ), + ), + Material( + child: OverlayHeader(controller: widget.controller), + ), + ], ); } }