add textoverflow param to channel name

This commit is contained in:
Salvatore Giordano
2021-05-10 17:07:45 +02:00
parent b3ec54ae48
commit 45213fa7f1
@@ -12,11 +12,15 @@ class ChannelName extends StatelessWidget {
const ChannelName({
Key? key,
this.textStyle,
this.textOverflow = TextOverflow.ellipsis,
}) : super(key: key);
/// The style of the text displayed
final TextStyle? textStyle;
/// How visual overflow should be handled.
final TextOverflow textOverflow;
@override
Widget build(BuildContext context) {
final client = StreamChat.of(context);
@@ -71,7 +75,7 @@ class ChannelName extends StatelessWidget {
return Text(
title!,
style: textStyle,
overflow: TextOverflow.ellipsis,
overflow: textOverflow,
);
},
);