New composition area with emoji typeahead

This commit is contained in:
Ken Powers
2019-06-27 16:35:21 -04:00
committed by Scott Nonnenberg
parent e62a1a7812
commit 7b645011c2
95 changed files with 1740 additions and 1293 deletions

View File

@@ -1,53 +1,53 @@
### All emoji
```jsx
<Emojify text="🔥🔥🔥" i18n={util.i18n} />
<Emojify text="🔥🔥🔥" />
```
### With skin color modifier
```jsx
<Emojify text="👍🏾" i18n={util.i18n} />
<Emojify text="👍🏾" />
```
### With `sizeClass` provided
```jsx
<Emojify text="🔥" sizeClass="jumbo" i18n={util.i18n} />
<Emojify text="🔥" sizeClass="jumbo" />
```
```jsx
<Emojify text="🔥" sizeClass="large" i18n={util.i18n} />
<Emojify text="🔥" sizeClass="large" />
```
```jsx
<Emojify text="🔥" sizeClass="medium" i18n={util.i18n} />
<Emojify text="🔥" sizeClass="medium" />
```
```jsx
<Emojify text="🔥" sizeClass="small" i18n={util.i18n} />
<Emojify text="🔥" sizeClass="small" />
```
```jsx
<Emojify text="🔥" sizeClass="" i18n={util.i18n} />
<Emojify text="🔥" sizeClass="" />
```
### Starting and ending with emoji
```jsx
<Emojify text="🔥in between🔥" i18n={util.i18n} />
<Emojify text="🔥in between🔥" />
```
### With emoji in the middle
```jsx
<Emojify text="Before 🔥🔥 after" i18n={util.i18n} />
<Emojify text="Before 🔥🔥 after" />
```
### No emoji
```jsx
<Emojify text="This is the text" i18n={util.i18n} />
<Emojify text="This is the text" />
```
### Providing custom non-link render function
@@ -56,9 +56,5 @@
const renderNonEmoji = ({ text, key }) => (
<span key={key}>This is my custom content</span>
);
<Emojify
text="Before 🔥🔥 after"
renderNonEmoji={renderNonEmoji}
i18n={util.i18n}
/>;
<Emojify text="Before 🔥🔥 after" renderNonEmoji={renderNonEmoji} />;
```