fix modal adding safearea

This commit is contained in:
Salvatore Giordano
2021-05-20 15:33:01 +02:00
parent c9e72ebc91
commit 66ea6ae875
@@ -787,16 +787,19 @@ class _GroupInfoScreenState extends State<GroupInfoScreen> {
void _showUserInfoModal(User? user, bool isUserAdmin) {
var channel = StreamChannel.of(context).channel;
final color = StreamChatTheme.of(context).colorTheme.white;
showModalBottomSheet(
context: context,
clipBehavior: Clip.antiAlias,
isScrollControlled: true,
backgroundColor: color,
builder: (context) {
return StreamChannel(
return SafeArea(
child: StreamChannel(
channel: channel,
child: Material(
color: StreamChatTheme.of(context).colorTheme.white,
color: color,
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
@@ -912,7 +915,8 @@ class _GroupInfoScreenState extends State<GroupInfoScreen> {
_buildModalListTile(
context,
StreamSvgIcon.userRemove(
color: StreamChatTheme.of(context).colorTheme.accentRed,
color:
StreamChatTheme.of(context).colorTheme.accentRed,
size: 24.0,
),
'Remove From Group', () async {
@@ -920,7 +924,8 @@ class _GroupInfoScreenState extends State<GroupInfoScreen> {
context,
title: 'Remove member',
okText: 'REMOVE',
question: 'Are you sure you want to remove this member?',
question:
'Are you sure you want to remove this member?',
cancelText: 'CANCEL',
);
@@ -941,6 +946,7 @@ class _GroupInfoScreenState extends State<GroupInfoScreen> {
],
),
),
),
);
},
shape: RoundedRectangleBorder(