mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-11-16 12:10:28 +03:00
Twemojified all text
Signed-off-by: Ajay Bura <ajbura@gmail.com>
This commit is contained in:
parent
9d0f99c509
commit
647d085c5f
18 changed files with 266 additions and 248 deletions
|
|
@ -2,6 +2,8 @@ import React, { useState, useEffect } from 'react';
|
|||
import PropTypes from 'prop-types';
|
||||
import './Avatar.scss';
|
||||
|
||||
import { twemojify } from '../../../util/twemojify';
|
||||
|
||||
import Text from '../text/Text';
|
||||
import RawIcon from '../system-icons/RawIcon';
|
||||
|
||||
|
|
@ -29,7 +31,11 @@ function Avatar({
|
|||
{
|
||||
iconSrc !== null
|
||||
? <RawIcon size={size} src={iconSrc} />
|
||||
: text !== null && <Text variant={textSize}>{[...text][0]}</Text>
|
||||
: text !== null && (
|
||||
<Text variant={textSize}>
|
||||
{twemojify([...text][0])}
|
||||
</Text>
|
||||
)
|
||||
}
|
||||
</span>
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue