do not render chat input when no permission
This commit is contained in:
parent
ed6d7e527d
commit
442a5a5cdf
|
|
@ -27,6 +27,19 @@ class ChatInputRow extends StatelessWidget {
|
||||||
}
|
}
|
||||||
const height = 48.0;
|
const height = 48.0;
|
||||||
|
|
||||||
|
if (!controller.room.canSendDefaultMessages) {
|
||||||
|
return Center(
|
||||||
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(12.0),
|
||||||
|
child: Text(
|
||||||
|
L10n.of(context).noSendPermission,
|
||||||
|
style: theme.textTheme.bodySmall,
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
if (!controller.room.otherPartyCanReceiveMessages) {
|
if (!controller.room.otherPartyCanReceiveMessages) {
|
||||||
return Center(
|
return Center(
|
||||||
child: Padding(
|
child: Padding(
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue