@@ -289,12 +289,13 @@ class _EmojiAutocompleteItem extends StatelessWidget {
289
289
290
290
final EmojiAutocompleteResult option;
291
291
292
- static const _size = 32 .0 ;
293
- static const _notoColorEmojiTextSize = 25.7 ;
292
+ static const _size = 24 .0 ;
293
+ static const _notoColorEmojiTextSize = 19.3 ;
294
294
295
295
@override
296
296
Widget build (BuildContext context) {
297
297
final store = PerAccountStoreWidget .of (context);
298
+ final designVariables = DesignVariables .of (context);
298
299
final candidate = option.candidate;
299
300
300
301
// TODO deduplicate this logic with [EmojiPickerListEntry]
@@ -313,15 +314,26 @@ class _EmojiAutocompleteItem extends StatelessWidget {
313
314
? candidate.emojiName
314
315
: [candidate.emojiName, ...candidate.aliases].join (", " ); // TODO(#1080)
315
316
317
+ // TODO(design): emoji autocomplete results
318
+ // There's no design in Figma for emoji autocomplete results.
319
+ // Instead we adapt the design for the emoji picker to the
320
+ // context of autocomplete results as exemplified by _MentionAutocompleteItem.
321
+ // That means: emoji size, text size, text line-height, and font weight
322
+ // from emoji picker; text color (for contrast with background) and
323
+ // outer padding from _MentionAutocompleteItem; padding around emoji glyph
324
+ // to bring it to same size as avatar in _MentionAutocompleteItem.
316
325
return Padding (
317
326
padding: const EdgeInsets .symmetric (horizontal: 16.0 , vertical: 8.0 ),
318
327
child: Row (children: [
319
328
if (glyph != null ) ...[
320
- glyph,
321
- const SizedBox (width: 8 ),
329
+ Padding (padding: const EdgeInsets .all (6 ),
330
+ child: glyph),
331
+ const SizedBox (width: 6 ),
322
332
],
323
333
Expanded (
324
334
child: Text (
335
+ style: TextStyle (fontSize: 17 , height: 18 / 17 ,
336
+ color: designVariables.contextMenuItemLabel),
325
337
maxLines: 2 ,
326
338
overflow: TextOverflow .ellipsis,
327
339
label)),
0 commit comments