From 3332c525d41794a1b7624063534cdf836700ce2b Mon Sep 17 00:00:00 2001 From: Etienne Lemay Date: Sat, 27 May 2017 13:52:49 -0400 Subject: [PATCH] Add messenger & facebook sets --- README.md | 6 +++--- example/index.js | 2 +- src/components/emoji.js | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index c4f81f1..32124a1 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ import { Picker } from 'emoji-mart' | **perLine** | | `9` | Number of emojis per line. While there’s no minimum or maximum, this will affect the picker’s width. This will set *Frequently Used* length as well (`perLine * 4`) | | **i18n** | | [`{…}`](#i18n) | [An object](#i18n) containing localized strings | | **native** | | `false` | Renders the native unicode emoji | -| **set** | | `apple` | The emoji set: `'apple', 'google', 'twitter', 'emojione'` | +| **set** | | `apple` | The emoji set: `'apple', 'google', 'twitter', 'emojione', 'messenger', 'facebook'` | | **sheetSize** | | `64` | The emoji [sheet size](#sheet-sizes): `16, 20, 32, 64` | | **backgroundImageFn** | | ```((set, sheetSize) => …)``` | A Fn that returns that image sheet to use for emojis. Useful for avoiding a request if you have the sheet locally. | | **emojisToShowFilter** | | ```((emoji) => true)``` | A Fn to choose whether an emoji should be displayed or not | @@ -204,9 +204,9 @@ It can however be overwritten as per user preference. ![colors](https://cloud.githubusercontent.com/assets/436043/17221637/9f6f8508-54c2-11e6-8d10-59c5d3a458e0.png) #### Multiple sets supported -Apple / Google / Twitter / EmojiOne +Apple / Google / Twitter / EmojiOne / Messenger / Facebook -![sets](https://cloud.githubusercontent.com/assets/436043/17221550/4261d64a-54c2-11e6-8c49-a5c4c4696f8b.png) +![sets](https://cloud.githubusercontent.com/assets/436043/26523496/d41cd734-42e6-11e7-8ae8-bad87e83d534.png) ## Not opinionated **Emoji Mart** doesn’t automatically insert anything into a text input, nor does it show or hide itself. It simply returns an `emoji` object. It’s up to the developer to mount/unmount (it’s fast!) and position the picker. You can use the returned object as props for the `EmojiMart.Emoji` component. You could also use `emoji.colons` to insert text into a textarea or `emoji.native` to use the emoji. diff --git a/example/index.js b/example/index.js index ba4bcd9..588dd08 100644 --- a/example/index.js +++ b/example/index.js @@ -98,7 +98,7 @@ class Example extends React.Component {
- {['native', 'apple', 'google', 'twitter', 'emojione'].map((set) => { + {['native', 'apple', 'google', 'twitter', 'emojione', 'messenger', 'facebook'].map((set) => { var props = { disabled: !this.state.native && set == this.state.set } if (set == 'native' && this.state.native) { diff --git a/src/components/emoji.js b/src/components/emoji.js index 760049f..ae6dc2b 100644 --- a/src/components/emoji.js +++ b/src/components/emoji.js @@ -115,7 +115,7 @@ Emoji.propTypes = { forceSize: PropTypes.bool, skin: PropTypes.oneOf([1, 2, 3, 4, 5, 6]), sheetSize: PropTypes.oneOf([16, 20, 32, 64]), - set: PropTypes.oneOf(['apple', 'google', 'twitter', 'emojione']), + set: PropTypes.oneOf(['apple', 'google', 'twitter', 'emojione', 'messenger', 'facebook']), size: PropTypes.number.isRequired, emoji: PropTypes.oneOfType([ PropTypes.string,