Merge branch 'feature/new-ui' into feature/mono-repo
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import 'package:emojis/emoji.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:stream_chat/stream_chat.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
@@ -38,27 +37,21 @@ Future<bool> showConfirmationDialog(
|
||||
return Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
SizedBox(
|
||||
height: 26.0,
|
||||
),
|
||||
SizedBox(height: 26.0),
|
||||
if (icon != null) icon,
|
||||
SizedBox(
|
||||
height: 26.0,
|
||||
),
|
||||
SizedBox(height: 26.0),
|
||||
Text(
|
||||
title,
|
||||
style: StreamChatTheme.of(context).textTheme.headlineBold,
|
||||
),
|
||||
SizedBox(
|
||||
height: 7.0,
|
||||
),
|
||||
Text(question),
|
||||
SizedBox(
|
||||
height: 36.0,
|
||||
SizedBox(height: 7.0),
|
||||
Text(
|
||||
question,
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
SizedBox(height: 36.0),
|
||||
Container(
|
||||
color:
|
||||
StreamChatTheme.of(context).colorTheme.black.withOpacity(.08),
|
||||
color: StreamChatTheme.of(context).colorTheme.greyGainsboro,
|
||||
height: 1.0,
|
||||
),
|
||||
Row(
|
||||
@@ -293,16 +286,3 @@ StreamSvgIcon getFileTypeImage(String type) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
final _emojis = Emoji.all();
|
||||
|
||||
bool textIsOnlyEmoji(String text) {
|
||||
return text.trim().characters.isNotEmpty &&
|
||||
text.trim().characters.every((c) =>
|
||||
_emojis.firstWhere(
|
||||
(Emoji emoji) => emoji.char.contains(c),
|
||||
orElse: () => null,
|
||||
) !=
|
||||
null) &&
|
||||
text.characters.length < 4;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user