reaction placement (#3548)
This commit is contained in:
parent
98dfa09250
commit
891be5efe5
3 changed files with 13 additions and 10 deletions
|
|
@ -151,7 +151,7 @@ class MessageSelectionPositionerState extends State<MessageSelectionPositioner>
|
|||
return reactionsEvents.where((e) => !e.redacted).isNotEmpty;
|
||||
}
|
||||
|
||||
double get reactionsHeight => hasReactions ? 32.0 : 0.0;
|
||||
double get reactionsHeight => hasReactions ? 28.0 : 0.0;
|
||||
|
||||
bool get ownMessage =>
|
||||
widget.event.senderId == widget.event.room.client.userID;
|
||||
|
|
|
|||
|
|
@ -83,11 +83,6 @@ class OverMessageOverlay extends StatelessWidget {
|
|||
width: controller.mediaQuery!.size.width -
|
||||
controller.columnWidth -
|
||||
(controller.showDetails ? FluffyThemes.columnWidth : 0),
|
||||
decoration: BoxDecoration(
|
||||
border: Border.all(
|
||||
color: Colors.green,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
|||
|
||||
import 'package:matrix/matrix.dart';
|
||||
|
||||
import 'package:fluffychat/config/themes.dart';
|
||||
import 'package:fluffychat/pages/chat/chat.dart';
|
||||
import 'package:fluffychat/pages/chat/events/message_reactions.dart';
|
||||
import 'package:fluffychat/pangea/toolbar/enums/reading_assistance_mode_enum.dart';
|
||||
|
|
@ -49,6 +50,7 @@ class OverlayCenterContent extends StatelessWidget {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final ownMessage = event.senderId == event.room.client.userID;
|
||||
return IgnorePointer(
|
||||
ignoring: !isTransitionAnimation &&
|
||||
readingAssistanceMode != ReadingAssistanceMode.practiceMode,
|
||||
|
|
@ -83,10 +85,16 @@ class OverlayCenterContent extends StatelessWidget {
|
|||
),
|
||||
),
|
||||
if (hasReactions)
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(4),
|
||||
child: SizedBox(
|
||||
height: 20,
|
||||
AnimatedSize(
|
||||
duration: FluffyThemes.animationDuration,
|
||||
curve: FluffyThemes.animationCurve,
|
||||
alignment: Alignment.bottomCenter,
|
||||
child: Padding(
|
||||
padding: EdgeInsets.only(
|
||||
top: 4.0,
|
||||
left: 4.0,
|
||||
right: ownMessage ? 0 : 12.0,
|
||||
),
|
||||
child: MessageReactions(
|
||||
event,
|
||||
chatController.timeline!,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue