Skip to content

Commit

Permalink
Merge branch 'feat-special-emojis' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
Arenukvern committed Nov 17, 2021
2 parents daad393 + 5e6ffaf commit 100cb12
Show file tree
Hide file tree
Showing 23 changed files with 635 additions and 207 deletions.
122 changes: 122 additions & 0 deletions assets/special_emoji.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
[
{
"category": "special-emojis",
"emoji": "",
"keywords": "1,one"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "2,two"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "3,three"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "4,four"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "5,five"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "6,six"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "7,seven"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "8,eight"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "9,nine"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "10,ten"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "11,eleven"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "12,twelve"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "13,thirteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "14,fourteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "15,fifteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "16,sixteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "17,seventeen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "18,eighteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "19,nineteen"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "20,twenty"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "long line"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "line"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "play,arrow right"
},
{
"category": "special-emojis",
"emoji": "",
"keywords": "dot"
}
]
2 changes: 1 addition & 1 deletion lib/abstract/greetings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ part of abstract;
class Greeting {
Greeting() : _random = Random();
final Random _random;
int get _randomMax => morning.values.length - 1;
int get _randomMax => morning.values.length;
int get _randomMin => 0;
int _nextRandom() => _randomMin + _random.nextInt(_randomMax - _randomMin);

Expand Down
1 change: 1 addition & 0 deletions lib/gen/assets.gen.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions lib/generated/intl/messages_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
// ignore_for_file:prefer_single_quotes,comment_references, directives_ordering
// ignore_for_file:annotate_overrides,prefer_generic_function_type_aliases
// ignore_for_file:unused_import, file_names, avoid_escaping_inner_quotes
// ignore_for_file:unnecessary_string_interpolations, unnecessary_string_escapes

import 'package:intl/intl.dart';
import 'package:intl/message_lookup_by_library.dart';
Expand Down
1 change: 1 addition & 0 deletions lib/generated/intl/messages_it.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
// ignore_for_file:prefer_single_quotes,comment_references, directives_ordering
// ignore_for_file:annotate_overrides,prefer_generic_function_type_aliases
// ignore_for_file:unused_import, file_names, avoid_escaping_inner_quotes
// ignore_for_file:unnecessary_string_interpolations, unnecessary_string_escapes

import 'package:intl/intl.dart';
import 'package:intl/message_lookup_by_library.dart';
Expand Down
1 change: 1 addition & 0 deletions lib/generated/intl/messages_ru.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
// ignore_for_file:prefer_single_quotes,comment_references, directives_ordering
// ignore_for_file:annotate_overrides,prefer_generic_function_type_aliases
// ignore_for_file:unused_import, file_names, avoid_escaping_inner_quotes
// ignore_for_file:unnecessary_string_interpolations, unnecessary_string_escapes

import 'package:intl/intl.dart';
import 'package:intl/message_lookup_by_library.dart';
Expand Down
59 changes: 59 additions & 0 deletions lib/library/widgets/button_popup.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
part of widgets;

class ButtonPopup extends StatelessWidget {
const ButtonPopup({
required final this.children,
final this.height,
final this.hideBorder = false,
final Key? key,
}) : super(key: key);
final List<Widget> children;
final double? height;
final bool hideBorder;
@override
Widget build(final BuildContext context) {
final theme = Theme.of(context);
Color borderColor;
if (hideBorder) {
borderColor = Colors.transparent;
} else if (theme.brightness == Brightness.dark) {
borderColor = AppColors.cleanBlack;
} else {
borderColor = AppColors.grey4;
}
return Card(
elevation: 0,
clipBehavior: Clip.hardEdge,
color: Colors.transparent,
shape: RoundedRectangleBorder(
borderRadius: defaultBorderRadius,
side: BorderSide(
color: borderColor,
),
),
child: SizedBox(
height: height ?? 320,
width: 250,
child: Stack(
children: [
ColoredBox(
color: theme.canvasColor.withOpacity(0),
child: const SizedBox.expand(),
).frosted(
blur: theme.brightness == Brightness.dark ? 15 : 12,
frostOpacity: 0.1,
frostColor: theme.brightness == Brightness.dark
? AppColors.black
: AppColors.white,
),
Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: children,
),
],
),
),
);
}
}
22 changes: 22 additions & 0 deletions lib/library/widgets/emoji_button.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
part of widgets;

class EmojiButton extends StatelessWidget {
const EmojiButton({
required final this.onPressed,
required final this.emoji,
final Key? key,
}) : super(key: key);
final Emoji emoji;
final VoidCallback onPressed;
@override
Widget build(final BuildContext context) {
return CupertinoButton(
minSize: 0,
padding: EdgeInsets.zero,
onPressed: onPressed,
child: Center(
child: Text(emoji.emoji),
),
);
}
}
Loading

0 comments on commit 100cb12

Please sign in to comment.