chore: Adjust bubble color in dark mode

This commit is contained in:
Christian Pauly 2022-08-31 16:06:53 +02:00
parent 9ed1fcf2c7
commit 1370e892cd
2 changed files with 3 additions and 7 deletions

View File

@ -249,10 +249,7 @@ class ChatView extends StatelessWidget {
Radius.circular(AppConfig.borderRadius),
),
elevation: 4,
shadowColor: Theme.of(context)
.colorScheme
.onBackground
.withAlpha(64),
shadowColor: Colors.black.withAlpha(64),
clipBehavior: Clip.hardEdge,
color: Theme.of(context).brightness ==
Brightness.light

View File

@ -70,7 +70,7 @@ class Message extends StatelessWidget {
final alignment = ownMessage ? Alignment.topRight : Alignment.topLeft;
var color = Theme.of(context).brightness == Brightness.light
? Colors.white
: Colors.black;
: Theme.of(context).colorScheme.surfaceVariant;
final displayTime = event.type == EventTypes.RoomCreate ||
nextEvent == null ||
!event.originServerTs.sameEnvironment(nextEvent!.originServerTs);
@ -174,8 +174,7 @@ class Message extends StatelessWidget {
child: Material(
color: noBubble ? Colors.transparent : color,
elevation: event.type == EventTypes.Sticker ? 0 : 4,
shadowColor:
Theme.of(context).colorScheme.onBackground.withAlpha(64),
shadowColor: Colors.black.withAlpha(64),
borderRadius: borderRadius,
clipBehavior: Clip.antiAlias,
child: InkWell(