fix: Minor design fixes
This commit is contained in:
parent
719323ad66
commit
e9aa285f1a
|
@ -8,6 +8,7 @@ import 'package:fluffychat/utils/string_color.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_gen/gen_l10n/l10n.dart';
|
import 'package:flutter_gen/gen_l10n/l10n.dart';
|
||||||
|
|
||||||
|
import '../adaptive_page_layout.dart';
|
||||||
import '../avatar.dart';
|
import '../avatar.dart';
|
||||||
import '../matrix.dart';
|
import '../matrix.dart';
|
||||||
import '../message_reactions.dart';
|
import '../message_reactions.dart';
|
||||||
|
@ -86,6 +87,8 @@ class Message extends StatelessWidget {
|
||||||
color: color,
|
color: color,
|
||||||
borderRadius: BorderRadius.circular(radius),
|
borderRadius: BorderRadius.circular(radius),
|
||||||
),
|
),
|
||||||
|
constraints:
|
||||||
|
BoxConstraints(maxWidth: AdaptivePageLayout.defaultMinWidth),
|
||||||
child: Stack(
|
child: Stack(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Column(
|
Column(
|
||||||
|
|
|
@ -672,26 +672,16 @@ class _ChatState extends State<_Chat> {
|
||||||
child: Swipeable(
|
child: Swipeable(
|
||||||
key: ValueKey(
|
key: ValueKey(
|
||||||
filteredEvents[i - 1].eventId),
|
filteredEvents[i - 1].eventId),
|
||||||
background: Container(
|
background: Padding(
|
||||||
color: Theme.of(context)
|
|
||||||
.primaryColor
|
|
||||||
.withAlpha(100),
|
|
||||||
padding: EdgeInsets.symmetric(
|
padding: EdgeInsets.symmetric(
|
||||||
horizontal: 12.0),
|
horizontal: 12.0),
|
||||||
alignment: Alignment.centerLeft,
|
child: Center(
|
||||||
child: Row(
|
child: Icon(Icons.reply),
|
||||||
children: [
|
|
||||||
Icon(Icons.reply),
|
|
||||||
SizedBox(width: 2.0),
|
|
||||||
Text(L10n.of(context).reply)
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
direction: SwipeDirection.startToEnd,
|
direction: SwipeDirection.endToStart,
|
||||||
onSwipe: (direction) {
|
onSwipe: (direction) => replyAction(
|
||||||
replyAction(
|
replyTo: filteredEvents[i - 1]),
|
||||||
replyTo: filteredEvents[i - 1]);
|
|
||||||
},
|
|
||||||
child: Message(filteredEvents[i - 1],
|
child: Message(filteredEvents[i - 1],
|
||||||
onAvatarTab: (Event event) {
|
onAvatarTab: (Event event) {
|
||||||
sendController.text +=
|
sendController.text +=
|
||||||
|
|
Loading…
Reference in a new issue