commit
b90ca821bc
2
.babelrc
2
.babelrc
|
@ -1,4 +1,4 @@
|
|||
{
|
||||
"presets": ["es2015", "react"],
|
||||
"plugins": ["transform-object-rest-spread"]
|
||||
"plugins": ["transform-object-rest-spread", "transform-runtime"]
|
||||
}
|
||||
|
|
|
@ -29,8 +29,10 @@
|
|||
"babel-loader": "6.2.4",
|
||||
"babel-plugin-transform-es2015-destructuring": "6.9.0",
|
||||
"babel-plugin-transform-object-rest-spread": "6.8.0",
|
||||
"babel-plugin-transform-runtime": "^6.23.0",
|
||||
"babel-preset-es2015": "6.6.0",
|
||||
"babel-preset-react": "6.5.0",
|
||||
"babel-runtime": "^6.23.0",
|
||||
"emoji-datasource": "^3.0.0",
|
||||
"emojilib": "^2.2.1",
|
||||
"inflection": "1.10.0",
|
||||
|
|
|
@ -153,7 +153,8 @@ export default class Picker extends React.Component {
|
|||
|
||||
handleEmojiOver(emoji) {
|
||||
var { preview } = this.refs
|
||||
const emojiData = CUSTOM_CATEGORY.emojis.find(customEmoji => customEmoji.id === emoji.id)
|
||||
// Use Array.prototype.find() when it is more widely supported.
|
||||
const emojiData = CUSTOM_CATEGORY.emojis.filter(customEmoji => customEmoji.id === emoji.id)[0]
|
||||
preview.setState({ emoji: Object.assign(emoji, emojiData) })
|
||||
clearTimeout(this.leaveTimeout)
|
||||
}
|
||||
|
|
|
@ -29,7 +29,8 @@ export default class Skins extends React.Component {
|
|||
|
||||
return <div>
|
||||
<div className={`emoji-mart-skin-swatches ${opened ? 'emoji-mart-skin-swatches-opened' : ''}`}>
|
||||
{Array(6).fill().map((_, i) => {
|
||||
{/* Use Array.prototype.fill() when it is more widely supported. */}
|
||||
{[...Array(6)].map((_, i) => {
|
||||
var skinTone = i + 1,
|
||||
selected = skinTone == skin
|
||||
|
||||
|
|
|
@ -37,7 +37,8 @@ function get(perLine) {
|
|||
if (!frequently) {
|
||||
defaults = {}
|
||||
|
||||
return Array(perLine).fill('').map((_, i) => {
|
||||
// Use Array.prototype.fill() when it is more widely supported.
|
||||
return [...Array(perLine)].map((_, i) => {
|
||||
defaults[DEFAULTS[i]] = perLine - i
|
||||
return DEFAULTS[i]
|
||||
})
|
||||
|
|
|
@ -513,6 +513,12 @@ babel-plugin-transform-regenerator@^6.6.0:
|
|||
dependencies:
|
||||
regenerator-transform "0.9.11"
|
||||
|
||||
babel-plugin-transform-runtime@^6.23.0:
|
||||
version "6.23.0"
|
||||
resolved "https://registry.yarnpkg.com/babel-plugin-transform-runtime/-/babel-plugin-transform-runtime-6.23.0.tgz#88490d446502ea9b8e7efb0fe09ec4d99479b1ee"
|
||||
dependencies:
|
||||
babel-runtime "^6.22.0"
|
||||
|
||||
babel-plugin-transform-strict-mode@^6.24.1:
|
||||
version "6.24.1"
|
||||
resolved "https://registry.yarnpkg.com/babel-plugin-transform-strict-mode/-/babel-plugin-transform-strict-mode-6.24.1.tgz#d5faf7aa578a65bbe591cf5edae04a0c67020758"
|
||||
|
@ -575,7 +581,7 @@ babel-runtime@^5.0.0:
|
|||
dependencies:
|
||||
core-js "^1.0.0"
|
||||
|
||||
babel-runtime@^6.0.0, babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.9.0:
|
||||
babel-runtime@^6.0.0, babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.23.0, babel-runtime@^6.9.0:
|
||||
version "6.23.0"
|
||||
resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.23.0.tgz#0a9489f144de70efb3ce4300accdb329e2fc543b"
|
||||
dependencies:
|
||||
|
|
Loading…
Reference in New Issue